الصفحات :      العودة إلى  مدرسة الكمبيوتر     قسم  الصيانة   الصفحة الأولى

Low-Level Format, Zero-Fill and Diagnostic Utilities

Older hard disks required periodic low-level formatting by the system configurator or end-user. To facilitate this, low-level format utilities were created. These are small programs written to control the low-level formatting process for the hard disk. The hard disk controller would normally include one of these programs in a ROM chip in hardware, enabling access to the software without requiring any drives to be running in the system, and thus avoiding a possible "chicken and egg" quandary. In addition, more sophisticated, third-party utilities were available that would perform an LLF and also do other related features such as scanning for bad sectors or analyzing the drive to determine an optimal interleave setting. These would typically be loaded from a floppy disk.www.tartoos.com

Low-level formatting an older hard disk could be a rather complicated procedure, particularly for one who was not very familiar with PCs and hard disks. Various factors needed to be taken into account, such as defect mapping and setting the interleave factor. The particular conditions of the drive when formatting were also important: due to the vagaries of stepper-motor actuators, doing an LLF when the drive was very cold or very hot could lead to errors when the drive returned to a more normal temperature. Even the orientation of the drive when it was formatted was an issue.www.tartoos.com

As I have said (probably too often, sorry) modern drives do not need to be low-level formatted by the end user, and in fact cannot be LLFed outside the factory due to their precision and complexity. However, it seems that the need to LLF hard disks on the part of users has never gone away. Like some primordial instinct, many PC users seem to have a fundamental desire to LLF their modern disks. Maybe it is built into the genetic code in some way yet undiscovered. ;^) In fact, even if it were possible, the vast majority of the time that someone "needs" to LLF a hard disk today, it is not really necessary. Many users jump quickly to wanting to try an "LLF" whenever they have a problem with their hard disk, much the way many jump to re-installing their operating system whenever it gives them trouble.www.tartoos.com

Hard drive manufacturers have created for modern drives replacements for the old LLF utilities. They cause some confusion, because they are often still called "low-level format" utilities. The name is incorrect because, again, no utility that a user can run on a PC can LLF a modern drive. A more proper name for this sort of program is a zero-fill and diagnostic utility. This software does work on the drive at a low level, usually including the following functions (and perhaps others):

  • Drive Recognition Test: Lets you test to see if the software can "see" the drive. This is the first step in ensuring that the drive is properly installed and connected.
  • Display Drive Details: Tells you detailed information about the drive, such as its exact model number, firmware revision level, date of manufacture, etc.
  • Test For Errors: Analyzes the entire surface of the hard disk, looking for problem areas (bad sectors) and instructing the integrated drive controller to remap them.
  • Zero-Fill: Wipes off all data on the drive by filling every sector with zeroes. Normally a test for errors (as above) is done at the same time. www.tartoos.com

When most users today talk about "low-level formatting" a drive, what they are really talking about is doing a zero-fill. That procedure will restore a functional drive (that is, one that does not have mechanical problems) to the condition it was in when received from the factory. There are occasions when a modern hard disk can become so badly corrupted that the operating system cannot recover it, and a zero-fill can help in this situation. Stubborn boot sector viruses for example can be hard to eradicate without resorting to low-level intervention. Since the zero-fill cleans all programs and data off the drive it will get rid of almost any data-related problem on the drive, such as viruses, corrupted partitions and the like. Just remember that it's a bit like burning down your house to get rid of termites: you lose everything on the drive.

This type of utility can also be used to "hide" bad sectors by telling the drive to remap them to its collection of spares. Just remember that a drive that continues to "grow" bad sectors over time is one whose reliability is highly suspect.

Warning: Only use a low-level zero-fill or diagnostic utility designed for your particular hard disk. You can download one for free from your drive manufacturer's web site. Even though damage probably won't result from using the wrong program, you may lose data and you may also complicate any warranty service you try to have performed on the drive. (Technical support people at "Company X" generally don't like to hear that you used a utility on their drive written by "Company Y".)www.tartoos.com
 

Warning: Always back up your data before you use a low-level utility, and make sure that you carefully follow all of the instructions provided.
 

Warning: Never run a low-level disk utility from within a multi-tasking operating system such as Windows 9x. Other programs running in the background could interfere with the utility. Restart the computer in MS-DOS mode first, or reboot the computer from a floppy.
 

Unformatted and Formatted Capacity

Some portion of the space on a hard disk is taken up by the formatting information that marks the start and end of sectors, ECC, and other "overhead". For this reason, a hard disk's storage total depends on if you are looking at the formatted or unformatted capacity. The difference can be quite significant: 20% or even more.www.tartoos.com

Older drives that were typically low-level formatted by the user, often had their size listed in terms of unformatted capacity. For example, take the Seagate ST-412, the first drive used on the original IBM PC/XT in the early 1980s. The "12" in this model number refers to the drive's unformatted capacity of 12.76 MB. Formatted, it is actually a 10.65 MB drive.

Now, let's be honest: stating the capacity of the hard disk in unformatted terms is lame. Since nobody can use a drive that is unformatted, the only thing that matters is the formatted capacity. Stating the drive in terms of unformatted capacity is not quite as bad as how tape drive manufacturers always report the size of their drives assuming 2:1 compression, of course. But it's still lame. :^)

Fortunately, this is no longer an issue today. Since modern drives are always low-level formatted at the factory, it would be extremely weird to state their sizes in terms of unformatted capacity, and manufacturers have stopped doing this. In fact, there usually isn't any easy way to find out the unformatted capacity of new drives! So to take another example from our friends at Seagate, the ST-315330A, the "15330" refers to the drive's approximate formatted capacity, 15,364 MB (15.4 GB).www.tartoos.com

Binary vs. Decimal Capacity Measurements

Computer measurements are expressed in both binary and decimal terms, often using the same notation. Due to a mathematical coincidence, the fact that 2^10 (1024) is almost the same number as 10^3 (1000), there are two similar but different ways to express a megabyte or a gigabyte. This phenomenon, and the general problems it causes, I also discuss there how and why I have begun using alternative measurement notations for binary numbers.

The problems with binary and decimal are probably more noticed in the area of hard disk capacity than anywhere else. Hard disk manufacturers always use decimal figures for their products' capacity: a 72 GB hard disk has about 72,000,000,000 bytes of storage. However, hard disk makers also use binary numbers where they are normally used--for example, buffer capacities are expressed in binary kilobytes or megabytes--but the same notation ("kB" or "MB") is used as for decimal figures. Hard disks are large, and larger numbers cause the discrepancy between decimal and binary terms to be exaggerated. For example, a 72 GB hard disk, expressed in binary terms, is "only" 67 GB. Since most software uses binary terms, this difference in numbers is the source of frequent confusion regarding "where the rest of the gigabytes went". In fact, they didn't go anywhere. It's just a different way of expressing the same thing.www.tartoos.com

This is also the source of much confusion surrounding 2.1 GB hard disks (or 2.1 GB hard disk volumes) and the 2 GB DOS limit on partition size. Since DOS uses binary gigabytes, and 2.1 GB hard disks are expressed in decimal terms, a 2.1 GB hard disk can in fact be entirely placed within a single DOS partition. 2.1 decimal gigabytes is actually 1.96 binary gigabytes. Another example is the BIOS limit on regular IDE/ATA hard disks, which is either 504 MB or 528 MB, depending on which "MB" you are talking about.

Hard Disk Geometry Specifications and Translation

The generic term used to refer to the way the disk structures its data into platters, tracks and sectors, is its geometry. In the early days this was a relatively simple concept: the disk had a certain number of heads, tracks per surface, and sectors per track. These were entered into the BIOS set up so the PC knew how to access the drive, and that was basically that.

With newer drives the situation is more complicated. The simplistic limits placed in the older BIOSes have persisted to this day, but the disks themselves have moved on to more complicated ways of storing data, and much larger capacities. The result is that tricks must be employed to ensure compatibility between old BIOS standards and newer hard disks.www.tartoos.com

Note: These issues relate to IDE/ATA hard disks, not SCSI drives, which use a different addressing methodology

Hard Disk Partitioning and Formatting Procedure

This procedure describes how to set up a new, empty hard disk so that it is ready for an operating system to be installed on it. This process includes partitioning and formatting and results in a bootable hard disk. The procedure covers configuring the hard disk as a single large partition or splitting it into multiple, smaller partitions. The procedure provides specific instructions for using the FDISK program and is based on the Windows 95 OEM SR2 (Windows 95B) FDISK version with FAT32 support.

Warning: This procedure is intended to be used for setting up a new hard disk containing no information on it. Do not follow these steps if your hard disk has already been partitioned and formatted, or data loss will likely result.
 

Procedure Overview:

  • Difficulty Level: 2 (Low).
  • Risk Factor: 1 (Very low). This assumes that the hard disk has no data on it.
  • Hardware Required: None.
  • Software Required: Boot disk containing the FDISK.EXE and FORMAT.COM programs.
  • Time to Perform: 5 to 20 minutes, depending on the size and speed of the hard disks.
  • Preparation / Warnings:
    • To be safe, always run FDISK from DOS only. www.tartoos.com
    • Be extremely careful when using the FDISK program, as one incorrect keystroke can result in major data loss. In particular, in a system with multiple hard disk drives be careful to make sure you are working on the right physical disk or you may accidentally end up disturbing the contents of the wrong drive. Beware that DOS drive letters can change after creating or deleting partitions, and that with multiple hard disks the partitions may be lettered in an unexpected sequence.
    • Do not perform this procedure until the system is in good working order. Resolve any hardware conflicts or other issues before commencing.
    • I assume that the system has been turned on and booted from the floppy disk.
    • FDISK uses binary megabytes when displaying drive and partition sizes, not decimal megabytes.
    • All commands in DOS or within FDISK require you to press {Enter} to select them; I'm not going to repeat it a zillion times within the procedure below.

Procedure Steps:

  1. Check Version Number: At the DOS prompt, enter the following command: "ver". The system will respond with the version of DOS/Windows you have booted. Make sure that this matches whatever you want to install on the hard disk. For Windows 95 OEM SR2 the version number will be "4.00.1111".
  2. Plan Partitions: Decide how you want to partition your hard disk. In particular, for large hard disks under Windows 95 OSR2, decide if you want to set up your hard disk with a single large FAT32 partition, or several smaller FAT16 partitions. (You can of course mix these). I provide instructions for doing either of these, but cannot tell you how to set up your system. You must decide based on what makes sense for you. For assistance in making this decision, and more general information on partitioning, cluster sizes and related issues, refer to this section. Most people today prefer to set up a new system using a single FAT32 partition. www.tartoos.com
  3. Run FDISK.EXE: From the command prompt, enter the command "fdisk". If you have a disk large enough to warrant the use of FAT32, you will be asked if you want to enable "large disk support". Enter "Y" if you want to enable FAT32, or "N" if you do not want to enable FAT32. If you do enable this, any partitions over 500 MB that you create will be FAT32. Note that if you do not enable FAT32, you will not be able to put your entire hard disk into one partition if it is greater than 2 GB in size.

If you decided to place your entire hard disk into a single partition, then follow this step:

  1. Partition Hard Disk (Single Partition): Follow these steps to set up your hard disk:
    1. Select from the FDISK menu "1. Create DOS partition or Logical DOS Drive".
    2. Select "1. Create Primary DOS Partition". FDISK will verify drive integrity. Then it will ask if you want to use the maximum available size of the disk for the primary partition and set it active. Enter "Y". The system will allocate the whole disk to the partition, and that's that.
    3. Press {Esc} to exit FDISK.

If instead you want to set up your hard disk with multiple partitions (or if you don't have Windows 95 OEM SR2), follow this step. In order to make the process easier to follow, I am going to use an example below. In the example, a 3100 (binary) MB hard disk is being partitioned into four partitions of 1000 MB, 800 MB, 700 MB and 600 MB respectively:

  1. Partition Hard Disk (Multiple Partitions): Follow these steps to set up your hard disk:
    1. Select from the FDISK menu "1. Create DOS partition or Logical DOS Drive".
    2. Select "1. Create Primary DOS Partition". FDISK will verify drive integrity. Then it will ask if you want to use the maximum available size of the disk for the primary partition and set it active. Enter "N". The system will show the size of the entire disk in MB. www.tartoos.com
    3. Enter the size of the primary partition. In our example, this would mean entering "1000". The system will tell you that it has created the primary partition, and will assign it the drive letter "C:".
    4. Press {Esc} to return to the FDISK menu.
    5. Select "2. Set active partition". Select partition 1. FDISK will report that it has set partition 1 active.
    6. Press {Esc} to return to the FDISK menu.
    7. Select from the FDISK menu "1. Create DOS partition or Logical DOS Drive".
    8. Select "2. Create Extended DOS Partition".
    9. When prompted, press {Enter} to select the entire remaining area of the disk for the extended DOS partition. FDISK will report that it has created the extended DOS partition.
    10. Press {Esc}. FDISK will automatically prompt you to create your first logical DOS volume within the extended DOS partition.
    11. Enter the size of the first logical partition (the second partition overall). In our example you would enter "800". FDISK will create the partition, label it "D:", and then say "Logical DOS Drive created, drive letters changed or added". Don't touch anything, just wait, and FDISK will prompt you for the next volume.
    12. Repeat the previous step for the remaining partitions (in our example there would be two more partitions to create, the 700 MB and 600 MB ones). When all of the partitions have been created, FDISK will report "All available space in the Extended DOS Partition is assigned to logical drives".
    13. Press {Esc} to exit FDISK. www.tartoos.com

Continue with the procedure:

  1. Reboot: Reboot the system using either the Reset button or the "three-fingered salute" ({Ctrl}+{Alt}+{Delete}). Make sure the floppy disk is in its drive, since you still need it. Note that you may get "Invalid media type reading drive C" errors while rebooting. This is normal at this stage.
  2. Format Primary Partition: From the "A:" DOS prompt, issue the following command: "format c:/s". Do not forget the "/s", as this is what will make your C: drive bootable. You will get a "scary" warning message such as "WARNING, ALL DATA ON NON-REMOVABLE DISK DRIVE C: WILL BE LOST. Proceed with Format (Y/N)?". Since of course there is no data presently on drive C:, just enter "Y" and the system will format the hard disk. The program will show you its progress as it formats and at the end will prompt you for a volume label. Enter one if you wish.
  3. Format Additional Partitions (if necessary): If you set up multiple partitions, format the additional partitions now. This is done in almost the same way as formatting the primary DOS partition, except that you leave off the "/s". So normally you would be entering "format d:", "format e:" and so on, until all the partitions have been formatted. The prompts should be the same as in the preceding step. www.tartoos.com

Warning: If you have a second hard disk in the system and it has a primary DOS partition, that partition is probably assigned D: because DOS assigns letters to all primary partitions before any logical partitions. Be careful of what you format.
 

  1. Remove Boot Floppy: Eject the boot floppy from the floppy disk. www.tartoos.com
  2. Reboot: Reboot the system using either the Reset button or {Ctrl}+{Alt}+{Delete}. The system should boot up from the hard disk this time, and stop at the "C:" prompt. Note that if you get an error such as "NO ROM BASIC, SYSTEM HALTED" or "No boot device found" at this stage, this means you forgot to set the primary DOS partition "active". Reboot from the floppy, run FDISK again and use option 2 to set the primary partition active, then reboot. If you get an error like "No operating system", this means you probably forgot the "/s" parameter when formatting the C: drive. Put the floppy disk back in the drive and then return to step 5. www.tartoos.com

 

 طباعة المقال العودة إلى  مدرسة الكمبيوتر     قسم  الصيانة   الصفحة الأولى
Syria
سورية
Amrit
عمريت
أرواد
طرطوس
صور من طرطوس
صور من سورية
للسيدات فقط
معجم الكمبيوتر
أدب وفكر
المجلة الطبية
المعلومات العامة
لمحة عن طرطوس
الموضة النسائية
مدرسة الكمبيوتر
 © 2002-2012 LBCInformation Corporation. All rights reserved م حنا عطا لحود.