Chown Not Responding as I expected

I recently changed the permission of mysql, /var/lib/mysql so I could save a database in it manually (was only option currently, instead of importing it the proper way). To do so, I had to change the permissions from username: MySQL Server and group: mysql. When I tried to change it back I got this error: chown: invalid user: ‘MySQL’... Where to now?

2

2 Answers

The username is probably mysql, not "MySQL Server" or "MySQL". Remember, everything in Linux is case sensitive.

You can also find out the exact username by running grep -i mysql /etc/passwd and take a look at the first word, that's the username.

Try this to set back the permission:

sudo chown mysql:mysql /var/lib/mysql

You can check if the mysql user is available on your system with the command:

id mysql

it should response something like this:

uid=107(mysql) gid=111(mysql) groups=111(mysql)
4

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

You Might Also Like