|
With the introduction of Microsoft Windows Vista (tm) the rules for creating
partitions have changed a bit. This is something that end-users will probably
never notice, but on disk Vista handles the creation of partitions differently
from all previous versions of Windows (you can read more about this here, but
this is not required reading). In short, Windows Vista uses different start- and
end locations to define a partition, so the structures and sectors that
DiskPatch looks for during a repair operation are found in different places. In
practice this means that if DiskPatch would analyze a disk that was partitioned
using Windows Vista, and DiskPatch's analyze logic would assume the disk was
partitioned using a previous version of Windows, nothing would be found because
DiskPatch would look in the wrong places. So, before an analysis is started you
must tell DiskPatch which operating system was used to create the partitions
that you wish to repair. When an operation is started that requires you to
select which operating system created the partitions, the following menu option
is displayed:

Select the appropriate option and press
<enter>. You can press <escape> at this point to abort the
operation.
-
Choose 'Megabyte aligned' if the partitions were created using Windows Vista.
-
Choose 'Cylinder aligned' if the partitions were created using a previous
version of Windows, or any other Microsoft based Operating System.
If you're not entirely sure which one to
choose, try 'Cylinder aligned' first. In this time where Vista is commonly
installed as an upgrade over existing partitions (and simply does not yet have
the install base that previous Windows versions have), cylinder aligned is your
best bet. If the partition repair list is empty or incomplete, try 'Megabyte
aligned'.
| The only
DiskPatch repair operation where the choice for Vista or earlier
versions of Windows is of any importance, is a 'Partition Table
rebuild'. All other operations (cloning, surface scanning, disk wiping,
boot sector repair etc.) are not affected by the changes that were
introduced in Windows Vista.
|
The difference
between Vista created partitions and Pre-Vista created partitions.
First, a little background information.
all hard disks are made up of sectors. Each sector has a number, the
first sector being number 0 (zero). So sector 10 is simply the 11th
sector on the disk (start at 0!) and so on. This type of numbering is
called LBA addressing. LBA stands for 'Logical Block Address', which in
this case simply means that sectors can be found on the disk by counting
from the start of the disk. A simple clean system.
In earlier days, when disks were smaller, an additional system was used
to define a location on a disk: the CHS notation. CHS stands for
Cylinder, Head and Sector. Mechanically speaking, hard disks contain
platters and each platter has it's own set of read/write heads. If you'd
put the heads in a certain position above the platters and perform a
read operation on all the heads, you would have read a cross section of
the disk. A stack of rings if you will, one ring for each platter. This
would be called a cylinder. Each cylinder would be numbered, the first
one being 0 (zero). The read/write heads are also numbered (again, the
first one being 0), so you can use a cylinder number and a head number
to find a specific location on the platters. Finally, each of the rings
we've read earlier consist of a number of sectors, which also have a
number (sector numbers start at 1, not 0). So a CHS address of 9-0-1
would translate into reading the sector at cylinder 9, head 0 and sector
1 (remember: cylinder and head starts at 0, sectors start at 1). The
maximum number of sectors in a ring would be 63 (from 1 to 63), the
maximum number of heads would be 255 (from 0 to 254) and cylinders could
be any number, so as disks got bigger the number of cylinders grew and
grew. Of course there were almost never any disks that actually had 255
heads, this number was selected because at the time they thought it
would be more than enough to accommodate even the largest disks.
Obviously they were wrong...
This CHS notation is still in use today, but only because of backwards
compatibility reasons: most recent operating systems don't use these
numbers anymore. Since disks these days are quite big, disk manufacturers
almost always set the number of sectors per ring to 63 (the max possible
value) and the number of heads per cylinder to 255 (again, the max
possible value). If you'd make these numbers smaller you could get a
huge number of cylinders so it makes sense to select the highest
possible values for heads and sectors: bigger chunks are easier to
manage. For this reason most modern day disks will tell you that they
have 63 sectors per head and 255 heads per cylinder, even if in fact
that's not the way the disk is made up.
So what does this have to do with partitions?
All Windows versions before Windows Vista used these CHS
numbers to select the start- and end location for a partition: a
partition would always start on the first sector of a head location, and
the partition would always end at a cylinder end location. Example:
let's say we have a disk that has 63 sectors per ring, 255 heads per
cylinder and 1000 cylinders. A start location for a partition could be
0-1-1 (cylinder 0, head 1, the first sector) and an end location could
be 74-254-63 (cylinder 74, head 254 and sector 63). In this example 254
is the highest possible head number and 63 is the highest possible
sector number: if you continue to the next sector these values would
roll back their starting values, and the cylinder number would increase
by 1. That's why we call this type of location (head 254 and sector 63)
a 'cylinder end location'.
For this reason a partition would never be the exact size that you
selected: during creation a partition was stretched or shrunk to make
sure the start- and end locations would be according to the rules as
explained above.
If a partition is created according to these rules, a partition is 'CHS
aligned'.
Windows Vista ignores the whole CHS nightmare and uses only LBA
addressing, so Vista starts counting at sector 0 and simply sequentially
counts onwards. A new formula is introduced to determine the start- and
end locations for partitions: a start location is always a multiple of
2048, an end location is always a multiple of 2048 minus 1. Nice and
simple. The number 2048 was selected for a reason: 1 sector contains 512
bytes so 2048 sectors is exactly 1 megabyte. So if you select to create a
partition of x megabytes in Windows Vista, it will be exactly that size
in megabytes.
If a partition is created according to these rules, a partition is
'megabyte aligned'.
And finally, what does all this have to do with DiskPatch?
DiskPatch uses a clever scheme to search the disk for partition
remnants. As you can see from the explanation above, it's imperative
that DiskPatch knows where to search. Therefore DiskPatch needs to know
if the partitions were created using Windows Vista (so DiskPatch can
look at LBA locations that are a multiple of 2048) or if the partitions
were created using earlier versions of Windows (so DiskPatch can look at
the correct CHS locations). If you would let DiskPatch scan a Vista disk
in CHS mode it's likely that nothing would be found, so it's essential
that you select the correct search method. Also, if DiskPatch
accidentally finds stuff while using the wrong search method, the repair
would probably lead to partitions that can't be accessed, or partitions
may even be damaged by the actual repair. For this reason you should
always enable the Undo feature, and make sure you use the correct
scanning method.
|
|