Search Exchange
Search All Sites
Nagios Live Webinars
Let our experts show you how Nagios can help your organization.Login
Directory Tree
Directory
fgilain
byfgilain, May 19, 2014
Hi, when using this script, i had an error message at the bottom of the page :
Traceback (most recent call last): File "/usr/local/nagios/sbin/nss.py", line 97, in ? app = Nag() File "/usr/local/nagios/sbin/nss.py", line 39, in __init__ self.service() File "/usr/local/nagios/sbin/nss.py", line 94, in service if current_state != "0": UnboundLocalError: local variable 'current_state' referenced before assignment
i just added that line (line 56 and 77) to avoid that error to be displayed :
global current_state
hope it will help other users of this usefull script.
Florent
Traceback (most recent call last): File "/usr/local/nagios/sbin/nss.py", line 97, in ? app = Nag() File "/usr/local/nagios/sbin/nss.py", line 39, in __init__ self.service() File "/usr/local/nagios/sbin/nss.py", line 94, in service if current_state != "0": UnboundLocalError: local variable 'current_state' referenced before assignment
i just added that line (line 56 and 77) to avoid that error to be displayed :
global current_state
hope it will help other users of this usefull script.
Florent