Use Modem to Call Phone Number
Hi Folks,
I've been having some issues with two of our linux servers (they just mysteriously stop responding at random times - brand new, have tried replacing all the parts). Anyway, I think I have the problem fixed, but it has brought up an interesting problem: I don't know when they go down. We have some modems that we've salvaged from various operations, and I'd like to know if there is a way to use one of said modems (or just buy a new one - external of course) to call me when I run a command (i.e. if the server doesn't respond to a ping for over 30 seconds, call me). I was assuming that mgetty/vgetty could do that, but I didn't find any hard evidence saying it could. Any thoughts on this? And on a side note, any modems that are particularly recommended? Thanks, Stephen |
Take a look at minicom. I know that minicom will do what you want if somebody types in the commands. Minicom has a script feature which I have never used where it runs a script at startup without human intervention. Something like:
minicom -S /root/commands/minicom.script You might be able to do what you want with a minicom script. ----------------------- Steve Stites |
This is kind of a 'wrap up' of what I ended up doing. Because I didn't want to waste any money on a USB modem (if it didn't work, we'd be throwing it into the box of oblivion) I started looking for other alternatives to getting a message to me via phone. I was looking through Webmin, and lo and behold there was an option to send a text message to my phone! It was under 'System and Server Status'. So, all of my servers are hooked into a master server via webmin now. A warning to whoever may want to set this up: make sure that it only notifies you when a system goes down. Do not have it notify you ever X minutes. I ended up getting about 108 text messages from my server when one of them was down for a day. Other than that though, it works perfectly. Thanks Webmin :)
|
All times are GMT -5. The time now is 05:56 AM. |