Page 1 of 1

Script to notify when system is up x days

Posted: Mon Aug 15, 2016 6:00 am
by hoffman2503
Hi team,

I was wondering, if any of you knows any script can run on Windows to notify Nagios to notify the users when the Windows is up 90 days and post a custom alert message?

Thanks for all your time.
hoffman2503

Re: Script to notify when system is up x days

Posted: Mon Aug 15, 2016 1:06 pm
by rkennedy
It's a bit beyond the support we can provide, but you should be able to modify this powershell script to work for your needs. It'll output the variable uptime at the end, which you could use to set up your own if conditions.

http://ss64.com/ps/syntax-get-uptime.html