Unable to add a host or service in downtime mode

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
dworthcsl
Posts: 95
Joined: Wed Jan 11, 2012 4:00 pm

Unable to add a host or service in downtime mode

Post by dworthcsl »

Hi,

I am trying to put a host an all of its services in maintenance mode. However, when I add all of my information and click commit I get the following:
Sorry, but you are not authorized to commit the specified command.

Read the section of the documentation that deals with authentication and authorization in the CGIs for more information.
Logged into XI, I am able click on a service or host and disable notifications, reschedule a check, etc. I am also able to put a host or service in re-occuring downtime. My account is associated with the server. Is there anything else I am missing?

Thanks,
David
dworthcsl
Posts: 95
Joined: Wed Jan 11, 2012 4:00 pm

Re: Unable to add a host or service in downtime mode

Post by dworthcsl »

This is ver 2011R3.2 on RHEL 6.x 64bit.
mguthrie
Posts: 4380
Joined: Mon Jun 14, 2010 10:21 am

Re: Unable to add a host or service in downtime mode

Post by mguthrie »

What user are you logged into Nagios XI as?

When you go to fill in the information, what username does the Core cgi say your logged in as (top left on page)?
dworthcsl
Posts: 95
Joined: Wed Jan 11, 2012 4:00 pm

Re: Unable to add a host or service in downtime mode

Post by dworthcsl »

I am logged into XI as my user ID. When I go to add a service for maintenance, it list my full name, which is the same as the name that is listed under my userid. I just logged out and logged back in. I was able to put a host into maintenance mode, but not a service. When adding a service, I tried to put a * for service name to disable all services. I am not sure if this is a valid option. However, I also tried with a service name and that did not work.

Here is an example of what I am filling in.

Code: Select all

Host Name:	server_name
Service:	Check Disk nrpe
Author (Your Name):	This was filled in the name associated with my userid
Comment:	test

Triggered By:	default

Start Time:	default
End Time:	default
Type:	Tried flex and fixed
If Flexible, Duratio 2 hours


mguthrie
Posts: 4380
Joined: Mon Jun 14, 2010 10:21 am

Re: Unable to add a host or service in downtime mode

Post by mguthrie »

Can you check the following file and verify that your user ID was added to the following file for host and service commands?

/usr/local/nagios/etc/cgi.cfg
dworthcsl
Posts: 95
Joined: Wed Jan 11, 2012 4:00 pm

Re: Unable to add a host or service in downtime mode

Post by dworthcsl »

My id is valid for the following:

authorized_for_all_host_commands
authorized_for_all_hosts
authorized_for_all_service_commands
authorized_for_all_services
authorized_for_configuration_information
authorized_for_system_commands
authorized_for_system_information
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Unable to add a host or service in downtime mode

Post by scottwilkerson »

You need to make sure that the service name is exactly correct or you will get this error.

For example, if the service name is
/ Disk Usage
and you enter

Code: Select all

Check Disk nrpe
You will get this error.

To see if this is the problem, go to the service detail page
Advanced tab
click Schedule downtime
Then just add comment and modify time.

If it goes through, you just had a bad service name
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
dworthcsl
Posts: 95
Joined: Wed Jan 11, 2012 4:00 pm

Re: Unable to add a host or service in downtime mode

Post by dworthcsl »

That did work. Is there a way to add all services to a maintenance window? i.e. using "*" in the service field
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Unable to add a host or service in downtime mode

Post by scottwilkerson »

Go to Host Detail Page -> Advanced Tab -> See this host in Nagios Core

Then select "Schedule downtime for all services on this host"
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
dworthcsl
Posts: 95
Joined: Wed Jan 11, 2012 4:00 pm

Re: Unable to add a host or service in downtime mode

Post by dworthcsl »

Thanks! I was able to find it. It would be great to have the ability to disable all services off the Incident Management > Scheduled Downtime. That will save a step, but the current way works.
Locked