I'm looking for the poor man's monitoring solution. I have a Hyper-V 2008 R2 environment where power fluctuations at off-peak hours are pretty common. The battery keeps the box up for a fair amount of time. I'm working on a solution to have the battery issue shutdown commands to the box for a best solution but I'd like to get a simple monitoring solution in place to monitor the status of the virtual machines.
Essentially something like this:
- Power Goes Out.
- Power is eventually restored.
- Server automatically restarts (On Power Restore).
- Virtual Machines should restart (From off or saved based on settings in Hyper-V).
- Task Scheduler runs a task every hour or so and checks for Virtual Machines that are not started.
- If the machines are not started it sends a message, prefer SMTP to alert someone to check it.
I'm not exactly sure how best to accomplish the check of the VMs. Do I issue a CLI or PS script that has a return code the task scheduler can then make a decision on or use some other method?
I'm looking to use the built-in Windows tools as this seems like something that should be accomplishable. If not thats fine, alternates are great too. And yes, I want a free way to do this. Not looking to spend any cash here, or implement some giant tool like Nagios for this seemingly small problem.
If I'm crazy thats fine too!