Ok, I've searched all over and have spent quite a bit of my time installing, uninstalling, trying various option but without success.
I'm on Mac OS X Lion (10.7.3) and am trying to setup a Python, MySQL.
I successfully installed Python and MySQL via HomeBrew. Python works great.
After MySQL Installation, I followed the first 2 steps - unset and the mysql_install_db
commands.
Now, when I try to start mysql "mysql.server start", I get the following error
ERROR! The server quit without updating PID file (/usr/local/var/mysql/Brajeshwar.local.pid).
Brajeshwar
is my username on my machine.
I had this issue on mac 10.10.5 Yosemite
What I did to solve this
cd /usr/local/var/mysql
sudo rm *.err && sudo rm *.pid
sudo reboot
sudo mysql.server start
Find usr/local/var/mysql/your_computer_name.local.err file and understand the more information about error
Location : /usr/local/var/mysql/your_computer_name.local.err
It's probably problem with permissions
where PID is second column value 2. check ownership of mysql
I had this problem on Linux, but the cause is relevant to any mysql installation. In my case, the server was crashing before startup was complete and the pid file updated. The error messages were seen when starting up mysqld directly instead of via "service mysql start".
In my case, the cause was the partition where the log files were located being full. Removing log files permitted mysql to start again. To test for this issue, go to the location of your mysql activity logs, and do
df .
.I had the same issue on OS X El Capitan, here's the terminal command sequence that fixed it for me.
Delete error files (you'll have to change the path depending on your setup)
Find the info for the mysql process that's still running and kill it:
Now restart MySQL:
It works for me.
My issue was that I started server as sudo once and then tried to restart as a local user.
Here mysql was not able to write to '.err' file owned by root. I had to remove that file and restart the server: