thold sending alerts to deleted users

Support questions about the Threshold plugin

Moderators: Developers, Moderators

Post Reply
User avatar
jmb
Posts: 17
Joined: Tue Jul 29, 2008 2:32 pm

thold sending alerts to deleted users

Post by jmb »

We've been advised recently by our mail systems admins that they're seeing traffic for long-deleted mail accounts from Cacti. I took a look, and the addresses cited didn't exist in any Cacti user accounts, in any "Extra Alert Emails" fields of thresholds, or any settings. Then I had a look in the plugin_thold_contacts table, and found a bunch of addresses for users who no longer exist. A few joins later, and it can be seen that the thresholds still have connections to these, even though they're not displayed. It looks like thold_save_threshold_contacts either doesn't get called, or doesn't do its job (I can't see the corresponding DELETE in the MySQL binlog when I save a threshold).

This query finds all occurrences where a threshold is associated with a thold contact with no corresponding Cacti user:

Code: Select all

SELECT t.id, t.name, tc.id, tc.data
 FROM thold_data t
 JOIN plugin_thold_threshold_contact cl ON cl.thold_id = t.id
 JOIN plugin_thold_contacts tc ON cl.contact_id = tc.id
 LEFT JOIN user_auth ua ON tc.user_id = ua.id
WHERE ua.id IS NULL;
Any advice on how best to clear up such a mess?
Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests