Querying nagios object information through command line

Wenhua Zhang shiziwen at gmail.com
Fri May 18 04:59:00 CEST 2012


Hi Yu,
If you have any problem or idea about status-txt(or status-json and
statusXML), please fill free to let me know.


2012/5/17 Yu Watanabe <yu.watanabe at jp.fujitsu.com>:
> Hi Wenhua
>
> This looks interesting as well.
> I will take a look at it.
>
> Thanks,
> Yu
>
> Wenhua Zhang ¤µ¤ó¤Ï•ø¤­¤Þ¤·¤¿:
>>Hi Yu,
>>I think status-txt may do some help for you.
>>status-txt is implemented to duplicate the output of status.cgi in
>>plain text to achieve this goal, making it easier for other
>>applications/services to use Nagios data. You can also get the source
>>code from github "https://github.com/shiziwen/nagios-status2txt".
>>
>>Besides plain text, there have been some other format you can use, XML and JSON.
>>JOSN: http://exchange.nagios.org/directory/Addons/APIs/JSON/status-2Djson/details
>>XML: http://svn.jasonantman.com/nagios-xml/statusXML-krzywanski.php,
>>and this(c version of nagios-xml:
>>http://svn.jasonantman.com/nagios-xml/php_module/), which maybe more
>>usefull for light-weight or high-performance purpose.
>>
>>I hope it can do some help for you.
>>
>>2012/5/17 Yu Watanabe <yu.watanabe at jp.fujitsu.com>:
>>> Benny , Ritchie , Daniel
>>>
>>> Thank you for the advice.
>>>
>>> I will take a look at the mklivestatus.
>>>
>>> Thanks.
>>> Yu
>>>
>>> C. Bensend ¡¢¥ª¡¢¡þ¥Þ±§¡¢¥å¡¢©a¡¢¥­¡¢¥½:
>>>>
>>>>> Is there a script or a module that can be called through a command line
>>>>> and can retrieve nagios object definition , host , service?
>>>>>
>>>>> I am thinking of calling from php program.
>>>>>
>>>>> I found that config.cgi has an ability of fetching the object definition
>>>>> but it seems that it returns html info.
>>>>>
>>>>> It would be helpful if someone can share their thoughts.
>>>>
>>>>Livestatus can do this, and it's MUCH quicker/more lightweight/better
>>>>(IMHO) than NDOUtils.
>>>>
>>>>http://mathias-kettner.de/checkmk_livestatus.html
>>>>
>>>>Benny
>>>>
>>>>
>>>>--
>>>>"The problem with quotes on the internet is that it's very hard to
>>>>verify their authenticity."       -- Abraham Lincoln
>>>>
>>>>
>>>>
>>>>------------------------------------------------------------------------------
>>>>Live Security Virtual Conference
>>>>Exclusive live event will cover all the ways today's security and
>>>>threat landscape has changed and how IT managers can respond. Discussions
>>>>will include endpoint security, mobile security and the latest in malware
>>>>threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
>>>>_______________________________________________
>>>>Nagios-users mailing list
>>>>Nagios-users at lists.sourceforge.net
>>>>https://lists.sourceforge.net/lists/listinfo/nagios-users
>>>>::: Please include Nagios version, plugin version (-v) and OS when reporting any issue.
>>>>::: Messages without supporting info will risk being sent to /dev/null
>>>
>>>
>>> ------------------------------------------------------------------------------
>>> Live Security Virtual Conference
>>> Exclusive live event will cover all the ways today's security and
>>> threat landscape has changed and how IT managers can respond. Discussions
>>> will include endpoint security, mobile security and the latest in malware
>>> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
>>> _______________________________________________
>>> Nagios-users mailing list
>>> Nagios-users at lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/nagios-users
>>> ::: Please include Nagios version, plugin version (-v) and OS when reporting any issue.
>>> ::: Messages without supporting info will risk being sent to /dev/null
>>
>>______________________________________________________________________
>>
>>------------------------------------------------------------------------------
>>Live Security Virtual Conference
>>Exclusive live event will cover all the ways today's security and
>>threat landscape has changed and how IT managers can respond. Discussions
>>will include endpoint security, mobile security and the latest in malware
>>threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
>>______________________________________________________________________
>>
>>_______________________________________________
>>Nagios-users mailing list
>>Nagios-users at lists.sourceforge.net
>>https://lists.sourceforge.net/lists/listinfo/nagios-users
>>::: Please include Nagios version, plugin version (-v) and OS when reporting any issue.
>>::: Messages without supporting info will risk being sent to /dev/null
>
>
> ------------------------------------------------------------------------------
> Live Security Virtual Conference
> Exclusive live event will cover all the ways today's security and
> threat landscape has changed and how IT managers can respond. Discussions
> will include endpoint security, mobile security and the latest in malware
> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
> _______________________________________________
> Nagios-users mailing list
> Nagios-users at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/nagios-users
> ::: Please include Nagios version, plugin version (-v) and OS when reporting any issue.
> ::: Messages without supporting info will risk being sent to /dev/null

-------------- next part --------------
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
-------------- next part --------------
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null


More information about the Users mailing list