Page 1 of 1

mysql, dovecot and exim4 failed to start after reboot

Posted: Mon Apr 07, 2014 8:45 am
by Charger
I run droplet on DigitalOcean with Ubuntu 13.10, install Vesta CP and setup my sites.
After reboot I notice that on page 'Services" not started exim4, dovecot and mysql. Sites doesn't work because MySQL connection error.

In /var/log/mysql/error.log I found:

Code: Select all

InnoDB: Unable to lock ./ibdata1, error: 11
InnoDB: Check that you do not already have another mysqld process
InnoDB: using the same InnoDB data or log files.
This popular solution didn't help me:

Code: Select all

mv ibdata1 ibdata1.bak 
cp -a ibdata1.bak ibdata1
Service is not started, but port is used:

Code: Select all

root@hive:/home/charger# /etc/init.d/mysql status
 * MySQL is stopped.
root@hive:/home/charger# lsof -i:3306
COMMAND PID  USER   FD   TYPE DEVICE SIZE/OFF NODE NAME
mysqld  962 mysql   10u  IPv4   9772      0t0  TCP *:mysql (LISTEN)

root@hive:/home/charger# ps aux | grep mysql
mysql      962  0.3 10.4 599744 52372 ?        Ssl  04:17   0:00 /usr/sbin/mysqld
root      1219  0.0  0.1   4440   680 ?        S    04:17   0:00 /bin/sh /usr/bin/mysqld_safe
mysql     2269  0.1  6.3 356032 31676 ?        Sl   04:19   0:00 /usr/sbin/mysqld --basedir=/usr --datadir=/var/lib/mysql --plugin-dir=/usr/lib/mysql/plugin --user=mysql --log-error=/var/log/mysql/error.log --pid-file=/var/run/mysqld/mysqld.pid --socket=/var/run/mysqld/mysqld.sock --port=3306
root      2478  0.0  0.1  11156   928 pts/0    S+   04:20   0:00 grep --color=auto mysql
If I kill this process (kill -9 962) then on web-page mysql service become "running" and sites start working.

With exim4 and dovecot, I don't know is this right processes:

Code: Select all

root@hive:/home/charger# ps aux | grep exim4
111       1166  0.0  0.3 113240  1700 ?        Ss   04:17   0:00 /usr/sbin/exim4 -bd -q30m
root      5871  0.0  0.1  11156   928 pts/0    S+   04:49   0:00 grep --color=auto exim4
root@hive:/home/charger# ps aux | grep dovecot
root       810  0.0  0.2  21764  1484 ?        Ss   04:17   0:00 /usr/sbin/dovecot -F -c /etc/dovecot/dovecot.conf
dovecot    854  0.0  0.1  13276  1000 ?        S    04:17   0:00 dovecot/anvil
root       855  0.0  0.2  13404  1176 ?        S    04:17   0:00 dovecot/log
root       858  0.0  0.5  23124  2536 ?        S    04:17   0:00 dovecot/config
root      6076  0.0  0.1  11156   928 pts/0    S+   04:50   0:00 grep --color=auto dovecot
What is this mean? How I can fix this?

Re: mysql, dovecot and exim4 failed to start after reboot

Posted: Mon Apr 07, 2014 5:49 pm
by MyKEcz
Have you tried to reinstall MySQL? If doesn't reinstall help try run dpkg-reconfigure mysql-server-5.5.
I've installed few VestaCP panels without problems. Haven't your server crashed when you made some changes? Was that clean install of OS? I've seen somewhere that few servers of DigitalOcean had an HDD problems, maybe you can try make new one.

Re: mysql, dovecot and exim4 failed to start after reboot

Posted: Tue Apr 08, 2014 5:39 pm
by Charger
Looks like "dpkg-reconfigure mysql-server-5.5" is helped. Thanks.
But problem repeat if I start new droplet, install Vesta adn reboot. It is looks very strange for me.

Re: mysql, dovecot and exim4 failed to start after reboot

Posted: Fri Apr 11, 2014 3:56 pm
by imperio
Charger,
A you solved this problem?

Re: mysql, dovecot and exim4 failed to start after reboot

Posted: Tue Apr 15, 2014 5:07 pm
by Charger
imperio,
Yes, now MySQL worked after reboot, so this problem solved.

Re: mysql, dovecot and exim4 failed to start after reboot

Posted: Wed Apr 16, 2014 6:14 pm
by imperio
OK