Skip to content

Configure Systemd TimeoutStartSec

A node may fail to load with $ systemctl start mysql.service if the node has a large buffer pool or must synchronize a large amount of data.

A resolution is to either increase the setting for the mysql service TimeoutStartSec option to a higher number or disable the option.

Check the current timeout with the following:

$ systemctl show mysql.service -p TimeoutStartUSec
Expected output
TimeoutStartUSec=10min

The following command opens an editor and allows you to edit the value:

$ sudo systemctl edit mysql.service

In the text editor, add the following to overwrite the TimeoutStartSec configuration:

[Service]
TimeoutStartSec=900s

After systemctl is reloaded, the option value changes to 15 minutes.

Expected output
TimeoutStartUSec=15min

To disable the option, change the value to 0:

[Service]
TimeoutStartSec=0

After systemctl is reloaded, the option is disabled.

Expected output
TimeoutStartUSec=infinity

For the edited change to take effect, run the following command:

$ sudo systemctl daemon-reload

After systemctl has been reloaded, verify your change with systemctl show mysql.service -p TimeoutStartUSec.