Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I want to use of symbolic link for change path database in mysql.
I create a Directory ,then create a symbolic link to this directory but when I want to use of this database get following error:

ERROR 1018 (HY000): Can't read dir of './depot/' (errno: 13)

I disabled apparmor but not working.

I checked No Problem of Permission.

share|improve this question
add comment

1 Answer

To fix this problem you need to set correct permission on /var/lib/mysql/dbname/ directory. Use the command as follows:

cd /var/lib/mysql/

ls -l

chown mysql:mysql dbname/ -R

Replace dbname with actual database directory name. Now you can connect to your mysql server:

mysql -u user -p dbname -e 'show tables;'
share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.