long runtime v032

Support questions about the Threshold plugin

Moderators: Developers, Moderators

Post Reply
torstentfk
Cacti User
Posts: 367
Joined: Tue Apr 05, 2005 9:52 am
Location: Munich, Germany

long runtime v032

Post by torstentfk »

Hi,

feedback from upgrading from v030 to v032:
- changing the pluging version to 032 and doing one polling cycle the threshold page shows this picture:
- at the second cycle all thresholds turned to normal state.
- runtime changed from a view seconds in 030 to one minute.
- no statement int the cacti-log that points to "checking threshold".

Code: Select all

02/22/2007 09:55:33 AM - CMDPHP: Poller[0] Host[127] DS[1057] WARNING: Result from SNMP not valid.  Partial Result: No Such Object avail
02/22/2007 09:56:17 AM - SYSTEM STATS: Time:77.1636 Method:cmd.php Processes:3 Threads:N/A Hosts:271 HostsPerProcess:91 DataSources:4472 RRDsProcessed:2722
02/22/2007 09:56:17 AM - MANAGE: Poller[0] Checking Manage
02/22/2007 09:56:17 AM - UPTIME: Poller[0] Checking uptime
- alerting and email function works
- email ist considered as Spam:

Code: Select all

Content analysis details:   (7.2 points, 5.5 required)

 pts rule name              description
---- ---------------------- --------------------------------------------------
 0.8 EXTRA_MPART_TYPE       Header has extraneous Content-type:...type= entry
 1.2 BLANK_LINES_70_80      BODY: Message body has 70-80% blank lines
 5.0 HTML_IMAGE_ONLY_04     BODY: HTML: images with 0-400 bytes of words
 0.0 HTML_MESSAGE           BODY: HTML included in message
 0.2 HTML_TAG_BALANCE_BODY  BODY: HTML has unbalanced "body" tags
So I changed in thoild-functions.php:
added line 798: $mail->Body .="<p>This is an automatic generated message from the monitoring syste m.<br> Do not reply to this address.<br>This is an automatic generated message from the moni toring system.<br> Do not reply to this address.<br>This is an automatic generated message f rom the monitoring system.<br> Do not reply to this address.<br>This is an automatic generat ed message from the monitoring system.<br> Do not reply to this address.<br>This is an autom atic generated message from the monitoring system.<br> Do not reply to this address.<br>This is an automatic generated message from the monitoring system.<br> Do not reply to this addr ess.<br><p> This is not a Spam Mail - if you do not want to get any further emails please co ntact you local monitoring administrator (in most cases this is the local cacti-guru)";


Torsten
Attachments
thold-error.GIF
thold-error.GIF (16.33 KiB) Viewed 2111 times
cigamit
Developer
Posts: 3369
Joined: Thu Apr 07, 2005 3:29 pm
Location: B/CS Texas
Contact:

Post by cigamit »

Since thold now polls after every single thread / process, and not just once after everything else is done, you will see no notification in the log.

The first polling after installing the new one may cause that issue, as the DB isn't populated with the "old" value.

Runtime should have actually have gone down. v0.3.2 and up pulls directly from the cacti database, while earlier versions polled each and every rrd file individually, which was extremely slow. You may want to switch to debug mode and see what is causing the slow down.

I'm seeing about adding a text box in the settings for text to add to each email.
torstentfk
Cacti User
Posts: 367
Joined: Tue Apr 05, 2005 9:52 am
Location: Munich, Germany

Post by torstentfk »

Hi,

check the two versions in debug mode on my machine:
A "tail -f cacti-log"on version 030 veryfast through my window. In version 032 it puts a couple of debug lines and then stops for abt 1 second. After this break thold continues with next and stops again.....

here some lines from debug:

Code: Select all

03/05/2007 03:26:34 PM - CMDPHP: Poller[0] DEBUG: SQL Assoc: "SELECT DISTINCT local_graph_id FROM graph_templates_item WHERE task_item_id=7783"
03/05/2007 03:26:34 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "REPLACE INTO settings (name, value) VALUES ('thold_last_poll', NOW())"
03/05/2007 03:26:34 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "UPDATE thold_data SET lastread='60091840.2667', thold_alert='0', thold_fail_count='0' WHERE rra_id='4223' AND data_id=7783"
03/05/2007 03:26:34 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "UPDATE thold_data SET oldvalue = '699350222581' where data_id = 7778"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Assoc: "select id,name,name_cache from data_template_data where local_data_id=4221 order by id LIMIT 1"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Assoc: "select * from thold_data where thold_enabled='on' AND data_id = 7778"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Assoc: "SELECT DISTINCT local_graph_id FROM graph_templates_item WHERE task_item_id=7778"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "REPLACE INTO settings (name, value) VALUES ('thold_last_poll', NOW())"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "UPDATE thold_data SET lastread='49849689.4433', thold_alert='0', thold_fail_count='0' WHERE rra_id='4221' AND data_id=7778"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "UPDATE thold_data SET oldvalue = '68928152623' where data_id = 7779"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Assoc: "select id,name,name_cache from data_template_data where local_data_id=4221 order by id LIMIT 1"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Assoc: "select * from thold_data where thold_enabled='on' AND data_id = 7779"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Assoc: "SELECT DISTINCT local_graph_id FROM graph_templates_item WHERE task_item_id=7779"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "REPLACE INTO settings (name, value) VALUES ('thold_last_poll', NOW())"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "UPDATE thold_data SET lastread='5494173.21', thold_alert='0', thold_fail_count='0' WHERE rra_id='4221' AND data_id=7779"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "UPDATE thold_data SET oldvalue = '769653429125' where data_id = 7776"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Assoc: "select id,name,name_cache from data_template_data where local_data_id=4220 order by id LIMIT 1"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Assoc: "select * from thold_data where thold_enabled='on' AND data_id = 7776"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Assoc: "SELECT DISTINCT local_graph_id FROM graph_templates_item WHERE task_item_id=7776"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "REPLACE INTO settings (name, value) VALUES ('thold_last_poll', NOW())"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "UPDATE thold_data SET lastread='58024983.2367', thold_alert='0', thold_fail_count='0' WHERE rra_id='4220' AND data_id=7776"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "UPDATE thold_data SET oldvalue = '36834431132' where data_id = 7777"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Assoc: "select id,name,name_cache from data_template_data where local_data_id=4220 order by id LIMIT 1"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Assoc: "select * from thold_data where thold_enabled='on' AND data_id = 7777"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Assoc: "SELECT DISTINCT local_graph_id FROM graph_templates_item WHERE task_item_id=7777"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "REPLACE INTO settings (name, value) VALUES ('thold_last_poll', NOW())"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "UPDATE thold_data SET lastread='11779996.7567', thold_alert='0', thold_fail_count='0' WHERE rra_id='4220' AND data_id=7777"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "UPDATE thold_data SET oldvalue = '769653995767' where data_id = 7774"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Assoc: "select id,name,name_cache from data_template_data where local_data_id=4219 order by id LIMIT 1"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Assoc: "select * from thold_data where thold_enabled='on' AND data_id = 7774"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Assoc: "SELECT DISTINCT local_graph_id FROM graph_templates_item WHERE task_item_id=7774"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "REPLACE INTO settings (name, value) VALUES ('thold_last_poll', NOW())"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "UPDATE thold_data SET lastread='58024983.2367', thold_alert='0', thold_fail_count='0' WHERE rra_id='4219' AND data_id=7774"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "UPDATE thold_data SET oldvalue = '36835013375' where data_id = 7775"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Assoc: "select id,name,name_cache from data_template_data where local_data_id=4219 order by id LIMIT 1"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Assoc: "select * from thold_data where thold_enabled='on' AND data_id = 7775"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Assoc: "SELECT DISTINCT local_graph_id FROM graph_templates_item WHERE task_item_id=7775"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "REPLACE INTO settings (name, value) VALUES ('thold_last_poll', NOW())"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "UPDATE thold_data SET lastread='11779996.7567', thold_alert='0', thold_fail_count='0' WHERE rra_id='4219' AND data_id=7775"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "UPDATE thold_data SET oldvalue = '63106188561' where data_id = 7772"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Assoc: "select id,name,name_cache from data_template_data where local_data_id=4218 order by id LIMIT 1"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Assoc: "select * from thold_data where thold_enabled='on' AND data_id = 7772"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Assoc: "SELECT DISTINCT local_graph_id FROM graph_templates_item WHERE task_item_id=7772"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "REPLACE INTO settings (name, value) VALUES ('thold_last_poll', NOW())"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "UPDATE thold_data SET lastread='4557722.0633', thold_alert='0', thold_fail_count='0' WHERE rra_id='4218' AND data_id=7772"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "UPDATE thold_data SET oldvalue = '4952872419' where data_id = 7773"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Assoc: "select id,name,name_cache from data_template_data where local_data_id=4218 order by id LIMIT 1"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Assoc: "select * from thold_data where thold_enabled='on' AND data_id = 7773"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Assoc: "SELECT DISTINCT local_graph_id FROM graph_templates_item WHERE task_item_id=7773"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "REPLACE INTO settings (name, value) VALUES ('thold_last_poll', NOW())"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "UPDATE thold_data SET lastread='488817.4033', thold_alert='0', thold_fail_count='0' WHERE rra_id='4218' AND data_id=7773"
03/05/2007 03:26:35 PM - CMDPHP: Poller[0] DEBUG: SQL Exec: "UPDATE thold_data SET oldvalue = '636244250208' where data_id = 7770"
Torsten
cigamit
Developer
Posts: 3369
Joined: Thu Apr 07, 2005 3:29 pm
Location: B/CS Texas
Contact:

Post by cigamit »

I'm not seeing where it is stopping in the log you posted. That log spans < 2 seconds. It changes from 03:26:34 to 03:26:35 at the beginning of the log, and then continues on from there. It then processes 6 Datasources in the same second. Possibly even more, as it hasn't changed seconds yet.
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest