How To: Set up to automatically defragment
Learn from our various Guides, plus check out our FAQ's and How To's. There is something for everyone. Share what you know and add to the collection.

Moderators: Management, Forum Experts

Postby gries818 on Sat May 13, 2006 4:07 pm

well after doing some work with Vista I can say the defragmentor is set up to run automatically without batch files. however the program gives you much less info then windows xp does. still have yet to try it with the command prompt.
Image

Mac OS 10.5.7 - Personal
Ubuntu Server 9.04 - Server
User avatar
gries818
Support Team
 
Posts: 6022
Joined: Wed Jul 07, 2004 2:28 pm

Postby kd1966 on Sat May 13, 2006 5:10 pm

I'm getting the "feeling" that the Vista defrag is a "RunOnce" type of program on the first boot; I have yet to see it running again. I have done the -b option in Vista and after a couple of those it seems to boot a bit quicker (5381)
User avatar
kd1966
PRO MASTER
PRO MASTER
 
Posts: 8081
Joined: Mon Aug 08, 2005 10:00 pm
Location: USA - GSO - NC

Postby gries818 on Sat May 13, 2006 6:41 pm

no, go to My Computer-(the drive you have Vista installed on)-Properties-Tools-Defragment and it comes up with a dialog asking/telling you when the auto Defragment is. At least thats the way I remember it... Next time I boot into Vista I will check.
Image

Mac OS 10.5.7 - Personal
Ubuntu Server 9.04 - Server
User avatar
gries818
Support Team
 
Posts: 6022
Joined: Wed Jul 07, 2004 2:28 pm

Postby gries818 on Sun May 14, 2006 8:13 pm

gries818 wrote:still have yet to try it with the command prompt.


currently its the same output for the command prompt.
Image

Mac OS 10.5.7 - Personal
Ubuntu Server 9.04 - Server
User avatar
gries818
Support Team
 
Posts: 6022
Joined: Wed Jul 07, 2004 2:28 pm

i made improvements...

Postby l33t on Fri Jun 23, 2006 4:38 pm

i hate to dig this back up, but i didint want to start a new thread.

i made improvments, to the origional script i posted
now the script defragments 10 times... and thats the magic number that i found to get EVERYTHING defragmented...

soooo just copy the text below, save it as def.bat , and put it in your C:\windows folder, and to run it... at the run prompt (winkey + R) type def DEIVE LETTER:

sooo lets say i wanted to defrag my c: drive.
i would type
Code: Select all
def C:


enjoy!
here is the code.

Code: Select all
@echo off
title DEFRAGGER %1%
color 0a
echo i am a defragging utility, i will defragment your hard disk.  this will perform 10 passes!
echo the first paramater must be passed on as a capitol letter, and have a ":"!!! this is IMPORTANT!!!!

echo the drive letter is %1% , i hope this is right!

title %1% pass 1
defrag %1% -b
defrag %1% -v

title %1% pass 2
defrag %1% -b
defrag %1% -v

title %1% pass 3
defrag %1% -b
defrag %1% -v

title %1% pass 4
defrag %1% -b
defrag %1% -v

title %1% pass 5
defrag %1% -b
defrag %1% -v
'
title %1% pass 6
defrag %1% -b
defrag %1% -v

title %1% pass 7
defrag %1% -b
defrag %1% -v

title %1% pass 8
defrag %1% -b
defrag %1% -v

title %1% pass 9
defrag %1% -b
defrag %1% -v

title %1% pass 10
defrag %1% -b
defrag %1% -v
title DONE
pause

echo DONE
User avatar
l33t
PRO Level 14
PRO Level 14
 
Posts: 974
Joined: Sun May 01, 2005 10:06 pm

Postby gries818 on Fri Jun 23, 2006 4:49 pm

^*^
Image

Mac OS 10.5.7 - Personal
Ubuntu Server 9.04 - Server
User avatar
gries818
Support Team
 
Posts: 6022
Joined: Wed Jul 07, 2004 2:28 pm

Postby c0ldfyr3 on Sun Dec 17, 2006 11:21 am

l33t can i use this same code to defrag multiple drives? if so how. i am a little rusty on commands for DOS.
An Expert is some one who has made all the mistakes that can be made in a very narrow filed *** Niels Bohr ***
User avatar
c0ldfyr3
PRO Level 17
PRO Level 17
 
Posts: 2483
Joined: Sun May 02, 2004 4:49 pm
Location: 127.0.0.1

Postby gries818 on Sun Dec 17, 2006 11:34 am

c0ldfyr3 wrote:l33t can i use this same code to defrag multiple drives? if so how. i am a little rusty on commands for DOS.


yeah you could. i am also rusty though i can't really remember. i remember i had trouble with drive letters.
Image

Mac OS 10.5.7 - Personal
Ubuntu Server 9.04 - Server
User avatar
gries818
Support Team
 
Posts: 6022
Joined: Wed Jul 07, 2004 2:28 pm

Postby c0ldfyr3 on Sun Dec 17, 2006 11:46 am

would it be

Code: Select all
def C: ; B:
An Expert is some one who has made all the mistakes that can be made in a very narrow filed *** Niels Bohr ***
User avatar
c0ldfyr3
PRO Level 17
PRO Level 17
 
Posts: 2483
Joined: Sun May 02, 2004 4:49 pm
Location: 127.0.0.1

Postby l33t on Sun Dec 17, 2006 1:10 pm

c0ldfyr3 wrote:would it be

Code: Select all
def C: ; B:


i am not in windows ATM an cannot test this, however, i don't think that would work as my "program" just passes the first command line argument to the command "defrag" in the form of a drive letter.

all my
User avatar
l33t
PRO Level 14
PRO Level 14
 
Posts: 974
Joined: Sun May 01, 2005 10:06 pm

PreviousNext

Return to Guides and How To

Who is online

Users browsing this forum: No registered users and 0 guests