Is there a way to determine whether a RHEL7 server was rebooted via systemctl (or reboot / shutdown aliases), or whether the server crashed? Pre-systemd this was fairly easy to determine with last -x runlevel
, but with RHEL7 it's not so clear.
ipmitool differs a lot in Solaris and Linux. How can I use ipmitool in these servers (on Sun, IBM and other hardwares) to detect the power supply status?
What are you all doing to monitor ESXi servers that run the free edition? With the lack of SNMP support, it seems fairly limited to me. What'd I'd like to be able to do is get some type of alert when a drive or other hardware fails. I've seen a few articles on getting OpenManage installed on an ESXi box (to rebuild an array), but it seems to be quite a pain as well. Even if I get OpenManage working, I won't have alerts without SNMP.
Any comments, input, or guidance would be greatly appreciated.
I'm trying to find a reliable way of finding which process on my machine is changing a configuration file (/etc/hosts
to be specific).
I know I can use lsof /etc/hosts
to find out what processes currently have the file open, but this doesn't help because the process is obviously opening the file, writing to it, and then closing it again.
I also looked at lsof
's repeat option (-r), but it seems to only go as fast as once a second, which probably won't ever capture the write in progress.
I know of a couple tools for monitoring changes to the filesystem, but in this case I want to know which process is responsible, which means catching it in the act.
I'm a lone web developer with my own Centos VPS hosting a few small web sites for my clients. Today I discovered my httpd service had stopped (for no apparent reason - but that's another thread). I restarted it but now I need to find a way that I can be notified by email and/or SMS if it happens again - I don't like it when my client rings me to tell me their web site doesn't work!
I know there are probably many different possibilities, including server monitoring software. I think all I really need is a script that I can run as a cron job from my dev host (which is permanently running in my office) that attempts to load a page from my production server and if it doesn't load within say 30 seconds then it sends me an email or SMS. I'm pretty rubbish at shell scripting, hence this question.
Any suggestions would be gratefully appreciated.