<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=us-ascii"><meta name=Generator content="Microsoft Word 12 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
{font-family:SimSun;
panose-1:2 1 6 0 3 1 1 1 1 1;}
@font-face
{font-family:Mangal;
panose-1:0 0 4 0 0 0 0 0 0 0;}
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@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;}
@font-face
{font-family:"\@SimSun";
panose-1:2 1 6 0 3 1 1 1 1 1;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0in;
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:10.0pt;}
@page WordSection1
{size:8.5in 11.0in;
margin:70.85pt 70.85pt 70.85pt 70.85pt;}
div.WordSection1
{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=EN-US link=blue vlink=purple><div class=WordSection1><p class=MsoNormal><span style='color:#1F497D'>Doesn’t this create potential problem if you just do a normal start with errors and not a restart? i.e. verify -> stop -> update configs -> start -> die ?<o:p></o:p></span></p><p class=MsoNormal><span style='color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span style='color:#1F497D'>Dan<o:p></o:p></span></p><p class=MsoNormal><span style='color:#1F497D'><o:p> </o:p></span></p><div><div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in'><p class=MsoNormal><b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>From:</span></b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'> SCHAER Frederic [mailto:frederic.schaer@cea.fr] <br><b>Sent:</b> Monday, March 07, 2011 10:30 AM<br><b>To:</b> nagios-devel@lists.sourceforge.net<br><b>Subject:</b> [Nagios-devel] nagios startup script patch<o:p></o:p></span></p></div></div><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Hi,<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Attached is a patch that intends to remove duplicate configuration checks when (re)starting nagios.<o:p></o:p></p><p class=MsoNormal>Especially, this divides by three nagios restart time for large configurations since the restart sequence is no more “verify - stop - verify - start + nagios paths check”, but only “verify - stop - start without checking paths” .<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Without patch, and because of circular dependencies checks, my nagios is taking 15 minutes to restart:<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal># time service nagios restart<o:p></o:p></p><p class=MsoNormal>Running configuration check...done.<o:p></o:p></p><p class=MsoNormal>Stopping nagios: ...done.<o:p></o:p></p><p class=MsoNormal>Starting nagios: done.<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>real 15m40.751s<o:p></o:p></p><p class=MsoNormal>user 15m24.449s<o:p></o:p></p><p class=MsoNormal>sys 0m1.388s<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>With this simple patch : <o:p></o:p></p><p class=MsoNormal># time service nagios restart<o:p></o:p></p><p class=MsoNormal>Running configuration check...done.<o:p></o:p></p><p class=MsoNormal>Stopping nagios: ..done.<o:p></o:p></p><p class=MsoNormal>Starting nagios: done.<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>real 5m2.680s<o:p></o:p></p><p class=MsoNormal>user 4m52.048s<o:p></o:p></p><p class=MsoNormal>sys 0m0.820s<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>I hope this gets included in the code…<o:p></o:p></p><p class=MsoNormal>Cheers,<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Frederic Schaer<o:p></o:p></p></div></body></html>