1
I'm trying to move the mysql datadir on my Ubuntu 10.04 to an encrypted location.
I tried a naive approach of:
- setting up the encrypted private directory ( https://help.ubuntu.com/community/EncryptedPrivateDirectory )
- sudo stop mysql
- changing the datadir to ~/Private/mysql under [mysqld] in the my.cnf
- sudo mv /var/lib/mysql ~/Private/ sudo start
- sudo start mysql
Alas, not only did mysql not start, but I got a black screen with some text outputs ("fsck" caught my eye, but not much more) and a total freeze of the machine. After a hard reset, the entire user account won't log in, and I had to create a new one for now. By the way, even after moving the datadir back and getting mysql to work again (all from the secondary account), the primary account still won't log in, with the black screen with text message showing for about half a second and then throwing me back to the login screen.
Any thoughts on how to get the datadir into an encrypted location the "right way"?
(And what could possibly have screwed up the account so badly..)
1"a total freeze of the machine" makes this sounds like a lot more than just an encrypted directory and/or mysql problem to me. – Jarvin – 2010-08-23T20:23:48.443