automateing defragmenting / scandisk

  • Thread starter Thread starter Brian Henry
  • Start date Start date
B

Brian Henry

Is there a way to automate defragmenting of a hard drive on a network? we
have 70 some systems, and want to tell them to defragment their hard drives,
and possibly run a scan disk maybe weekly at night, is there a group policy
or an active directory entry that can set this up? thanks!
 
Windows XP has a command-line utility defrag.exe which you can schedule.
Otherwise the best solution would be to use Diskkeeper from
ExecutiveSoftware. This tool has the ability to schedule disk
defragmentation.

--
Regards

Matjaz Ladava, MCSE (NT4 & 2000), MVP
(e-mail address removed)
http://ladava.com
 
how would you go about scheduleing it across a network though? I want to be
able to change the policy of all the computers to run it automaticly (like
an active directory entry or a group policy) that says when it runs that can
be centrally changed at the server level and affect all the client
computers. thanks
 
Brian,

Neither the built-in defragmenter in Win2k or WinXP can be network
managed/scheduled. In order to do so will require a 3rd party
defragmentation product.

- Greg/Raxco Software
Microsoft MVP - Windows Storage Management/File System

Disclaimer: I work for Raxco Software, the maker of PerfectDisk - a
commercial defrag utility, as a systems engineer in the support department.
 
-----Original Message-----
how would you go about scheduleing it across a network
though?

You would do that with the "at" command. For example, our
systems are set to delete profiles, scandisk, and defrag
every Monday @ 2am.

N:\>at \\intellab04
S ID Day Time Command Line
----------------------------------
1 Each M 2:30 AM c:\batch\clean\clean.cmd
2 Each M 3:00 AM c:\winnt\defrag.vbs


Relevant contents of clean.cmd:

c:\batch\shutdown /l /r /t:600 "Scheduled weekly
maintenance, please logout" /c
echo y | chkdsk c: /f
call c:\batch\clean\delprof /q /i
rem ** then some stuff to take ownership of, and delete
rem ** c:\temp etc etc


Relevant lines of defrag.vbs:

Set WshShell = WScript.CreateObject("WScript.Shell")
Return = WshShell.Run("c:\winnt\system32\defrag c: -f" ,
1, TRUE)
' Return values:
' 0: successful
' 1: defrag cancelled manually
' 2: command-line error
' 3: unknown error
' 4: insufficient memory
' 5: general error
' 6: system error
' 7: 15% free disk space requirement not met
 
Back
Top