Find all services with mails notifications enabled

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
pouda
Posts: 105
Joined: Wed Sep 14, 2011 9:47 am

Find all services with mails notifications enabled

Post by pouda »

Hi All,


I monitor more or less 1500 services and i would find quickly the list of services where Mail notifications is enable for a critical activities etc....

I'm not so bad in SQL but i've some difficulties to find the proper way of how these notifications are configured ...

Maybe someone can help me ?

Bye and have a nice day.
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Find all services with mails notifications enabled

Post by scottwilkerson »

This can be accomplished with the new CCM Beta found in the post
http://support.nagios.com/forum/viewtop ... 97&p=24253
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
pouda
Posts: 105
Joined: Wed Sep 14, 2011 9:47 am

Re: Find all services with mails notifications enabled

Post by pouda »

Hy,

Thanks for you reply, so now CCM beta is installed but i don't find the proper way where i can find all activated mail notifications on services monitored..

Can you help me please ?
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Find all services with mails notifications enabled

Post by scottwilkerson »

I have to apologize as I mis-read your original post. I thought you were asking for a way to enable/disable notifications for hosts/services en-masse.

There is no easy way to determine this as the type of notification in XI is managed per-user.

I can show you 2 SQL query's to see if the notification_enabled flag is set for hosts/services.

this is in the nagios MySQL database

for hosts

Code: Select all

SELECT name1 as host,notifications_enabled FROM nagios_objects,nagios_hosts WHERE objecttype_id=1 and object_id=host_object_id and is_active=1
for services

Code: Select all

SELECT name1 as host,name2 as service,notifications_enabled FROM nagios_objects,nagios_services WHERE objecttype_id=2 and object_id=service_object_id and is_active=1
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
pouda
Posts: 105
Joined: Wed Sep 14, 2011 9:47 am

Re: Find all services with mails notifications enabled

Post by pouda »

Hello,

These queries are working well BUT the result is not really the expected result.

When i get results for services i had all services with notification enabled but not MAIL notifications enabled .. i insist on the fact that i want to know on which services i activated the MAIL notifications.
notifi.jpg
You do not have the required permissions to view the files attached to this post.
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Find all services with mails notifications enabled

Post by scottwilkerson »

As stated in the previous email
scottwilkerson wrote:There is no easy way to determine this as the type of notification in XI is managed per-user.
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
Locked