Defrag All Partitions / Hard Drives Simultaneously

Two Easy Methods for Defragmentation

Harsh Gupta - Tech Writer
Defragmentation is a process by which contiguous memory is allotted to all the files stored on a hard drive. Here, 'memory' refers to the storage space of a hard drive. In other words, defragmentation is a process of arranging files that are fragmented on your hard drive. Fragmentation occurs when operating system does not allocate contiguous memory space to store a file as a complete unit. In other words, operating system creates gaps while storing these files because contiguous space is not available.

Defragmentation helps in solving the problem of defragmentation. Defragmentation is done by reorganizing the contents of the disk physically to store each file contiguously. Defragmenter places the smaller files within a single directory together, such that they can be accessed in sequence. There are system files that can't be moved from their location and these files are never moved and the same is decided by the operating system. Defragmentation can be done in 2 ways:

First Method:

This method is used to defrag one partition at a time. Go to 'Start Menu' and click 'Programs'. It will open a popup menu, now, click 'Accessories' and a new list of menu option will be opened. Now click on 'system tool'. Finally, click the 'Disk Defragmenter' option from the sub-menu.

A disk defragment window will appear and list the available partitions present on your hard drive. This window lists the total size of that particular partition and the available free space on that partition. First, select the drive that you want to defrag. Then, click on 'Analyze' tab. It will start analyzing the selected partitions/drive. After analyzing the select partitions or hard driver, it will ask you to defragment the partition or drive. After you select the defragment option, operating system will start arranging the files on select partitions or drive such that the data is arranged contiguously.

After the defragmentation process is over, it will show you the report of the defragmentation process along with a picture view of the defragmented partition or drive.

Second method:

With this method you can defrag all your hard drives or partitions at once. Actually, the drives are sequenced in order and all the process is carried out automatically. Thus, you don't have to instruct the computer for each and every partition or hard drive. It is done by creating a batch file that is created using command prompt.

Open 'Start Menu' and click 'Run'. Type 'cmd' and press Enter key to open 'command prompt' window. Finally, type defrag/? and a number of available parameters for that command will appear on your screen.

In order to execute the defragmentation process, we will create a batch file named defraga2.bat. You can later on execute the file whenever you want to defrag all your partitions or drive. In the command prompt window, type copy con defrag2.bat and press Enter Key.

Finally, add the following lines one by one depending on the number of hard drives or partitions you want to defrag. '-F' parameter is used to force defragmentation.

defrag c: -f
defrag d: -f
defrag e: -f

After you have entered the commands, press 'CTRL + Z' key to save the file. Now, type defrag2.bat and press 'Enter' key to execute the file and start the defragmentation process.

Published by Harsh Gupta - Tech Writer

I am a part time freelancer and writing is my hobby Some of my websites: http://www.GenericArticles.com http://www.JailBreakingiPhone.com  View profile

  • disk defragment window will appear and list the available partitions present on your hard drive.
After the defragmentation process is over, it will show you the report of the defragmentation process along with a picture view of the defragmented partition or drive.

1 Comments

Post a Comment
  • ParryHotter4/2/2008

    Defragging two or more partitions on the same *physical drive* simultaneously is pointless. There is only one actuator arm so it'll still take the same amount of time as defragging them one after the other.

    Defragging partitions on 2 separate physical drives simultaneously saves time.

    The batch file defrag method is still a sequential operation and not truly parallel, so it's not really accurate calling it 'simultaneous'.

    True simultaneous defrag helps to save time. The most efficient and easiest way to save time yet gain the maximum benefit of defragging is by using intelligent automatic defragmenters. The defragger runs as a background process and defragments when there are idle resources to do so...continuously. Just install it once and leave it alone...it'll do all the drives whenever it gets a chance. You never have to supervise it and wait for it to 'end' unlike the resource intensive and obsolete scheduled/manual defrag. Zero expenditure of time and manpower on the use

To comment, please sign in to your Yahoo! account, or sign up for a new account.