arboeglin at herffjones
Aug 10, 2012, 8:25 AM
Post #3 of 7
On Fri, Aug 10, 2012 at 09:47:29, Nathan Kinkade wrote:
RE: Remote access to varnish stats / nagios and varnish
[In reply to]
> Cc: varnish-misc [at] varnish-cache
> Subject: Re: Remote access to varnish stats / nagios and varnish
> On Fri, Aug 10, 2012 at 7:00 AM, Oddur SnĂ¦r MagnĂşsson
> <oddur [at] ccpgames> wrote:
> > Hi,
> > I want to monitor some varnishstats (cache hits/misses/bandwith)
> > from my
> varnish instances with nagios. Iâ€™ve found this
> https://github.com/varnish/varnish-nagios/commits/master but it seems
> you are running varnish and nagios on the same machine (or using a
> npre agent on the varnish box).
> > What would be ideal for me is to expose a single url that just
> > responds with
> counter values, possibly just the full output of â€śvarnishstat â€“xâ€ť.
> > Very similar to http://wiki.nginx.org/NginxHttpStubStatusModule for
> > If itâ€™s possible to access to counter values using inline C, I guess
> > this would
> be possible using that.
> > Best regards,
> > Oddur SnĂ¦r MagnĂşsson
> > Senior Programmer | ReykjavĂk | Iceland
> I feel like I may be missing something in what you're looking for, but
> if all you want is a URL that produces the output of `varnishstat -x`,
> then it seems trivial to write a practically one line CGI script for
> this purpose. Or to have a cron job dump the output to a text file in
> your webroot every so often, and then just accessing that file directly when you need it.
> varnish-misc mailing list
> varnish-misc [at] varnish-cache
I think the most simple option would be to just use the Nagios check_by_ssh plugin to run the varnish-nagios command on the remote system.
varnish-misc mailing list
varnish-misc [at] varnish-cache