Host Template showing up as host alias in notification

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
brdr
Posts: 312
Joined: Mon Jun 02, 2014 12:49 pm

Host Template showing up as host alias in notification

Post by brdr »

Hi,

We have XI 2014R2.3.

Below is email notification. It is default Email Settings using service notification command 'xi_service_notification_handler'. The only change is the we are using 'hostalias' where is says host in the email. For some reason if the host alias ('Description' field for Host in CCM) is blank the descript of the host template is being inserted in field hostalias. Is this by design?

---
From: noreply-nagios
Sent: Thursday, May 14, 2015 9:10 AM
To: xxxx xxxxxx
Subject: RECOVERY Service Alert - netdevice_01/_Hardware Environmentals is OK

***** Nagios XI Alert *****

Nagios has detected this service has recovered.

Notification Type: RECOVERY

Service: _Hardware Environmentals
Host: Network Device Host Template
Address: x.x.x.x
State: OK
Info: I am a Cisco IOS Software, Catalyst L3 Switch Software (CAT3K_CAA-UNIVERSALK9-M), Version 15.0(1)EX3, RELEASE SOFTWARE (fc2)
Date/Time: 2015-05-14 09:10:04

Respond: http://nagioshost/nagiosxi/rr.php?uid=6 ... 93b699ea41
Nagios URL: http:/nagioshost/nagiosxi/
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Host Template showing up as host alias in notification

Post by lmiltchev »

I believe if the alias is not set (if it is blank), you should see "alias" in the email notification. For example, in my notification options I have:

Code: Select all

Host Name: %host%
Hostalias: %hostalias%
Without alias

In the CCM:

Code: Select all

Host Name: localhost
Description: <blank>
In the email notification:

Code: Select all

Host Name: localhost
Hostalias: alias
With alias

In the CCM:

Code: Select all

Host Name: localhost
Description: TEST
In the email notification:

Code: Select all

Host Name: localhost
Hostalias: TEST
Be sure to check out our Knowledgebase for helpful articles and solutions!
brdr
Posts: 312
Joined: Mon Jun 02, 2014 12:49 pm

Re: Host Template showing up as host alias in notification

Post by brdr »

What happens when you do 'without alias' for the host your testing, and this host uses a template with a description of 'Host Template'? Does it still show as 'alias' or 'Host Template' in the email notification?

Thx
jdalrymple
Skynet Drone
Posts: 2620
Joined: Wed Feb 11, 2015 1:56 pm

Re: Host Template showing up as host alias in notification

Post by jdalrymple »

brdr - I wouldn't even call this "by design" it's just logical. Templates are just like regular hosts and the definitions stack upon one another. If you don't specify explicitly a definition in a host it will inherit it from the parent template.

What would you like to see become the alias of a host if you didn't explicitly set it?
brdr
Posts: 312
Joined: Mon Jun 02, 2014 12:49 pm

Re: Host Template showing up as host alias in notification

Post by brdr »

I dunno. Fo now, when I train the other users here that are entering hosts and using templates that the description of the host should be present, if not, they will get the description of the template if present in email notification. Plz lock. Thx.
jdalrymple
Skynet Drone
Posts: 2620
Joined: Wed Feb 11, 2015 1:56 pm

Re: Host Template showing up as host alias in notification

Post by jdalrymple »

Locking now - just one last addition. You might want to change your lowest level templates "alias" definition to be something like "Log into CCM and change this host's Alias" or something to remind your users.

Hope this helped.
Locked