Hi,
not really a bug, just a suggestion: Why does the export script stops and
starts nagios again instead of just reloading the configuration
(/etc/init.d/nagios reload)?
Problem is that "/etc/init.d/nagios stop" requires the user which runs the
apache to have the "kill" permission. Of course, this can be "sudo"ed, but
it would be easier to use the reload command.
I introduced a new configuration item "nagios_reload" and adjusted the
export.php script slightly to:
<?php
$output = array();
exec($sys_config['nagios_reload'], $output, $rv);
foreach($output as $line) {
print($line . "<br />");
}
if($rv) {
if($rv == 126) {
?>
Unable to execute the Nagios Reload Command. Check
permissions to run '<?=$sys_config['nagios_reload'];?>' and try again...<br
/>
<?php
}
else {
?>
Reloading Nagios Failed via
'<?=$sys_config['nagios_reload'];?>'. Check the command and try
again...<br />
<?php
}
}
else
{
print("Nagios reloaded with exported configuration.<br /><br />");
}
?>
instead of the stop and start commands.
Tobias.
Nobody/Anonymous ( nobody ) - 2007-01-19 17:54
5
Open
None
Taylor
Export
None
Public
|
Date: 2008-04-27 12:44
|
|
Date: 2008-04-27 12:41
|
|
Date: 2008-02-14 19:45
|
|
Date: 2007-06-22 21:59
|
|
Date: 2007-06-06 11:09
|
|
Date: 2007-03-05 15:52 Logged In: NO |
|
Date: 2007-01-28 21:53 Logged In: NO |
| Field | Old Value | Date | By |
|---|---|---|---|
| assigned_to | nobody | 2007-06-22 21:59 | tdondich |
Copyright © 2010 Geeknet, Inc. All rights reserved. Terms of Use