Skip to content

Instantly share code, notes, and snippets.

@rdmpage
Created January 8, 2015 11:09
Show Gist options
  • Save rdmpage/b98652324e0745c9bcf4 to your computer and use it in GitHub Desktop.
Save rdmpage/b98652324e0745c9bcf4 to your computer and use it in GitHub Desktop.
MySQL database permissions
When copying MySQL database files (i.e. the binary files in /usr/local/mysql/data ) to a new machine we need to set permissions.
For the database "db" we do the following:
sudo chown -R _mysql db
sudo chgrp -R _mysql db
sudo chmod -R 644 db
sudo chmod 755 db
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment