Error running MySQL Daemon

Conner Stephen McCabe asked:

I’m getting a bizarre error running my mysql daemon as the user ‘mysql’ here is what the command spews out, now I’ve checked and the instance isn’t running already :S So, I have no idea why it’s displaying this output:

120729 18:54:28 [Note] Plugin 'FEDERATED' is disabled.
120729 18:54:28 InnoDB: The InnoDB memory heap is disabled
120729 18:54:28 InnoDB: Mutexes and rw_locks use GCC atomic builtins
120729 18:54:28 InnoDB: Compressed tables use zlib 1.2.5
120729 18:54:28 InnoDB: Using Linux native AIO
120729 18:54:28 InnoDB: Initializing buffer pool, size = 128.0M
120729 18:54:28 InnoDB: Completed initialization of buffer pool
120729 18:54:28 InnoDB: highest supported file format is Barracuda.
120729 18:54:28  InnoDB: Waiting for the background threads to start
120729 18:54:29 InnoDB: 1.1.8 started; log sequence number 2929794
120729 18:54:29 [Note] Server hostname (bind-address): '0.0.0.0'; port: 3306
120729 18:54:29 [Note]   - '0.0.0.0' resolves to '0.0.0.0';
120729 18:54:29 [Note] Server socket created on IP: '0.0.0.0'.
120729 18:54:29 [ERROR] Can't start server : Bind on unix socket: No such file or directory
120729 18:54:29 [ERROR] Do you already have another mysqld server running on socket: /var/mysql/mysql.sock ?
120729 18:54:29 [ERROR] Aborting

120729 18:54:29  InnoDB: Starting shutdown...
120729 18:54:30  InnoDB: Shutdown completed; log sequence number 2929794
120729 18:54:30 [Note] mysqld: Shutdown complete

Any help is greatly appreciated, thanks guys!

My answer:


The problem is clear in the error messages:

120729 18:54:29 [ERROR] Can't start server : Bind on unix socket: No such file or directory
120729 18:54:29 [ERROR] Do you already have another mysqld server running on socket: /var/mysql/mysql.sock ?

Most likely that socket doesn’t actually exist. This is probably a simple typo.

By default the socket is located at /var/lib/mysql/mysql.sock on a Fedora box. So, in your /etc/my.cnf file you should have:

socket=/var/lib/mysql/mysql.sock

View the full question and answer on Server Fault.

Creative Commons License
This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.