[Nagios-devel] Host alias on retention data file

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
Guest

[Nagios-devel] Host alias on retention data file

Post by Guest »

Hello,

I'm facing a little problem here and maybe you could help me clarify my min=
d.
Let's suppose i've configured a host called 'linux0' with an 'alias' 'my li=
nux server' and after a few days i resolve to change the alias for the same=
host for, let's say, 'my linux server 2'.

I've noticed that the macro $HOSTALIAS$ keeps pointing me to the old alias(=
'my linux server') after Nagios restart, disregarding my change.
I take a look on the source code and i saw that the alias is stored to and =
restored from retention.dat file when I restart my Nagios daemon, thus over=
writing my configuration file changed alias. Is that the desired behaviour?
When is the macro $HOSTALIAS$ will be set to 'my linux server 2' ?

I saw that we have a configuration variable called retained_host_attribute_=
mask, and according to documentation, i need to look at includes/common.h t=
o be able to avoid a specific var to be stored at retention.dat.=20
But in includes/common.h I only could find defines for status related varia=
bles, none related to alias.

I could prevent the overwrite of 'alias' variable editing the source code, =
more specificaly on xdata/xrddefault.c line 1204, but i think that i'm prob=
ably missing something here.

Any thoughts?

--
Ricardo Jos=E9 Maraschini
OpServices Tecnologia da Informa=E7=E3o
Your IT under control





This post was automatically imported from historical nagios-devel mailing list archives
Original poster: [email protected]
Locked