MySql 5.5.10 won't start #5338

Closed
elindsay opened this Issue Apr 25, 2011 · 21 comments

Projects

None yet

After installing MySql with homebrew, I wasn't able to get the server running. It was a fresh install on a new computer that had never had mysql installed before.

After running

brew install mysql
mysql_install_db --verbose --user=whoami --basedir="$(brew --prefix mysql)" --datadir=/usr/local/var/mysql --tmpdir=/tmp
mysql.server start

I get

.................................................................................................... ERROR! The server quit without updating PID file (/usr/local/var/mysql/Emma-Lindsays-MacBook-Pro-2.local.pid)

I'm not sure if I'm missing a step in the middle here or not, but I've always been able to clearly follow the install instructions for mysql on homebrew before and never had a problem like this.

same problem for me

Contributor
adamv commented May 5, 2011

A recent update to the MySQL formula should address this.

You can also try:

mkdir -p /usr/local/var/mysql

before running

mysql.server start
@adamv adamv closed this May 5, 2011
@ghost
ghost commented Sep 8, 2011

I'm having the exact same issue. Why is this issue closed?

Experiencing this issue right now.

micho commented Sep 16, 2011

I'm getting the same

+1 on this problem. What is the problem?

I had this problem and the fix for me was to run:

sudo rm /etc/my.cnf

It's from an old manual mysql install from long ago and it conflicts with the homebrew mysql config.

fannar commented Nov 8, 2011

Saw similar problem using 5.5.15.

Nothing worked until the file /usr/local/var/mysql/[computer-name].err was emptied. Then mysql.server start worked.

Hmm ok I will try this. Been mostly on my work computer so have not had the time to check. Let you know when I do. Thanks!

Fannar, your solution works. Thakns!

Having the same problem, here is a gist of my cmd line output https://gist.github.com/2017873 I've tried all the suggested fixes but no luck. Brew install mysql 5.5.15 now

I managed to fix this using

mysql_install_db --verbose --basedir="$(brew --prefix mysql)" --datadir=/usr/local/var/mysql --tmpdir=/tmp

Seems to be an issue with the correct datadir and basedir and tmpdir folders..Just running mysql_install_db fails with a few errors about not finding my_print_defaults. I got past this however i then had the issue at startup of mysql.

The above command seemed to fix it however the only difference i see is that you set the user where i do not!

Thanks for the tip Themitchell. worked like a charm!

pheraph commented Jun 22, 2012

I noticed I have to create a my.cnf by hand if the datadir differs from the default location (/usr/local/var/mysql). I installed MySQL with the following command:

mysql_install_db --verbose --user=raphael --basedir="$(brew --prefix mysql)" --datadir=/Users/raphael/Webseiten/mysql-data --tmpdir=/tmp

When I tried to launch MySQL the logs showed the same error as in the initial post:

ERROR! The server quit without updating PID file (/usr/local/var/mysql/raphael.local.pid).

The logs revealed that mysqld still tries to find its tables in /usr/local/var/mysql, so I added a /usr/local/etc/my.cnfwith the following content:

[mysqld]
datadir=/Users/raphael/Webseiten/mysql-data
palya commented Jan 25, 2013

Thanks Themitchell! It works for me!

Error is Starting MySQL
. ERROR! The server quit without updating PID file (/usr/local/var/mysql/MP16.local.pid).

But, there is no folder in local/var for me to delete MP16.err file

I tried all the solutions but still have the same problem.

It began occurring after i did a brew switch from mysql 5.6.10 to 5.5.25.

I've also tried switching back to 5.6.10, but the problem is still there.

Owner

The MySQL database probably isn't backwards compatible.

+1

@fannar solution works.

rm -rf /usr/local/var/mysql/macbook.local.err
mysql.server start
amk221 commented Nov 17, 2015

When I try the suggested fix the .err and then run mysql.server restart file is immediately recreated.

Owner

@amk221 Open a new issue.

@MikeMcQuaid MikeMcQuaid locked and limited conversation to collaborators Nov 17, 2015
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.