Details
-
Bug
-
Status: Closed (View Workflow)
-
Minor
-
Resolution: Duplicate
-
5.5.36, 10.0.6
-
None
-
debian 7 64 bits
Description
root@production3:/var/lib/mysql# service mysql start
|
[FAIL] Starting MariaDB database server: mysqld . . . . . . . . . . . . . . . . . . . failed!
|
but in fact if you wait 60 seconds, and try "mysql", the software is up.
The issue is using a large amount of memory and memlock=1
It seems that the OS takes time to lock the memory and the software reports a failure to start when in fact, the process has not finished yet.
The issue may be compounded by the fact that the machine is virtual, Vmware, and it may take longer to acquire a lock on memory.
I use large-pages=1.
I have no idea if the memory is actually locked or not
cat /proc/meminfo | grep -i pages
|
AnonPages: 11784856 kB
|
AnonHugePages: 0 kB
|
HugePages_Total: 27000
|
HugePages_Free: 1668
|
HugePages_Rsvd: 0
|
HugePages_Surp: 0
|
Hugepagesize: 2048 kB
|
I don't know what we can do here. I suppose one can always create a configuration where MariaDB will take a lot of time to start. I'm not sure it's possible in all cases to distinguish that from a hanged or locked up server (caused by some bug in MariaDB or even the Linux kernel).
Perhaps all you need to do is to increase MYSQLD_STARTUP_TIMEOUT, like in
root@production3:/var/lib/mysql# MYSQLD_STARTUP_TIMEOUT=60 service mysql start