There is a plugin for Nagios called check_ice that you can also just compile and run standalone. See: https://github.com/pozar/check_ice On Sun, Apr 12, 2015 at 7:50 PM, Dean Sauer <wemanageitfl at gmail.com> wrote:> On Sat, 11 Apr 2015 07:03:16 +0000, Philipp Schafft wrote: > > > You can request /admin/stats.xml. That file will return the overall > > server status including per source information. If the server returns > > 200 with the expected XML document the server is up and running. > > Thanks, my pseudo code already determined that and the underlying issue. > > If I query the server on port 8000 and get 200, then its up/running... > > Now the sources... > > > > You can > > look at the <source> tags to find out if the sources are connected. > > Thanks, but no I am not scraping/parsing that. I despise the whole > concept of "scraping" sites like this, there is already one piece of > software doing this as it is in my arena. > > doing a: > > urllib.urlopen("http://domain/source").getcode() > > just returns a 200 even if the actual source is down, and the source is > on a fall back. If I were following http expectations I should get 302, > temp redirection as used widely, or 307 if you stick to the strict > standard. > > Sadly right now the simple check that IceCast is UP will have to suffice, > and covers the main problem, right now. > > _______________________________________________ > Icecast mailing list > Icecast at xiph.org > http://lists.xiph.org/mailman/listinfo/icecast >-------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.xiph.org/pipermail/icecast/attachments/20150412/5024f17d/attachment.htm
Here can take a look other alternative: https://github.com/cdgraff/icecast-mon We base our solution in avprobe/ffprobe, this test like a real listener. Feedback is welcome! this is just first release, but we use on production. Regards, Alejandro 2015-04-12 22:26 GMT-03:00 Dave Pascoe <davekm3t at gmail.com>:> There is a plugin for Nagios called check_ice that you can also just > compile and run standalone. > > See: https://github.com/pozar/check_ice > > > On Sun, Apr 12, 2015 at 7:50 PM, Dean Sauer <wemanageitfl at gmail.com> > wrote: > >> On Sat, 11 Apr 2015 07:03:16 +0000, Philipp Schafft wrote: >> >> > You can request /admin/stats.xml. That file will return the overall >> > server status including per source information. If the server returns >> > 200 with the expected XML document the server is up and running. >> >> Thanks, my pseudo code already determined that and the underlying issue. >> >> If I query the server on port 8000 and get 200, then its up/running... >> >> Now the sources... >> >> >> > You can >> > look at the <source> tags to find out if the sources are connected. >> >> Thanks, but no I am not scraping/parsing that. I despise the whole >> concept of "scraping" sites like this, there is already one piece of >> software doing this as it is in my arena. >> >> doing a: >> >> urllib.urlopen("http://domain/source").getcode() >> >> just returns a 200 even if the actual source is down, and the source is >> on a fall back. If I were following http expectations I should get 302, >> temp redirection as used widely, or 307 if you stick to the strict >> standard. >> >> Sadly right now the simple check that IceCast is UP will have to suffice, >> and covers the main problem, right now. >> >> _______________________________________________ >> Icecast mailing list >> Icecast at xiph.org >> http://lists.xiph.org/mailman/listinfo/icecast >> > > > _______________________________________________ > Icecast mailing list > Icecast at xiph.org > http://lists.xiph.org/mailman/listinfo/icecast > >-------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.xiph.org/pipermail/icecast/attachments/20150412/727629ac/attachment.htm
Philipp Schafft
2015-Apr-13 07:55 UTC
[Icecast] Check feed connected, active - IceCast 2.4.x
reflum, On Sun, 2015-04-12 at 22:55 -0300, Alejandro wrote:> Here can take a look other > alternative: https://github.com/cdgraff/icecast-monThank you for sharing!> We base our solution in avprobe/ffprobe, this test like a real > listener. > > > Feedback is welcome! this is just first release, but we use on > production.Have a little bit of feedback. :) in icecast_mon.py:80 you construct a string with an URL embedded. in icecast_mon.py:83 you split it again. I think you would be better off by constructing an array directly. The current implementation may be prone to errors based on meta characters in the URL. (This isn't super unlikely. Already had a similar case on a Icecast setup myself where mount points contained such special characters.) Thank you for your work! -- Philipp. (Rah of PH2) -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 490 bytes Desc: This is a digitally signed message part Url : http://lists.xiph.org/pipermail/icecast/attachments/20150413/445a7ea3/attachment-0001.pgp