Re: [Nagios-devel] Are all the last_update values in status.dat al=
Posted: Thu Jul 09, 2009 4:03 pm
I've vetted through 2.7, 2.12 and 3.x in all cases it's the same=20
fprintf(fp,"\tlast_update=3D%lu\n",current_time);
Oddly enough I don't think this was a bug. I think that this WAS a bug fix=
way back in the mists of time, the reason being is that the last_update ti=
me is NEVER set or updated except when it's read in from retention.dat
If we correct this code to the proper temp_host->last_update and temp_servi=
ce->last_update, nagios will likely segfault as soon as it writes out statu=
s.dat
I vote for complete removal of this line and modification of extinfo.c to u=
se the file update time, since it appears to be the only file that uses it.
Let me know what you think!
Sincerely,
Steve
________________________________________
From: Cary Petterborg [[email protected]]
Sent: Thursday, July 09, 2009 8:37 AM
To: Nagios Developers List
Subject: Re: [Nagios-devel] Are all the last_update values in status.dat al=
ways the same?
It is the same timestamp as "created" in the info record for all entries of=
last_update in the records (all 32,000 of them in the file).
I'll look at the code that we are using to see what it is using and compare=
it to the baseline 2.7 version. I don't think there will be any
difference in the code for that. Code changes for the nagios binary that we=
use are minimal.
Thanks
Cary
________________________________________
From: Andreas Ericsson [[email protected]]
Sent: Thursday, July 09, 2009 1:23 AM
To: Nagios Developers List
Subject: Re: [Nagios-devel] Are all the last_update values in status.dat al=
ways the same?
Cary Petterborg wrote:
> The value for last_update in status.dat is the same for all records
> on our installation (30,000 services, 3300 hosts on 2.7- yes, I know
> it's old). Are there instances where this would not be the case? It
> seems that it would have been much more efficient to just put the
> last_update in the file once at the top if it is always the same for
> each record. Then things like diff and rsync of the status.dat file
> would be *significantly* better. Is there a possible use of the
> last_update field that I'm unaware of that would make a single
> last_update entry for the file be a bad idea?
>
They're tracked separately per status object. If the times are all
the same, that could mean you've found a bug, or Nagios does something
that doesn't quite make sense to me. This is from looking at the
data structures for hosts and services. I haven't examined the code
that prints it all out.
--
Andreas Ericsson [email protected]
OP5 AB www.op5.se
Tel: +46 8-230225 Fax: +46 8-230231
Considering the successes of the wars on alcohol, poverty, drugs and
terror, I think we should give some serious thought to declaring war
on peace.
---------------------------------------------------------------------------=
---
Enter the BlackBerry Developer Challenge
This is your chance to win up to $100,000 in prizes! For a limited time,
vendors submitting new applications to BlackBerry App World(TM) will have
the opportunity to enter the BlackBerry Developer Challenge. See full prize
details at: http://p.sf.net/sfu/Challenge
_______________________________________________
Nagios-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/lis ... gios-devel
NOTICE: This email message is for the sole use of the intended recipient(s=
) and may contain confidential and privileged information. Any unauthorized=
review, use, disclosure or distribution is prohibited. If you are not the =
intended recipient, please contact the sender by reply email and destroy al=
l copies of the original message.
---------------------------------------------------------------------------=
---
Enter the BlackBerry Developer Challenge
This is your chance to win up to $100,000 in prizes! For a limited time,
vendors submitting new applications to BlackBerry App World(TM) will have
the opportunity to enter the BlackBerry Developer Challenge. See full prize
details at: http://p.sf.net/sfu/Challenge
...[email truncated]...
This post was automatically imported from historical nagios-devel mailing list archives
Original poster: ndreas Ericsson [[email protected]
fprintf(fp,"\tlast_update=3D%lu\n",current_time);
Oddly enough I don't think this was a bug. I think that this WAS a bug fix=
way back in the mists of time, the reason being is that the last_update ti=
me is NEVER set or updated except when it's read in from retention.dat
If we correct this code to the proper temp_host->last_update and temp_servi=
ce->last_update, nagios will likely segfault as soon as it writes out statu=
s.dat
I vote for complete removal of this line and modification of extinfo.c to u=
se the file update time, since it appears to be the only file that uses it.
Let me know what you think!
Sincerely,
Steve
________________________________________
From: Cary Petterborg [[email protected]]
Sent: Thursday, July 09, 2009 8:37 AM
To: Nagios Developers List
Subject: Re: [Nagios-devel] Are all the last_update values in status.dat al=
ways the same?
It is the same timestamp as "created" in the info record for all entries of=
last_update in the records (all 32,000 of them in the file).
I'll look at the code that we are using to see what it is using and compare=
it to the baseline 2.7 version. I don't think there will be any
difference in the code for that. Code changes for the nagios binary that we=
use are minimal.
Thanks
Cary
________________________________________
From: Andreas Ericsson [[email protected]]
Sent: Thursday, July 09, 2009 1:23 AM
To: Nagios Developers List
Subject: Re: [Nagios-devel] Are all the last_update values in status.dat al=
ways the same?
Cary Petterborg wrote:
> The value for last_update in status.dat is the same for all records
> on our installation (30,000 services, 3300 hosts on 2.7- yes, I know
> it's old). Are there instances where this would not be the case? It
> seems that it would have been much more efficient to just put the
> last_update in the file once at the top if it is always the same for
> each record. Then things like diff and rsync of the status.dat file
> would be *significantly* better. Is there a possible use of the
> last_update field that I'm unaware of that would make a single
> last_update entry for the file be a bad idea?
>
They're tracked separately per status object. If the times are all
the same, that could mean you've found a bug, or Nagios does something
that doesn't quite make sense to me. This is from looking at the
data structures for hosts and services. I haven't examined the code
that prints it all out.
--
Andreas Ericsson [email protected]
OP5 AB www.op5.se
Tel: +46 8-230225 Fax: +46 8-230231
Considering the successes of the wars on alcohol, poverty, drugs and
terror, I think we should give some serious thought to declaring war
on peace.
---------------------------------------------------------------------------=
---
Enter the BlackBerry Developer Challenge
This is your chance to win up to $100,000 in prizes! For a limited time,
vendors submitting new applications to BlackBerry App World(TM) will have
the opportunity to enter the BlackBerry Developer Challenge. See full prize
details at: http://p.sf.net/sfu/Challenge
_______________________________________________
Nagios-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/lis ... gios-devel
NOTICE: This email message is for the sole use of the intended recipient(s=
) and may contain confidential and privileged information. Any unauthorized=
review, use, disclosure or distribution is prohibited. If you are not the =
intended recipient, please contact the sender by reply email and destroy al=
l copies of the original message.
---------------------------------------------------------------------------=
---
Enter the BlackBerry Developer Challenge
This is your chance to win up to $100,000 in prizes! For a limited time,
vendors submitting new applications to BlackBerry App World(TM) will have
the opportunity to enter the BlackBerry Developer Challenge. See full prize
details at: http://p.sf.net/sfu/Challenge
...[email truncated]...
This post was automatically imported from historical nagios-devel mailing list archives
Original poster: ndreas Ericsson [[email protected]