Scripting library for monitoring server health?
Asked Answered
N

3

6

Is there a scripting library preferably in Python/Perl/Ruby that allows you to get information on disk, load, a list of processes running, cpu usage in a standard way?

I always end up parsing df, uptime, ps etc. Given that these differ on different Unix flavors and need to be done in a totally different way on Windows, I would have thought that someone would have already done this.

Nonentity answered 4/1, 2012 at 1:7 Comment(2)
I think someone gave a talk at an Australian Railscamp about one. I can't remember any details, though.Dreddy
you could call out to the "sar" command or others...linuxadmintips.wordpress.com/2011/03/05/…Campney
G
2

(ruby) Daniel Berger maintains a lot of gems in this field. Look for sys-cpu, sys-uptime, sys-uname, sys-proctable, sys-host, sys-admin, sys-filesystem - all multi-platform AFAIK.

Gardie answered 4/1, 2012 at 1:39 Comment(0)
M
6

Most simple is monit: http://mmonit.com/monit/

A step up, as @lawrencealan mentioned, is Nagios: http://nagios.org/

And here's a new interesting effort: http://amon.cx/

Megganmeggi answered 4/1, 2012 at 1:18 Comment(3)
All three are not scripting libraries that can easily be incorporated into own code - or?Encircle
Just in case I am missing something. Do any of the packages come with a scripting library that exposes the system info in a standard way?Nonentity
Not that I know of -- I guess I didn't understand what you were looking for. :)Megganmeggi
G
2

(ruby) Daniel Berger maintains a lot of gems in this field. Look for sys-cpu, sys-uptime, sys-uname, sys-proctable, sys-host, sys-admin, sys-filesystem - all multi-platform AFAIK.

Gardie answered 4/1, 2012 at 1:39 Comment(0)
C
0

Have you looked into Nagios? http://nagios.org/

There are an abundance of agents: http://exchange.nagios.org/directory/Addons/Monitoring-Agents

Chilly answered 4/1, 2012 at 1:11 Comment(1)
Just in case I am missing something. Does Nagios come with a scripting library that exposes the system info in a standard way?Nonentity

© 2022 - 2024 — McMap. All rights reserved.