Page 1 of 1
chkdsk script for servers
Posted: Fri Nov 30, 2007 6:59 am
by jarmar
Hello. I am back for some more help. I have tried to use the chkdsk script that you have in the scriptvault but it errors everytime on line 36 char 5 which is
for /F "eol= tokens=1 delims=( " %%i in (DrvLtr.txt) do set DrvLtr=%%i & call :dsKchk
If this is able to be fixed is there a way to add a function to allow me to schedule this to multiple servers. just the same as the help you gave me on the central event log backups that is working great after all of your help?
thanks in advance.
jarred
chkdsk script for servers
Posted: Fri Nov 30, 2007 6:59 am
by jarmar
Hello. I am back for some more help. I have tried to use the chkdsk script that you have in the scriptvault but it errors everytime on line 36 char 5 which is
for /F "eol= tokens=1 delims=( " %%i in (DrvLtr.txt) do set DrvLtr=%%i & call :dsKchk
If this is able to be fixed is there a way to add a function to allow me to schedule this to multiple servers. just the same as the help you gave me on the central event log backups that is working great after all of your help?
thanks in advance.
jarred
chkdsk script for servers
Posted: Fri Nov 30, 2007 7:16 am
by jarmar
can i also add in that it does it to all local disks? thanks
chkdsk script for servers
Posted: Mon Dec 03, 2007 2:40 am
by jvierra
It is far easier to just create a single BAT file for each server with teh ChkDsk commands. Remember that volumes with open files will cause you to have to do a restart to get the chkdsk to run. Each server will end up having it's own particular set of rules. Some volumes will not require a restart if they can be checked out-of-hours as teh "F" option should force all files to be closed. Most programs will allow this without complaint but you will need to test it to be sure. If you choose this path then use task scheduler to schedule a single "chkdsk" command for each volume with the necessary switches. Drive that need restarting can be scheduled at any time and then schedule the restart as a separate task after setting the chkdsk scan on boot flag.
Jeff suggestion to use PowerShell is best if you need to do anything that is more sophisticated as PoSH makes this all much easier. jvierra2007-12-03 10:43:27
chkdsk script for servers
Posted: Mon Dec 03, 2007 2:54 am
by jarmar
Thank you for the advice. I appreciate it and will look into it.