Created
July 8, 2011 04:26
-
-
Save aw/1071141 to your computer and use it in GitHub Desktop.
xinetd script to check MySQL availability and replication status
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# /etc/xinetd.d/mysqlchk | |
# | |
service mysqlchk_write | |
{ | |
flags = REUSE | |
socket_type = stream | |
port = 9200 | |
wait = no | |
user = nobody | |
server = /opt/mysqlchk_status.sh | |
log_on_failure += USERID | |
disable = no | |
only_from = 172.16.0.0/24 # recommended to put the IPs that need | |
# to connect exclusively (security purposes) | |
} | |
service mysqlchk_read | |
{ | |
flags = REUSE | |
socket_type = stream | |
port = 9201 | |
wait = no | |
user = nobody | |
server = /opt/mysqlchk_replication.sh | |
log_on_failure += USERID | |
disable = no | |
only_from = 172.16.0.0/24 # recommended to put the IPs that need | |
# to connect exclusively (security purposes) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment