treii28
Posts: 93
Joined: Fri May 10, 2013 4:52 pm

Best simple ways to check system heartbeats via network

Fri Aug 12, 2016 6:01 pm

I did some quick google searches to see if there were any really low-resource, minimal basic heartbeat servers available. I imagine I could do something with a combination of ping, lighttpd, and ssh to get an idea if a) a system is on the net, b) if it's basic services are running and c) if it's accessible but I was wondering if there was anything that was really really small but still basically secure that I could set up, perhaps with a short script to do all or most of the above from a simple restful call?

I'm just wondering what others might have done for this sort of thing. My primary purpose for doing this is that I just set up my growing stable of raspberry pi's on an ESP8266 based wifi relay switch. But I would like to set up the interface so that it will try to see if the system is actually responding in addition to the power being on, and perhaps add features to try safe-shutdowns vs. a hard power off. It would also be nice when switching one back on if my web page could watch for it to become active, perhaps flagging various images or CSS table/div cells to indicate various status conditions (on network, ssh working, etc)

As I say, I have some of my own ideas but before I go redesigning the wheel, I figured I'd check to make sure there isn't something already out there.

SonOfAMotherlessGoat
Posts: 690
Joined: Tue Jun 16, 2015 6:01 am

Re: Best simple ways to check system heartbeats via network

Fri Aug 12, 2016 7:37 pm

Would nmap be of use in this instance? You could scan the subnet, find the active nodes and then portscan the active nodes and get back the banner/header/response from the daemons on the active ports. With a little more work you could probably differentiate the RasPis based on MAC and only interrogate the Pis.
Account Inactive

stderr
Posts: 2178
Joined: Sat Dec 01, 2012 11:29 pm

Re: Best simple ways to check system heartbeats via network

Fri Aug 12, 2016 8:25 pm

treii28 wrote:I did some quick google searches to see if there were any really low-resource, minimal basic heartbeat servers available. I imagine I could do something with a combination of ping, lighttpd, and ssh to get an idea if a) a system is on the net, b) if it's basic services are running and c) if it's accessible but I was wondering if there was anything that was really really small
All you need is ping. I think the Beatles said that. Just have each node ping out to the control system, which I think Frank Zappa termed the "Central Scrutinizer", the health state of that system. Use tcpdump to monitor the ping data package, what could be more lightweight, Justin Bieber?

Return to “Networking and servers”