Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
Jdavis

server notifying

Recommended Posts

Posted · Original PosterOP

Is there a way to make windows server 2016 to email me or something to tell me when it rebooted. And/Or open up programs in a certain order? I don't ever know when it reboots until I login to it or try to access files.

Link to post
Share on other sites

use pulseway. Its one of LTTs sponsors and its dose what you want it to. Its free if you use it with only 3 server/computers.


Ready

0 print "fartz"

10 goto 0

run

fartz

fartz

fartz

fartz

fartz

fartz

fartz

fartz

fartz

fartz

fartz

fartz

Ctrl-break

Ready

Link to post
Share on other sites
Posted · Original PosterOP

After a couple of tweaks to the registry to enable auto login sat up it's working perfectly. Thank you!

Link to post
Share on other sites
$SmtpFrom = "YourServer <YourServer@domain.tld>"
$SmtpRecipient = "Lastname, Firstname <YourMailAddress@domain.tld>"
$SmtpServer = "your.mail.server"
$SmtpPort = 587
$SmtpSubject = "Reboot has occured"
$SmtpBody = "The machine " + $env:computername + " has rebooted."

Send-MailMessage -From $SmtpFrom -To $SmtpRecipient -SmtpServer $SmtpServer -Subject $SmtpSubject -Body $SmtpBody -Port $SmtpPort -encoding ([System.Text.Encoding]::UTF8)

Save as a .ps1, put it somewhere on the server, create a new task schedular task to run this upon boot

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now


×