From: Ben C. <Be...@cl...> - 2004-06-14 12:34:21
|
Phillipp, You are never waiting my time, if I can do anything to help PerfParse=20 users I always will. You problems is the version of SQL you are using. Only the latest=20 version 4 supports transactions. I would advise you to upgrade to the latest version. Alternatively, you=20 can edit the source code in the directory 'src'. Look for any lines like= : now_query("START TRANSACTION"); or now_query("COMMIT"); And delete them. Regards, Ben. Sand Philipp wrote: > Ah great now it works...thanks for that! > Now i got another failure :( I just created the Database and the tables= with the mysql_create.sh skript contributed. > Now i want to run perfparse and get the following: > [root@nagios1 bin]# ./perfparse > "START TRANSACTION" failed: > You have an error in your SQL syntax near 'START TRANSACTION' at line 1 >=20 > My mysql.log shows the following: >=20 > 040614 13:50:48 201 Connect ro...@na... on nagios > 201 Query SELECT file_name, line_in_file, las= t_line_hash, pid, file_name FROM perfdata_state WHERE domain =3D '008DC5B= 5' > 201 Query UPDATE perfdata_state SET pid =3D 1= 0227, line_in_file =3D 0, last_line_hash =3D '', file_name =3D '/usr/loca= l/nagios/var/serviceperf.log' WHERE domain =3D '008DC5B5' > 201 Query SET AUTOCOMMIT=3D0 > 201 Query START TRANSACTION > 201 Quit >=20 > Sorry for wasting your time :) >=20 > Philipp >=20 >=20 >>-----Original Message----- >>From: Ben Clewett [mailto:Ben...@ro...]=20 >>Sent: Monday, June 14, 2004 12:41 PM >>To: Sand Philipp >>Cc: 'per...@li...' >>Subject: Re: Make error >> >>Hi Philipp, >> >>I am glad you have found PerfParse, and hope you will enjoy using it. >> >>Your error messages seem to indicate you do not have the=20 >>MySQL client development libs on your system. These will=20 >>include the missing files 'mysql.h' and 'errmsg.h'. >> >>If you don't think this is the case, (errors in the make are=20 >>possible), enter the following and let me know if it replys=20 >>with anything: >> >>$ find / -name "mysql.h" -ls 2> /dev/null >> >>I do not know 'Fedora Core 1', so I am not sure how they=20 >>distribute the Mysql-devel package. You can however obtain=20 >>this from MySQL by getting and installing the source package=20 >>from mysql.com. It is the client development libs you need,=20 >>or the full package :) >> >>I also notice you are on MySQL version 3. This does not=20 >>support transactions. I strongly advice you upgrade to the=20 >>full version of MySQL 4, in what ever their latest release=20 >>version it, including the 'InnoDB', or 'max', release. =20 >>Transactions ensure that bad data cannot accidentally be=20 >>added to the system, which will ensure a far better quality=20 >>database in the long run. This also offers referential=20 >>integrity, so that your database cannot be accidentally=20 >>corrupted by a bad program/user! :) >> >>May I ask in future that you might want to address support=20 >>requests to the mailing list=20 >>per...@li.... You can sign up for=20 >>this from the bottom of PerfParse project page: >> >>http://sourceforge.net/projects/perfparse >> >>This will help other users with similar errors to fix their=20 >>own problems, and you may get a reply from another user who=20 >>offers an alternate fix. >> >>Kind regards, >> >>Ben Clewett. >> >> >>Sand Philipp wrote: >> >> >>>Hi Ben, >>> >>>I just wanted to try out your perparse Plugin for Nagios, and got a=20 >>>few problems in compiling the package... >>>My OS: Fedora Core 1 >>>Nagios 1.2 (without MySQL) >>>Mysql server version: 3.23.58 >>> >>>When I run configure everything looks fine. >>>When I run make (as root) the following messages are displayed: >>>[root@nagios1 perfparse-0.08]# make >>>make all-recursive >>>make[1]: Entering directory `/root/perfparse-0.08' >>>Making all in src >>>make[2]: Entering directory `/root/perfparse-0.08/src' >>>if gcc -DHAVE_CONFIG_H -I. -I. -I.. -I'/usr/include' =20 >> >>-g -O2 -Wall=20 >> >>>-MT perfparse.o -MD -MP -MF ".deps/perfparse.Tpo" -c -o perfparse.o=20 >>>perfparse.c; \ >>> >>>then mv -f ".deps/perfparse.Tpo" ".deps/perfparse.Po"; else rm -f=20 >>>".deps/perfparse.Tpo"; exit 1; fi In file included from=20 >>>perfparse.c:35: >>>common.h:29:19: mysql.h: No such file or directory >>>common.h:30:20: errmsg.h: No such file or directory In file=20 >> >>included=20 >> >>>from perfparse.c:35: >>>common.h:41: error: syntax error before "db_mysql" >>>common.h:41: warning: type defaults to `int' in declaration=20 >> >>of `db_mysql' >> >>>common.h:41: warning: data definition has no type or storage class >>>common.h:42: error: syntax error before '*' token >>>common.h:42: warning: type defaults to `int' in declaration of=20 >>>`query_result' >>>common.h:42: warning: data definition has no type or storage class >>>common.h:43: error: syntax error before "result_row" >>>common.h:43: warning: type defaults to `int' in declaration=20 >> >>of `result_row' >> >>>common.h:43: warning: data definition has no type or storage class >>>perfparse.c: In function `my_on_exit': >>>perfparse.c:198: warning: implicit declaration of function=20 >> >>`mysql_close' >> >>>perfparse.c: In function `save_raw_data': >>>perfparse.c:672: warning: implicit declaration of function=20 >>>`mysql_fetch_row' >>>perfparse.c: In function `saveBinAllowed': >>>perfparse.c:702: error: subscripted value is neither array=20 >> >>nor pointer >> >>>perfparse.c: In function `now_get_state': >>>perfparse.c:1183: error: subscripted value is neither array nor=20 >>>pointer >>>perfparse.c: In function `sql_fail': >>>perfparse.c:1386: warning: implicit declaration of function=20 >> >>`mysql_error' >> >>>perfparse.c:1386: warning: format argument is not a pointer (arg 4) >>>make[2]: *** [perfparse.o] Error 1 >>>make[2]: Leaving directory `/root/perfparse-0.08/src' >>>make[1]: *** [all-recursive] Error 1 >>>make[1]: Leaving directory `/root/perfparse-0.08' >>>make: *** [all] Error 2 >>> >>>When i run ./make install then, the following is displayed: >>> >>>[root@nagios1 perfparse-0.08]# make install Making install in src >>>make[1]: Entering directory `/root/perfparse-0.08/src' >>>if gcc -DHAVE_CONFIG_H -I. -I. -I.. -I'/usr/include' =20 >> >>-g -O2 -Wall=20 >> >>>-MT perfparse.o -MD -MP -MF ".deps/perfparse.Tpo" -c -o perfparse.o=20 >>>perfparse.c; \ >>> >>>then mv -f ".deps/perfparse.Tpo" ".deps/perfparse.Po"; else rm -f=20 >>>".deps/perfparse.Tpo"; exit 1; fi In file included from=20 >>>perfparse.c:35: >>>common.h:29:19: mysql.h: No such file or directory >>>common.h:30:20: errmsg.h: No such file or directory In file=20 >> >>included=20 >> >>>from perfparse.c:35: >>>common.h:41: error: syntax error before "db_mysql" >>>common.h:41: warning: type defaults to `int' in declaration=20 >> >>of `db_mysql' >> >>>common.h:41: warning: data definition has no type or storage class >>>common.h:42: error: syntax error before '*' token >>>common.h:42: warning: type defaults to `int' in declaration of=20 >>>`query_result' >>>common.h:42: warning: data definition has no type or storage class >>>common.h:43: error: syntax error before "result_row" >>>common.h:43: warning: type defaults to `int' in declaration=20 >> >>of `result_row' >> >>>common.h:43: warning: data definition has no type or storage class >>>perfparse.c: In function `my_on_exit': >>>perfparse.c:198: warning: implicit declaration of function=20 >> >>`mysql_close' >> >>>perfparse.c: In function `save_raw_data': >>>perfparse.c:672: warning: implicit declaration of function=20 >>>`mysql_fetch_row' >>>perfparse.c: In function `saveBinAllowed': >>>perfparse.c:702: error: subscripted value is neither array=20 >> >>nor pointer >> >>>perfparse.c: In function `now_get_state': >>>perfparse.c:1183: error: subscripted value is neither array nor=20 >>>pointer >>>perfparse.c: In function `sql_fail': >>>perfparse.c:1386: warning: implicit declaration of function=20 >> >>`mysql_error' >> >>>perfparse.c:1386: warning: format argument is not a pointer (arg 4) >>>make[1]: *** [perfparse.o] Error 1 >>>make[1]: Leaving directory `/root/perfparse-0.08/src' >>>make: *** [install-recursive] Error 1 >>> >>> >>>Any suggestions? >>>Thanks in advance! >>>Philipp >>> >>> >>> >>>_____________________________ >>> >>>*Philipp Sand* >>>OC-CC-TEC-SYS >>> >>>*SYCOR GmbH* >>>Heinrich-von-Stephan-Stra=DFe 1-5 >>>D - 37073 G=F6ttingen >>> >>>Telefon +49 (0) 551 / 490 - 0 >>>Telefax +49 (0) 551 / 490 - 2000 >>> >>>_ph...@sy..._ >>>___www.sycor.de___ <file://www.sycor.de>__ >>>------------------------------------------------ >>> >> >> >> >=20 |