Quantcast
Channel: Zenoss Community: Message List
Viewing all articles
Browse latest Browse all 1118

Re: Command Notification to run a python script

$
0
0

OK - it works.

 

Several things here.

 

1) Script is still identical to the above - note that is uses the environment variable ZENHOME

 

2) In the command notification configuration you do not want ANY quotes.  If you have quotes around the whole command then the shell is effectively looking for a complete command of '/opt/zenoss/local/change_summary_command.py  000c29d9-f87b-8309-11e2-a2be44f810f9' - which obviously doesn't exist.  Working Command Notification screenshot attached.

 

3) There have been changes between 4.2 and 4.2.3 with what environment variables actually get passed to the command notification.  In 4.2.3, if you dont pass ZENHOME explicitly then it is unset.  I think prior to 4.2.3 then ZENHOME did get passed without explicit invocation.  Safe answer is to always pass it.

 

command_notification_calling_python_script.jpg

Cheers,

Jane


Viewing all articles
Browse latest Browse all 1118

Trending Articles