Tripredacus, on Mar 21 2008, 07:51 AM, said:
I created a script that defrags a computers 2 volumes and then restarts. I am not using the /noprompt switch because when I did use it, the computer would reboot while it was running.
........
Now It just has a DOS box up with fragmentation stats on it but doesn't seem to be doing anything. The computer isn't locked up, but the HD LED is on constant. Task Manager shows 00:00 for CPU time for defrag.exe.
Is this normal for it to take a long time and not seem to be doing anything??
It only displays what it found before defragging. It is not a dynamic page. It does take a while depending on a lot of different factors. If you want a dynamic display from the command line, use DirMS.
As far as the restart while it runs, try using this:
start /wait defrag c: -f
The "start /wait" tells windows to run the command, but wait for it to finish to run the next command.
Hope this helps.