My-MacBook:~ me$ sudo mysqld_safe
Password:
chown: mysql: Invalid argument
Starting mysqld daemon with databases from /sw/var/mysql
STOPPING server from pid file /sw/var/mysql/My-MacBook.local.pid
080517 14:39:45 mysqld ended
After looking at /sw/var/mysql/My-MacBook.local.err, it seemed I was missing the user mysql. So I snooped around google and found the answer. Based on this, I executed the following commands:
sudo dscl localhost -create /Local/Default/Users/mysql
sudo dscl localhost -create /Local/Default/Users/mysql NFSHomeDirectory /var/emptyMy next attempt to start mysqld_safe gave me some more bad news:
sudo dscl localhost -create /Local/Default/Users/mysql Password '*'
sudo dscl localhost -create /Local/Default/Users/mysql PrimaryGroupID 74
sudo dscl localhost -create /Local/Default/Users/mysql RealName "MySQL Server"
sudo dscl localhost -create /Local/Default/Users/mysql UniqueID: 74
sudo dscl localhost -create /Local/Default/Users/mysql UserShell: /usr/bin/false
My-MacBook:var me$ sudo mysqld_safe Password:
chown: mysql: Invalid argument
Starting mysqld daemon with databases from /sw/var/mysql
STOPPING server from pid file /sw/var/mysql/My-MacBook.local.pid
080517 17:11:24 mysqld ended
This one was easy though. Just go to /sw/var and execute chown -R mysql mysql. You should be good to go from here. sudo mysqld_safe& should work just fine.
No comments:
Post a Comment