Not the answer you need?
Register and ask your own question!
Many Forum changes were implemented on Tue 22 Sep. Read about new Ranks, Scoring, and Reactions.
Email [email protected] for any comments or concerns.

where do I get check_mysql?

iberkneriberkner ContributorInactive User Role Beginner
As part of checking replication on a slave, our consultants are using a check_mysql file. I'm setting up a slave for backup purposes and wanted to run the same checks against the new slave. I copied the check_mysql file from our current slave to the new slave but it doesn't run, I get this error:


-bash: ./check_mysql: cannot execute binary file


The file probably needs to be compiled from source? or maybe something else?

Where do I get this file? I thought it was part of maatkit but its not?

Thanks

Comments

  • iberkneriberkner Contributor Inactive User Role Beginner
    I think I figured this out to be the nagios check_mysql plugin. I installed the plugins and copied the file and it seems to be working correctly.
  • ri0dayri0day Entrant Current User Role Beginner
    this my simple script for nagios monitor plugin,you can modfiy to suit you environment

    #!/bin/baship=$(/sbin/ifconfig eth1 |sed -n 2p |sed 's/^.*addr://g'|sed 's/Bcast.*//g')mysql -uuser -ppasswd -hhost -e"show slave status \G" >/tmp/$$.statusstatus=$(grep Seconds_Behind_Master: /tmp/$$.status)s1=${status##*:}if $s1 == "NULL";then echo "CRITICAL - REPLICATION IS STOP - $ip" exit 2fiif $s1 -lt 200then echo "OK - $s1 s - $ip " exit 0else echo "WARINING - Slave Behind Master $s1 S - $ip" exit 1firm -rf /tmp/$$.status"</pre>
Sign In or Register to comment.

MySQL, InnoDB, MariaDB and MongoDB are trademarks of their respective owners.
Copyright ©2005 - 2020 Percona LLC. All rights reserved.