Skip to content

Instantly share code, notes, and snippets.

@seanhsu0102
Created August 2, 2017 08:24
Show Gist options
  • Save seanhsu0102/56a25098ed39b8ebe4ae56979f2daca0 to your computer and use it in GitHub Desktop.
Save seanhsu0102/56a25098ed39b8ebe4ae56979f2daca0 to your computer and use it in GitHub Desktop.
check process mysqld with pidfile /var/run/mysqld/mysqld.pid
group database
group mysql
start program = "/etc/init.d/mysql start"
stop program = "/etc/init.d/mysql stop"
if failed host localhost port 3306 protocol mysql with timeout 15 seconds for 3 times within 4
cycles then restart
if failed unixsocket /var/run/mysqld/mysqld.sock protocol mysql for 3 times within 4 cycles then restart
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment