samedi 31 janvier 2015

Socket problems after upgrade


We just upgraded from 5.1 to 5.5 and seem to be having some weird socket issues. Here is the data I think is needed, let me know if you guys have any ideas.


First, here's the error message we're getting:



150201 1:32:59 [Note] Server hostname (bind-address): '0.0.0.0'; port: 3306
150201 1:32:59 [Note] - '0.0.0.0' resolves to '0.0.0.0';
150201 1:32:59 [Note] Server socket created on IP: '0.0.0.0'.
150201 1:32:59 [ERROR] Can't start server : Bind on unix socket: Permission denied
150201 1:32:59 [ERROR] Do you already have another mysqld server running on socket: /var/run/mysqld/mysqld.sock ?
150201 1:32:59 [ERROR] Aborting


So naturally we went through and checked read/write permissions and as you can see the settings are set correctly, and no mysqld.sock file exists



$: ls -ld mysqld
drwxr-xr-x 2 mysql root 40 Feb 1 00:55 mysqld
$: ls -a mysqld
. ..


We are using a different data directory and so we saw this thread: http://ift.tt/1D0r32c But after making the correct changes to apparmor it still does not seem to work.


/etc/apparmor.d/usr.sbin/mysqld



/usr/sbin/mysqld {
/sc/mysql/ r,
/sc/mysql/** rwk,
...
/var/run/mysqld/mysqld.pid w,
/var/run/mysqld/mysqld.sock w,
}


And finally, here is the my.cnf log:



[client]
port = 3306
socket = /var/run/mysqld/mysqld.sock

[mysqld_safe]
socket = /var/run/mysqld/mysqld.sock
nice = 0

[mysqld]
user = mysql
socket = /var/run/mysqld/mysqld.sock
port = 3306
basedir = /usr
datadir = /sc/mysql
tmpdir = /tmp
skip-external-locking
bind-address = 0.0.0.0
key_buffer = 16M
max_allowed_packet = 24M
thread_stack = 192K
thread_cache_size = 8
myisam-recover-options = BACKUP
query_cache_limit = 1M
query_cache_size = 16M
log_error = /var/log/mysql/error.log
expire_logs_days = 10
max_binlog_size = 100M

[mysqldump]
quick
quote-names
max_allowed_packet = 16M

[mysql]

[isamchk]
key_buffer = 16M

!includedir /etc/mysql/conf.d/


Also, although I knew it wouldn't work since mysqld isn't up and running, we did attempt to run mysql_upgrade to see what errors were coming back and this is what we got:



$: mysql_upgrade
Looking for 'mysql' as: mysql
Looking for 'mysqlcheck' as: mysqlcheck
FATAL ERROR: Upgrade failed


Any help would be greatly appreciated =) Lemme know if anymore information is needed.





Aucun commentaire:

Enregistrer un commentaire