Master Boot Record - Master Boot Record (MBR)

First, let's define some terminology. The words made in the article title, often understand two different things, which in some cases may be equivalent to, and in some - not. The first concept - the actual Master Boot Record. This record (code and data) that is loaded into memory from the hard drive and provides identification of the logical partitions on it, determines the active partition and boot from it Boot Record (Boot Record - BR), which will continue to run the operating system (OS). And the second thing - the boot sector, Master Boot Sector (MBS) - this sector, located on the cylinder 0, the (head) and 0 having the number 1. In most cases, MBS contains all the necessary code and data, so its content is the MBR however, there are cases (which we will discuss later in the article), when the code and data is not placed in the same sector (just do not have enough space or for safety reasons), and then the code of this sector provides the loading into memory the rest of the sectors. In this case, the MBR - a set of all the sectors that need to be loaded, and MBS - only a first sector.
However, we start with the case when the MBR and MBS - the same thing, and we call them more familiar and widespread term MBR. Slightly deviating from the topic, I note that a MBR (which provides boot any OS and occupies only MBS) are commonly termed Generic MBR.
Generally MBR appeared on the hard disk since MS DOS version 3.0, earlier versions of the hard disk was formatted as a floppy disk, and in the first sector located BR. Accordingly, the disc represents one section and could not be broken down into logical parts - the truth, when the size of the disks, which are then released, it was irrelevant.
sector size on the hard drive - 512 bytes. This space is enough to house all the necessary - and the code and data. However, only one structure should there necessarily be present - it is a signature. This word is called a special, strictly set, the sequence of 2 bytes with the hexadecimal values ​​55h AAh, which is recorded in the last 2 bytes of the sector and, accordingly, is offset from the beginning 1FEh sector. If at least one of the last two bytes differ in value, it is assumed that the first sector is not MBR and does not contain meaningful information. If the computer at startup, after reading the first sector, does not detect the correct signature, it will not transmit the control code settling down there, even if it is correct, and will display a message that the master boot record is not found. Or will try to find it on other devices - for example, on a floppy disk. Slightly deviating from the topic, I note that the BR also contains the signature 55h AAh in the last two bytes.
Well, so if started from the tail, then we go from there to the top of the sector. Before signature, close to her, there are 4 data blocks of 16 bytes each (respectively offset from the beginning 1BEh sector, 1CEh, 1DEh, 1EEh). The combination of these blocks is called the Partition Table, Partition Table (PT), and each separate entry - an element of the partition table (Partition Table Entry) or just a partition (Partition). These 16 bytes are enough to specify all the necessary characteristics of the section, namely section type, sign Forum activity, starting and ending sector of the partition in the cylinder format (track) - The head (side) - Sector (Cylinder - Head - Sector, CHS) the relative number of the first sector (relative to the MBR) and the number of sectors in the partition.
All the rest of the space sector employs software code that provides analysis of the PT, search for an active partition, boot into the memory section of the BR and transferring control to it. It is easy to calculate the code remains on the 512 - 4 * 16 - 2 = 446 bytes. This space is more than enough to carry out such actions.
Thus, the overall structure of the MBR may be represented by the following table:
  Offset Length Description
 000h 446 loader code
 1BEh 64 Partition Table
  16 Section 1
 1CEh 16 Section 2
 1DEh 16 Section 3
 1EEh 16 Section 4
 1FEh 2 Signature (55h AAh)
Each 16-byte block, which describes one section, has the following structure:
  Offset Length Description
 00h 1 Symptom section activity
 01h 1 Top of Section - Head
 02h 1 Start section - sector (bits 0-5), track (bits 6,7)
 03h 1 section Start - track (8.9 high-order bits are stored in a byte sector number)
 04h 1 partition type code
 05h 1 End section - head
 06h 1 End section - sector (bits 0-5), track (bits 6,7)
 07h 1 End section - track (8.9 high-order bits are stored in a byte sector number)
 08h 4 Offset of the first sector
 0Ch section 4 Number of sectors
partition type code is a one-byte identifier. If its value - 00h, it is considered that the PT element does not contain data on the partition, and its content is ignored. Any non-zero value means that this space is part of a certain type. Some of the values ​​clearly indicate the partition type, some correspond to several possible types, and definition of a particular type is assigned to the operating system, and the rest are reserved for future use. Relatively complete and up-to-date guide to sections of code types can be found in Ralf Brown Interrupt List in INTERRUPT.D file table 00652, which is contained in the archive (as of this writing) inter61a.zip at http://www.pobox.com/ ralf ~ / files.html . Here I give a table of the types of partitions that are created by the operating systems Windows 9x and Windows NT / 2000 / XP:
  Code section Type
 01h 12-bit FAT
 04h 16-bit FAT and 32 MB
 05h Advanced section
 06h 16-bit FAT than 32 MB
 07h Windows NT NTFS (and a few others - is determined by the type of content BR)
 0Bh 32-bit FAT
 0Ch 32-bit FAT using extended INT13 control
 0Eh LBA VFAT (the same as 06h, with the use of advanced management INT13)
 0Fh LBA VFAT (the same as 05h, with the use of advanced management INT13)
 17h Hidden NTFS partition
 1Bh hidden partition 32-bit FAT (the same that 0Bh)
 1Ch hidden partition 32-bit FAT using extended control INT13 (the same that 0Ch)
 1Eh hidden partition LBA VFAT (the same as 06h, with the use of advanced management INT13)
 Section 86h FAT-16 Windows NT stripe-array
 Section 87h NTFS stripe-array of Windows NT
 B6h mirrored master-partition FAT-16 Windows NT
 B7h mirrored master-section NTFS Windows NT
 FAT-16 Windows NT S6h Mirror slave-section
 S7h Mirror slave-section NTFS Windows NT
Symptom section of activity - ie, a sign that the operating system should download it from this section - may have a value of 80h (partition is active) and 00h (partition is not active). In general, the amount of the active partition must be less than 1 (except to make a choice?). If the active partition is not - then the OS from that hard drive can not be loaded. Other values ​​are rejected as bad. However, the decision on transfer of control takes the bootloader code, so the value of the byte boot feature - an axiom only the standard downloaders.
Trёhbaytny block start and end addresses section addresses have an identical format. It actually uses the value of packaging in order to have a minimum amount. Package format is fully consistent with the way the data is transmitted procedures work with hard drive (Int 13h), located in the PC's BIOS, so the computational overhead costs are obtained minimal. At the same cylinders and tracks are numbered, starting at zero, and the sector - for some reason the first. I really do not know why - it happened historically.
The sector, which indicates the start address of the section contains a special entry, called a boot record (BR). Her appointment and composition will be discussed in a separate article.
Offset of the first sector of the partition - it is actually the number of the sector when all of the hard disk sectors renumbered starting from 0 (in accordance with the numbering used Int 25h / 26h) in ascending order of first sector of one track, in order of increasing head numbers and, finally, cylinders. And what is the number of sectors in the partition - it is clear without explanation.
Naturally, all these values ​​are related by simple dependencies, because the information contained therein is excessive. Because the formula will give the relationship between them.
So, if we denote:
C M - cylinder on which the MBR;
H M - track, on which the MBR;
S M - sector, which is the MBR;
C S, H S, S S , C E, H E, S E - is the same, for the start of sectors (S) and end (E) of the section;
H H - the number of tracks in the hard disk;
S H - the number of sectors per track in the hard disk,
then:
The absolute number of sectors in which the PT:
Num PT = C M * H H * S H + H M * S H + S M -1
The absolute number of sectors beginning of this section:
Num S = C S * H H * S H + H S * S H + S S -1
Absolute Sector number of the end section:
Num E = C E * H H * E H + H E * E H + E E -1
The offset of the first sector of the partition:
Offset S = Num S - Num PT
The number of sectors of the partition:
Amount = Num E - Num S +1
From these formulas, moreover, it is evident that it is important how many tracks have a hard disk and how long cylinder sectors of each track. These values ​​depend on the geometry of the hard disk, and the selected settings in the BIOS translation mode. Therefore, the disc is divided into sections in a broadcast mode, it may be unreadable when you change the broadcast mode.
For IDE-drives, there are several modes of translation:
CHS (Cylinder-Head-Sector) - in this case the geometry of the disk is considered to be what it says it is a computer. Do not be fooled - the majority of the real drive geometry is not like that. However, the controller is part of the hard drive, makes the necessary changes yourself, and the way he does it is unimportant for us. The maximum number of cylinders - 1024 (0 to 1023), tracks - 16 (0 to 15), the sectors - 63 (1 to 63), and the maximum disk capacity available in the broadcast without the use of special programs - 504 Mbytes . When disk operations sector address is transmitted to the computer's BIOS controller hard disk unchanged.
LBA (Logical Block Addressing) - with the broadcast mode, not the disc geometry, which he informs the computer's BIOS. Produced bring to the format when the number of cylinders is less than 1024, and the number of sectors per track is equal to 63. The provided number of tracks at the same time depends on your computer's BIOS and hard disk volume, and can be equal to 16, 64, 128 or 255, the latest version of the BIOS is usually use reduction to 255 (0-254) paths, regardless of storage capacity. When referring to drive transferred to the LBA-broadcast cylinder number, head and sector translated into an absolute number of sectors, and that he passed the computer's BIOS hard disk controller to perform the operation. When storage volume of more than 8 GB of the number of cylinders is obtained more than 1024, because on computers that do not support the extended mode Int 13h, without having to install special software space beyond the boundaries of 8 GB available (regardless of the broadcast mode). Sometimes, however, it helps to update the computer's BIOS.
LARGE, or ECHS (Extended CHS) - with the broadcast mode is made to bring the number of cylinders to the value of at least 1024 due to the increase in the number of multiple paths. The provided number of tracks is strictly a multiple of the actual number of sectors per track is not changed. However, most modern drives the number of sectors per track (on the assurances of the drive controller) is 63. The maximum amount available on computers that do not support the extended mode Int 13h, depends on the actual number of tracks, but not more than 8 GB (for example, if the disk has 16 tracks, in their broadcast LARGE may be 16, 32, 48 ... 240, but not 255, since 255 is not a multiple of 16 and the maximum available volume - 1024 * 240 * 63 * 512 / (1024 3) = 7.38 GB).
If you use LBA or LARGE broadcast due to rounding to whole numbers several sectors at the end of the drive can "fall out" of the described space and become inaccessible. However, losses are usually small.
What about SCSI-disk drives, they will always work in the LBA-mode transmission. Rather, SCSI controller represents the geometry of the drive in accordance with the requirements of the LBA-broadcast, and the handling the disc sends him an absolute sector address. Naturally, it is in the BIOS SCSI-controller's responsibility to make the necessary recalculation.
Returning to the MBR. As already mentioned, it contains a data block of four table elements sections. This means that the maximum number of partitions that can be described in an MBR, equal to four. However, this does not mean that the maximum number of sections, which can be divided drive, four equally. To overcome this barrier was introduced a special type of interface with the code 05h - extended partition (Extended Partition).
An extended partition is very different from all other types of sections. Firstly, it does not describe the partition drive and the region of space in which the other sections are located. The number of the occupants of sections is theoretically unlimited. However, the sections that are located in this area, several "limited rights", the most significant limitation is that they can not be active (or rather, it is possible to do so, because of this the OS partition will be loaded, but the regular means of most of the existing OS do not permit, have to use special tools). Secondly, the MBR must contain only one entry for the extended partition. Rather, they can be made and more (at least four), but behaves like OS, encountering a difficult to predict. For example MS-DOS 6.20 ignores all extended partitions, except the first one in the list, as if they do not exist. Third, unlike other types of partitions in the sector, which is registered in the structure of the sector as a start section, contains not BR. There is actually one MBR, which has a signature, and a partition table, but does not typically contain program code (generally a sector including a partition table, but does not contain the bootstrap code that is called Abstract MBR). However, since there is no active partition, then the code is useless. In this sector, partition table there is usually one or two entries. The first section describes the usual (Partition), moreover, this section should be completely inside the space Extended Partition. If an ordinary section takes all the space in the partition table, a second element, which describes the remaining space as the Extended Partition. In another sector exactly as described by one section and, if space remains, even a record of the Extended Partition. And so it continues as long as the space is completed. In fact, all the records on the extended sections are connected chain (Extended Partition Chain), which pinch off pieces of the usual sections of the storage space, the place is not going to end. An error in any element of the chain will lead to its disintegrating as a result of all records after the break is not running, and the operating system space occupied by them will be found will be considered vacant.
usually OS adheres to a few rules when completing the circuit. First described in the next "link" circuit normal partition should not be placed in the middle, as if to describe the resulting two pieces of free space is required in PT this element enter two records on two different extended partitions as well, as I said earlier, the OS usually ignore all such records except the first, and as a result of the fall out of disk space partitioning. Second, usually a record of the normal section is made so that it occupied an initial area of ​​the extended partition, and the next element of the chain sections - the remainder.
What problems might arise from the contents of the MBR? Firstly, logical or physical destruction, i.e. surface damage or other mechanical problem or corrupt servo, which makes it impossible to read this sector from the disk. However, such cases are outside the scope of our consideration. The second most common problem - the destruction of all or part of the information contained in the sector, whereby the sections or may not be found by the operating system, or their parameters are determined incorrect.
The easiest case - the destruction of the signature. At the same time the OS thinks that the sector contains some random information, "garbage", and the drive itself does not divided into sections, and no information on it is not. To restore just enough by any means of direct access to the sectors of the disk (the most popular of DISKEDIT NORTON UTILITIES package) to restore the signature. Most operating systems, however, need to be restarted since the operating system is usually when you start reading the information on the partition a disk, and then in the process of its changes are not taken into account.
A more complicated case - is the destruction of the code. At the same time lose the ability to boot the operating system from the drive and attempt to boot usually ends with "hang" the computer. At the same time, if you boot from another drive (another hard disk, floppy disk, bootable CD-ROM, etc.), then all the information on the drive is available for use. In this case, it is recommended to use standard tools recover boot code, which are available in each OS. For example, on Windows 9x for this purpose FDISK.EXE program that runs with the key / MBR.
The destruction of the code - not as rare event as it might seem. As a rule, such a trouble occurs when one drive multiple operating systems are installed in series in one or various sections. Any OS installation wish to have in the MBR own code, but not all care about maintaining the code that was previously in the sector. For example on Windows 9x rewrite the bootloader code, without informing the user popularity and irrevocably destroying the old contents. However, this case is just not very scary, because all loaders OS are very similar. The problem occurs if the partition the drive into partitions used by third-party software, such as EZ-drive, ODM or such SpeedStore, which just MBR concepts and MBS are not equivalent. Due to the different ideologies download (which we'll see later) the code in the MBS, performs another function, namely, searching and downloading of the MBR code, located in the other sectors of the disk. Replacement code leads to the fact that this function is lost, and thus there are problems of different nature. The user must be very careful when using such software - code recovery in such cases can be very difficult.
And the most heavy and unpleasant experience - is the destruction of the partition table itself. However, as we know, the trouble never comes alone, and often all three are destroyed MBR component, but it is the destruction of PT results in the most serious consequences, because it lost the ability to access information stored on the drive. PT can be destroyed completely, and perhaps in part - ie, of the elements destroyed, and the rest intact. There are cases when the PT, located in an MBR, intact and broken a record of the sections in one of the links in the chain Extended Partition. However, since the structure of the MBR and the structure are identical (except that there is no Extended Partition elements code), the recovery procedure in both cases is the same.
There is a sufficient number of programs able to rebuild their shattered PT. The quality of their work is different and depends mainly on how difficult it was disk partitioning that all the types of partitions that are on the disk, known program, and there are no other than the destruction of PT has no damage data in other sectors, especially the BR sections. However, we are not looking for easy ways, and if you have the soul does not hang Head with cries of "more, faster, jumping print out my form, I'm on vacation late!", You will get much more pleasure if on their own, without any programming-machines using only their knowledge, be able to recover all the information. You can even just make all the necessary research to get all the numbers that need to be written in the PT, and then start the recovery program and then make it work, that everything felt right. And maybe even improve the results of its work, if it is not fulfilled by 100%.
So we need to work: a boot diskette with the DOS any, to which the copied file DISKEDIT.EXE, pencil, paper and calculator (though the calculator is in the DISKEDIT) and some brains. It is desirable, of course, and to the DOS, and DISKEDIT were fresher. I use DOS 7.10 from the Windows 98 SE and DISKEDIT of NORTON UTILITIES packet 2002. No drivers at this stage we do not need, well, except when the drive is connected to the old SCSI-controller and without load the driver just is not visible. You can download the mouse driver - will be a bit more convenient. Now, the main change - in addition to the files on a floppy disk should not be anything! This is important - if there is no floppy disk configuration file, DISKEDIT.EXE run in read-only mode (Read-Only) and no data will be changed on disk, until we do not explicitly ask for. A floppy disk to close all of the entries.
Boot from the floppy disk. Run DISKEDIT.EXE. After loading, press the keys Alt-D (or through the Object menu - Drive). It displays a window with available disk devices. First, we point out that we need a physical device (Physical disks), and then select the desired drive (say, Hard Disk 1), and then click OK. At the same time in all the sectors of the disk will be selected as the view range from first to last. That we need.
First, we will ask the program to perform the disk view and search all the sectors that can be circuit elements Extended Partition or BR. And although it would be easy to look DISKEDIT sector with the signature, not to analyze the contents (we take over) - great results can facilitate the work. The truth will have to be patient - the process is not quick, and besides, everyone found the sector will need to take a pencil, but worth powder and shot.
So, Tools - Find Object - Partition / Boot. Go. Whenever comes sector with the signature, the search stops, the screen displays a dump of the sector, and in the lower right corner - number of sectors. These are the addresses and need to take a pencil. However, if you partition a disk is not used very sophisticated methods, all we are interested in the sector will be placed on the zero or the first side in the first sector, ie Side 0 or 1, Sector 1. Other sectors, for example some 12 Cyl, Side 4, Sector 52 can safely be ignored - it accidentally. However, we have an absolute number of sectors, but it is not terrible, for the "right" number of sectors will be divisible by the number of sectors per track, usually 63 (other values ​​there are now much less - 17, 26, 40, 56, so hereinafter wherever I will be talking about the number of sectors 63, keep in mind that other number) have to be used on your particular storage possible. And this figure we can see from the menu (Info - Drive Info). Unfortunately, the number of sides and the cylinder there may be incorrect (not appropriate for the translation), but it's not terrible. Writing the next number of sectors, we continue to search (you can through the menu Tools - Find Again, you can just Ctrl-G). And so until we get a message that the object is not found. At this point in our hands (or rather, on paper) all sectors of the rooms in which there is a signature.
Теперь обрабатываем список, отсеивая явно случайные номера (это которые не делятся на 63), и особо выделяя пары номеров, которые различаются на 63. Эти пары - не что иное как пара из элемента Extended Partition и BR описанного в нём раздела.
Теперь отложим на минутку листок с цифрами и попытаемся вспомнить, какого размера разделы были на диске. Так, крупными мазками, 600 мегабайт, 12 гигабайт… запишем всё что помним. Если сумма не равна объёму накопителя - либо что-то забылось, либо неверно вспомнилось, либо было пространство, не принадлежавшее ни одному разделу (а что, бывает… знаю не один случай, когда десятигигабайтный жёсткий диск разбивался на компьютере, материнская плата которого не понимала более восьми гигабайт, а при апгрейде это как-то не вспомнилось… вот так 2 гигабайта и зависли). На этом этапе желательно вспомнить ещё и типы файловых систем в каждом из разделов.
Теперь возьмём оба листка и попытаемся совместить полученные данные. Мегабайт - две тысячи секторов, гигабайт - два миллиона… приблизительно. Но обычно удаётся совершенно однозначно наложить одно на другое. Полезно бывает нарисовать длинный прямоугольник, расставить на нём границы, соответствующие найденным секторам, и поделить на кусочки, соответствующие размерам разделов. Даже если однозначности нет - не беда. Разберёмся. При совмещении данных рекомендую помнить, что некоторые BR и элементы цепи Extended Partition могут быть разрушены (и соответственно не будут найдены), причём наиболее часто разрушаются BR первого (по положению на накопителе) раздела и BR активного раздела.
Впрочем, на данном этапе, пожалуй, всё… и не потому, что дальше некуда, а по другой причине - для дальнейшей работы по восстановлению требуется анализ других структур, которые располагаются уже в "найденных" разделах - это BR, FAT/MFT, каталоги и пр… мы их пока не рассматривали. Впрочем, иногда и найденной и вспомненной информации достаточно. В конце статьи приведен пример такого восстановления (пока не написан).
Иногда знание структуры разделов применяют совершенно для других целей - например, для создания своего собственного разбиения диска на разделы. Пример такого применения также есть в конце статьи.
При создании нестандартного разбиения диска на разделы, кроме требований, описанных ранее (один расширенный раздел и пр.), рекомендую также учитывать то, в каком порядке ОС MS-DOS и Windows назначают разделам буквы логических дисков ( Q51978 - Order in Which MS-DOS and Windows Assign Drive Letters ). Буквы присваиваются, начиная с C: (A: и B: зарезервированы для дисководов гибких дисков, возможно виртуальных). Порядок подключения таков:
  1. Раздел, с которого загружается ОС (при загрузке с жёсткого диска).
  2. Первые первичные разделы остальных жёстких дисков в порядке их нумерования (инициализации) BIOS компьютера.
  3. Разделы в Extended Partition жёстких дисков в порядке их нумерования (инициализации) BIOS компьютера, в порядке их записи в Partition Table дисков.
  4. Остальные первичные разделы дисков, в порядке их записи в Partition Table по порядку их нумерования (инициализации) BIOS компьютера.
  5. Устройства, формируемые драйверами, запускаемыми в файлах config.sys и autoexec.bat, в порядке их формирования и инициализации, если формируемому устройству не назначается в явной форме определённая буква или диапазон букв.
  6. Для ОС, которые могут опознавать и подключать накопители, не инициализируемые BIOS компьютера (не описанные в установках CMOS накопители) - разделы этих накопителей в соответствии с правилами 3 и 4 в порядке инициализации накопителей операционной системой.
Разделы не известных ОС типов не инициализируются и буквы им не присваиваются.
Следует помнить, что ОС семейства Windows NT имеют штатные средства переопределения букв логических дисков.

Пример 1. Ручное разбиение на разделы.

  • Параметры накопителя в LBA-трансляции (взяты из BIOS - Autodetect Hard Disk) - Cylinders 1216, Heads 255, Sectors 63, Capacity 10 Gb.
  • Желаемое разбиение: система 2 Гбайт, данные - 2 Гбайт, игры и дистрибутивы - остальное. Желательно разместить системный раздел в конце диска (по тестам там самая быстрая область), игры - в начале диска (по заверениям специалистов, наиболее часто данные повреждаются именно там).
  • Операционная система - Windows 98 SE rus, все разделы - FAT-32.
Исходя из желаемого разбиения, видится следующая схема: сначала расширенный раздел с двумя логическими дисками в нём - 6 и 2 Гбайт, потом первичный активный раздел 2 Гбайт, либо 3 первичных раздела в указанном порядке и с указанными размерами. Последний вариант нам не подходит (неважно по каким соображениям). Особенности работы программы FDISK выбранной ОС не позволяют выполнить разбиение штатно: если сначала мы создадим первичный раздел, он будет находиться в начале накопителя, если же мы сначала создадим расширенный раздел, то программа отказывается создавать первичный.
Принимаем решение провести разбиение с помощью FDISK насколько возможно, а затем доделать вручную. Первый этап: создать расширенный раздел с двумя дисками; второй: вручную добавить запись о первичном разделе.
Первый этап проблем не вызывает: загружаемся с дискеты, создаём extended partition размером 8 Гбайт, и в ней два логических диска - 6 Гбайт и 2 Гбайт. Перезагружаемся с дискеты, убеждаемся, что на диске появились (но недоступны - ведь мы не форматировали разделы!) диски C: и D:. Форматируем их при помощи стандартного FORMAT и в процессе форматирования убеждаемся, что диск C: имеет размер 6 Гбайт, диск D: - 2 Гбайт. Запускаем DISKEDIT и смотрим содержимое MBR. В нём имеется следующая запись:
 Starting location Ending location Relative Number of
System Boot Side Cylinder Sector Side Cylinder Sector Sectors Sectors
EXTEND No 1 0 1 254 972 63 63 15631182
unused No 0 0 0 0 0 0 0 0
unused No 0 0 0 0 0 0 0 0
unused No 0 0 0 0 0 0 0 0
Нам нужно добавить запись о первичном разделе. Тип (System) будет 0Ch (FAT32x), признак загрузки установлен, начало раздела по адресу 973/0/1, конец раздела по адресу 1215/254/63, относительный сектор начала раздела 15631245 (973*255*63+0*63+1-1), относительный сектор конца раздела 19535039 (1215*255*63+254*63+63-1), количество секторов 3903795 (19535039-15631245+1). Весьма существенная тонкость - если номер цилиндра более 1023, в соответствующее поле вносится значение 1023 - увы, это максимальное значение, которое можно туда записать - а правильное значение ОС рассчитает исходя из заданного количества секторов.
Переводим DISKEDIT в режим Read-Write (Tools-Configuration) и во второй строке вписываем рассчитанные данные. После ввода и проверки всех значений выходим из DISKEDIT клавишей Esc, а на вопрос, что делать с изменениями, отвечаем - записать (write). Restarting the computer. Убеждаемся, что на диске теперь три раздела - C: - недоступен, D: - 6 Гбайт, E: - 2 Гбайт. Форматируем диск C: с переносом на него системных файлов, в процессе форматирования убеждаемся, что диск C: имеет размер 2 Гбайт. Обновляем код MBR командой FDISK /MBR, вынимаем дискету, перезагружаем компьютер, убеждаемся, что ОС загрузилась, диски C:, D: и E: доступны и имеют размеры 2, 6 и 2 Гбайт. Запускаем NDD и убеждаемся, что ошибок ни в таблице разделов, ни на дисках нет. Разбиение закончено.
Теперь таблица разделов при просмотре через DISKEDIT выглядит так:
 Starting location Ending location Relative Number of
System Boot Side Cylinder Sector Side Cylinder Sector Sectors Sectors
EXTEND No 1 0 1 254 972 63 63 15631182 ; Расширенный раздел
FAT32x Yes 0 973 1 254 1023 63 15631245 3903795 ; Первичный раздел (C :)
unused No 0 0 0 0 0 0 0 0
unused No 0 0 0 0 0 0 0 0
Если поставить курсор на строку с записью о расширенном разделе и нажать Enter, то DISKEDIT автоматически перенесёт просмотр в сектор, на который указывает адрес начала раздела (для первичного раздела это будет BR, для расширенного - элемент цепи разделов). В нашем случае мы увидим такое содержимое элемента цепи разделов:
 Starting location Ending location Relative Number of
System Boot Side Cylinder Sector Side Cylinder Sector Sectors Sectors
FAT32x No 2 0 1 254 728 63 63 11711259 ; Логический раздел (D :)
EXTEND No 0 729 1 254 972 63 11711322 3919923 ; Расширенный раздел
unused No 0 0 0 0 0 0 0 0
unused No 0 0 0 0 0 0 0 0
Продолжим движение по цепи разделов в следующий элемент:
 Starting location Ending location Relative Number of
System Boot Side Cylinder Sector Side Cylinder Sector Sectors Sectors
FAT32x No 1 729 1 254 972 63 63 3919860 ; Логический раздел (E :)
unused No 0 0 0 0 0 0 0 0
unused No 0 0 0 0 0 0 0 0
unused No 0 0 0 0 0 0 0 0
Очередной элемент цепи не содержит записи о расширенном разделе. Цепь закончилась.