[Nagios-devel] TR: retained_service_attribute_mask and other alike
Posted: Thu May 14, 2009 2:06 pm
This is a multi-part message in MIME format.
------_=_NextPart_001_01C9D49A.9C4CC6C1
Content-Type: text/plain;
charset="us-ascii"
Content-Transfer-Encoding: quoted-printable
Hi,
=20
I'm transferring this to the dev list, as I suspect something more like
a bug (and probably no standard user will be able to answer)
=20
=20
=20
Hi,
=20
I'm facing a strange problem.
=20
I have in my definitions services for which notifications are disabled :
I'm still running those services on all nodes because it gives me
indication something went wrong on all nodes.
I recently had to suppress notifications for all services of a
hostgroups because of a general failure on those hosts, and problem is
that when I used the nagios CGIs to re-enable the service notifications,
notifications for those services I really don't want any notification
got enabled too... and I had to disable all those notifications in that
hostgroup again using the CGIs (I hope you follow).
=20
So now I'm wondering how could I fix the situation, and restore things
to normal (i.e : according to services config file) without loosing all
services current state.
I just tried to use the following in my nagios 3.1 config file.
=20
retained_service_attribute_mask=3D1
retained_process_service_attribute_mask=3D1
=20
Tried that, because it looks like the correct value to use according to
include/common.h is :
#define MODATTR_NOTIFICATIONS_ENABLED 1
=20
(by the way : what's the real difference between those 2 variables ? I
can't understand the real difference reading the documentation)
Anyway : this didn't work. Services are still disabled on restart or
reload.
=20
I then tried this :
retained_service_attribute_mask=3DMODATTR_NOTIFICATIONS_ENABLED
retained_process_service_attribute_mask=3DMODATTR_NOTIFICATIONS_ENABLED
=20
I know values are wrong, but nothing prevented nagios from restarting.
And off course it still didn't work, services notifications are still
disabled.
So what ?
Are these configuration option really implemented ?
I'm trying to look into the code, and I don't see anywhere the values
defined in the code being used :
=20
nagios-3.1.0]$ grep -r retained_service_attribute_mask *
base/nagios.c:unsigned long retained_service_attribute_mask=3D0L;
base/utils.c:extern unsigned long retained_service_attribute_mask;
base/utils.c: retained_service_attribute_mask=3D0L;
base/config.c:extern unsigned long retained_service_attribute_mask;
base/config.c: else
if(!strcmp(variable,"retained_service_attribute_mask"))
base/config.c:
retained_service_attribute_mask=3Dstrtoul(value,NULL,0);
=20
(and then, only html files)
=20
...
=20
So the C variable wouldn't be used at all ?
Am I missing something ?
Thanks && regards
------_=_NextPart_001_01C9D49A.9C4CC6C1
Content-Type: text/html;
charset="us-ascii"
Content-Transfer-Encoding: quoted-printable
<!--
/* Font Definitions */
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
{font-family:Tahoma;
panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:purple;
text-decoration:underline;}
span.EmailStyle17
{mso-style-type:personal;
font-family:"Calibri","sans-serif";
color:windowtext;}
span.EmailStyle18
{mso-style-type:personal-reply;
font-family:"Calibri","sans-serif";
color:#1F497D;}
.MsoChpDefault
{mso-style-type:export-only;
font-size:1
...[email truncated]...
This post was automatically imported from historical nagios-devel mailing list archives
Original poster: [email protected]
------_=_NextPart_001_01C9D49A.9C4CC6C1
Content-Type: text/plain;
charset="us-ascii"
Content-Transfer-Encoding: quoted-printable
Hi,
=20
I'm transferring this to the dev list, as I suspect something more like
a bug (and probably no standard user will be able to answer)
=20
=20
=20
Hi,
=20
I'm facing a strange problem.
=20
I have in my definitions services for which notifications are disabled :
I'm still running those services on all nodes because it gives me
indication something went wrong on all nodes.
I recently had to suppress notifications for all services of a
hostgroups because of a general failure on those hosts, and problem is
that when I used the nagios CGIs to re-enable the service notifications,
notifications for those services I really don't want any notification
got enabled too... and I had to disable all those notifications in that
hostgroup again using the CGIs (I hope you follow).
=20
So now I'm wondering how could I fix the situation, and restore things
to normal (i.e : according to services config file) without loosing all
services current state.
I just tried to use the following in my nagios 3.1 config file.
=20
retained_service_attribute_mask=3D1
retained_process_service_attribute_mask=3D1
=20
Tried that, because it looks like the correct value to use according to
include/common.h is :
#define MODATTR_NOTIFICATIONS_ENABLED 1
=20
(by the way : what's the real difference between those 2 variables ? I
can't understand the real difference reading the documentation)
Anyway : this didn't work. Services are still disabled on restart or
reload.
=20
I then tried this :
retained_service_attribute_mask=3DMODATTR_NOTIFICATIONS_ENABLED
retained_process_service_attribute_mask=3DMODATTR_NOTIFICATIONS_ENABLED
=20
I know values are wrong, but nothing prevented nagios from restarting.
And off course it still didn't work, services notifications are still
disabled.
So what ?
Are these configuration option really implemented ?
I'm trying to look into the code, and I don't see anywhere the values
defined in the code being used :
=20
nagios-3.1.0]$ grep -r retained_service_attribute_mask *
base/nagios.c:unsigned long retained_service_attribute_mask=3D0L;
base/utils.c:extern unsigned long retained_service_attribute_mask;
base/utils.c: retained_service_attribute_mask=3D0L;
base/config.c:extern unsigned long retained_service_attribute_mask;
base/config.c: else
if(!strcmp(variable,"retained_service_attribute_mask"))
base/config.c:
retained_service_attribute_mask=3Dstrtoul(value,NULL,0);
=20
(and then, only html files)
=20
...
=20
So the C variable wouldn't be used at all ?
Am I missing something ?
Thanks && regards
------_=_NextPart_001_01C9D49A.9C4CC6C1
Content-Type: text/html;
charset="us-ascii"
Content-Transfer-Encoding: quoted-printable
<!--
/* Font Definitions */
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
{font-family:Tahoma;
panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:purple;
text-decoration:underline;}
span.EmailStyle17
{mso-style-type:personal;
font-family:"Calibri","sans-serif";
color:windowtext;}
span.EmailStyle18
{mso-style-type:personal-reply;
font-family:"Calibri","sans-serif";
color:#1F497D;}
.MsoChpDefault
{mso-style-type:export-only;
font-size:1
...[email truncated]...
This post was automatically imported from historical nagios-devel mailing list archives
Original poster: [email protected]