Taken from http://www.ubuntugeek.com/how-to-change-the-mysql-data-default-directory.html
sudo /etc/init.d/mysql stop
sudo cp -R -p /var/lib/mysql /path/to/new/datadir
gksu gedit /etc/mysql/my.cnf
change the entry with datadir
sudo gedit /etc/apparmor.d/usr.sbin.mysqld
Copy the lines beginning with “/var/lib/mysql”, comment out the originals with hash marks (“#”), and paste the lines below the originals.
sudo /etc/init.d/apparmor reload
sudo /etc/init.d/mysql restart
Δεν υπάρχουν σχόλια:
Δημοσίευση σχολίου