-
Notifications
You must be signed in to change notification settings - Fork 30
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Fix support for MySQL >= 4.1. Submitted by: Gerrit Beine <tux@pingu…
…ru.net> - Hardcode path to swapinfo, although the configure script works on normal FreeBSD systems, it fails on pointyhat because it does not have swapinfo PR: ports/78147 Submitted by: maintainer
- Loading branch information
Sergey Matveychuk
authored and
Sergey Matveychuk
committed
Feb 27, 2005
1 parent
244ac6a
commit 854c622
Showing
3 changed files
with
69 additions
and
9 deletions.
There are no files selected for viewing
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
--- plugins/check_mysql.c.orig Sun Dec 26 00:17:44 2004 | ||
+++ plugins/check_mysql.c Sun Feb 20 14:12:10 2005 | ||
@@ -123,8 +123,16 @@ | ||
die (STATE_CRITICAL, "%s\n", slaveresult); | ||
} | ||
|
||
+ } else if (mysql_field_count (&mysql) == 33) { | ||
+ /* mysql >= 4.1.1 */ | ||
+ snprintf (slaveresult, SLAVERESULTSIZE, "Slave IO: %s Slave SQL: %s", row[10], row[11]); | ||
+ if (strcmp (row[10], "Yes") != 0 || strcmp (row[11], "Yes") != 0) { | ||
+ mysql_free_result (res); | ||
+ mysql_close (&mysql); | ||
+ die (STATE_CRITICAL, "%s\n", slaveresult); | ||
+ } | ||
} else { | ||
- /* mysql 4.x.x */ | ||
+ /* mysql 4.0.x or 4.1.0 */ | ||
snprintf (slaveresult, SLAVERESULTSIZE, "Slave IO: %s Slave SQL: %s", row[9], row[10]); | ||
if (strcmp (row[9], "Yes") != 0 || strcmp (row[10], "Yes") != 0) { | ||
mysql_free_result (res); |
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