CheckDisk SystemDrive
Edit script line 1 for number of failures before email is sent and line 2 for the email addrsss to send to. Script runs a standard chkdsk, it then looks for failures if failures found it checks how many failures have been reported before. Then either sends email and schedules a chkdsk /f or schedules a chkdsk and adds failure to registry. Procedure will check for user logged in (won’t detect RDP sessions). If no user is logged in it will reboot to run chkdsk /f. Writes to script log if successful. Able to report by filtering script log for $ChkDsk$ $Audit$ $OOD$
A version of this script that uses qwinsta.exe to detect RDP sessions on servers can be found here.
Search For More Scripts
View More results...