It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

nagios alert messages not appearing in hipchat chat window.


Thanks for the reply. I have put the below entries in nagios commands.cfg file I am running Nagios 3.4.4 on CentOS 6.4.

define command {
command_name notify-host-by-hipchat
command_line /usr/bin/hipsaint
--token=c29bab160e8e6a4f3ca39ba6fe7c1d --room=67307 --type=host
define command {
command_name notify-service-by-hipchat
command_line /usr/bin/hipsaint
--token=c29bab160e8e6a4f3ca39ba6fe7c1d --room=67307 --type=service

I am unable to see any nagios alert messages in hipchat window. Please let me know if anyone needs more information.



3 answers

/usr/bin/hipsaint --token=c29bab160e8e6a4f3ca39ba6fe7c1d --room=67307 --type=service --inputs="$SERVICEDESC$|$HOSTALIAS$|$LONGDATETIME$|$NOTIFICATIONTYPE$|$HOSTADDRESS$|$SERVICESTATE$|$SERVICEOUTPUT$"
when i run the below command replacing all macros, I get the below issue.
[nagios@nagios ~]$ id
uid=502(nagios) gid=502(nagios) groups=502(nagios),503(nagcmd)
[nagios@nagios ~]$ /usr/bin/hipsaint --token=c29bab160e8e6a4f3ca39ba6fe7c1d --room=67307 --type=service --inputs="Main Website solr Wed Jul 31 20:42:28 IST 2013 Recovery Recovery Ping OK"
Traceback (most recent call last):
File "/usr/bin/hipsaint", line 9, in <module>
load_entry_point('hipsaint==0.4', 'console_scripts', 'hipsaint')()
File "/usr/lib/python2.6/site-packages/hipsaint-0.4-py2.6.egg/hipsaint/bin/", line 55, in main
File "/usr/lib/python2.6/site-packages/hipsaint-0.4-py2.6.egg/hipsaint/", line 29, in deliver_payload
message_body = self.render_message()
File "/usr/lib/python2.6/site-packages/hipsaint-0.4-py2.6.egg/hipsaint/", line 56, in render_message
servicedesc, hostalias, timestamp, ntype, hostaddress, state, serviceoutput = self.inputs.split('|')
ValueError: need more than 1 value to unpack
[nagios@nagios ~]$
Please suggest further

Hello Kaushal,

Author of the nagios hipchat python library here. You're getting this error message because you're missing pipes | as separators between each variable.

It should look like this:

hipsaint --token=[INSERT TOKEN] --room=[INSERT ROOM ID] --type=service --inputs="Main Website|solr|Wed Jul 31 20:42:28 IST 2013|RECOVERY||OK|Ping OK"

Good luck!

I receive a similar trace as well:


 File "/bin/hipsaint", line 11, in <module>


  File "/usr/lib/python2.7/site-packages/hipsaint/bin/", line 78, in main


  File "/usr/lib/python2.7/site-packages/hipsaint/", line 68, in deliver_payload_v1

    raw_response = urlopen(self.urlv1, message_params)

  File "/usr/lib64/python2.7/", line 154, in urlopen

    return, data, timeout)

  File "/usr/lib64/python2.7/", line 437, in open

    response = meth(req, response)

  File "/usr/lib64/python2.7/", line 550, in http_response

    'http', request, response, code, msg, hdrs)

  File "/usr/lib64/python2.7/", line 475, in error

    return self._call_chain(*args)

  File "/usr/lib64/python2.7/", line 409, in _call_chain

    result = func(*args)

  File "/usr/lib64/python2.7/", line 558, in http_error_default

    raise HTTPError(req.get_full_url(), code, msg, hdrs, fp)

urllib2.HTTPError: HTTP Error 401: Unauthorized



Any resolution on this?





Suggest an answer

Log in or Sign up to answer
Community showcase
Published in Hipchat

Hipchat Cloud and Stride have reached End of Life (updated)

All good things come to an end - thanks to all our customers and partners who have been along the Hipchat and Stride journey with us.  As of Feb 15th 2019, Hipchat Cloud and Stride have reached ...

35,181 views 9 8
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you