I need to set a trigger for diskspace on 4000000000 but the config always change it to 2147483647
So how can I get this max trigger to an higher value
2: hdd_used
Hi: 2147483647 Lo: n/a BL: off
Moderators: Developers, Moderators
2: hdd_used
Hi: 2147483647 Lo: n/a BL: off
And I got this errors:[root@cacti-test /]# php /www/htdocs/cacti/thold/check-thold.php
Can anybody solve this??[root@cacti-test /]# /www/php/bin/php /www/htdocs/cacti/thold/check-thold.php
Warning: main(../include/config.php): failed to open stream: No such file or directory in /www/htdocs/cacti/thold/check-thold.php on line 25
Warning: main(): Failed opening '../include/config.php' for inclusion (include_path='.:/www/php/lib/php') in /www/htdocs/cacti/thold/check-thold.php on line 25
Warning: mysql_connect(): Access denied for user 'root'@'localhost' (using password: NO) in /www/htdocs/cacti/thold/check-thold.php on line 33
Warning: mysql_select_db(): supplied argument is not a valid MySQL-Link resource in /www/htdocs/cacti/thold/check-thold.php on line 34
Warning: mysql_query(): Access denied for user 'root'@'localhost' (using password: NO) in /www/htdocs/cacti/thold/check-thold.php on line 35
Warning: mysql_query(): A link to the server could not be established in /www/htdocs/cacti/thold/check-thold.php on line 35
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /www/htdocs/cacti/thold/check-thold.php on line 35
Access denied for user 'root'@'localhost' (using password: NO)
benhanson wrote:So it appears that if I change the double quotes in _REQUEST["hostid"] to single quotes, _REQUEST['hostid'] that it fails LESS. Still works consistently if the first to If statements are removed, though this kills some functionality. What's the deal with "" or '' ?
As of now the work around is to delete that line of code so thold.php does not try to generate that graph.FreRange wrote:Well after a little expermenting on my side I think that there is something wrong with how thold.php calls graphs.
It all starts around line 106 (I made other changes so I'm not sure of the orginal line number)
<snip>
<img src="graph_image.php?local_graph_id=<?php echo $graph ?>&rra_id=1&graph_start=-32400&graph_height=100&graph_width=300&graph_nolegend=true">
</snip>
It looks like you can get 1 call to graph in this code then IIS6 will no longer produce grahps. You have to restart the IIS service to create any grahps anywhere in the site.
Maybe this should be re-coded to follow the graph_image.php, graph.php and the like. I'm bumping around in the code a little more to see if I can't find a workaround for us IIS6 users.
I use this command and I patched my cactid.[asm] wrote:Cactid patch, that mails host state changes
use patch -p1 < thold.patch
Here is cactid/util.c code from line 1326 to 1340:[root@cacti-test cacti-cactid-0.8.6c]# make install
source='util.c' object='util.o' libtool=no \
depfile='.deps/util.Po' tmpdepfile='.deps/util.TPo' \
depmode=gcc3 /bin/sh ./config/depcomp \
gcc -DHAVE_CONFIG_H -I. -I. -I./config -I/usr/local/include/net-snmp -I/usr/local/include/net-snmp/.. -I/usr/local/mysql/include/mysql -g -O2 -c `test -f 'util.c' || echo './'`util.c
util.c error: conflicting types for 'mail'
util.c error: previous implicit declaration of 'mail' was here
util.c2: warning: no newline at end of file
make: *** [util.o] Error 1
Code: Select all
void mail(const char* address_list, const char* subject, const char* body) {
char command[255];
char message[255];
sprintf(command, "/usr/lib/sendmail %s", address_list);
FILE* fp;
fp = popen(command, "w");
if (fp) {
fprintf(fp, "To: %s\n", address_list);
fprintf(fp, "Subject: %s\n", subject);
fprintf(fp, "\n%s\n", body);
pclose(fp);
}
}
Users browsing this forum: No registered users and 0 guests