The partition mentioned above is called the Microsoft Reserved Partition (MSR). It is a reserved partition that does not receive a partition ID. It cannot store user data. The size of an MSR partition is 128 MB (for volumes under 16GB it is 32MB).
The Microsoft Reserved Partition (MSR) reserves space on each disk drive for subsequent use by operating system software. GPT disks do not allow hidden sectors. Software components that formerly used hidden sectors now allocate portions of the MSR for component-specific partitions. For example, converting a basic disk to a dynamic disk causes the MSR on that disk to be reduced in size and a newly created partition holds the dynamic disk database. Moreover, every GPT disk must contain an MSR. The order of partitions on the disk should be ESP (if any), OEM (if any) and MSR followed by primary data partition(s). It is particularly important that the MSR be created before other primary data partitions.
When initially created, the size of the MSR depends on the size of the disk drive:
On drives less than 16GB in size, the MSR is 32MB.
On drives greater than or equal two 16GB, the MSR is 128 MB.
If the MSR partition has been accidentally deleted, it can be easily recreated using Windows command line utility diskpart.
Basically, you need to insert the partition in the space left unoccupied by deleting it.
To do so, run diskpart at an elevated CMD or Powershell console.
In the Diskpart List and Select the disk that contains the partition to be recreated (we assume that it is disk 0)
DISKPART> List Disk
DISKPART> select disk 0
List the partitions on the disk
DISKPART> List partition
You get something like this:
Partition ### Type Size Offset
------------- ---------------- ------- -------
Partition 1 Primary 300 MB 1024 KB
Partition 2 Primary 99 MB 301 MB
Partition 3 Primary 45 GB 528 MB
It is easy to note that the missing partition should be located between partitions 2 and 3 (a 128MB gap)
If converted to bytes, the values show like this:
Partition ### Type Size Offset
------------- ---------------- ------- -------
Partition 1 Primary 314572800 1048576
Partition 2 Primary 103809024 315621376
Partition 3 Primary 48318382080 553648128
You can easily calculate the offset for the MSR partition by adding the offset and the size of the partition immediately preceding it.
In this case it would be 103809024 + 315621376 = 419430400Bytes = 400MB
There are cases though when there are no preceding partitions as it is the case of GPT data volumes. An example would be:
Partition ### Type Size Offset
------------- ---------------- ------- -------
Partition 1 Primary 10 TB 129 MB
In this case, one needs to take into consideration the default size of the MSR (32MB or 128MB) as mentioned above.
The calculation is made by removing the MSR size corresponding to the disk size from the offset of the next partition. In the case above, this would be
128MB = 134217728
129MB = 135266304
Offset = 135266304 - 134217728 = 1048576 -> 1024KB
A similar result, with the results expressed in bytes from the very beginning, may be obtained via Powershell:
PS C:\> get-wmiobject -class win32_diskpartition | where {$_.name -like "*Disk #1,*"} | select-object -property name,startingoffset,Size | ft -AutoSize -Wrap
name startingoffset Size
---- -------------- ----
Disk #1, Partition #0 135266304 11028341456896
Now, once the offset has been calculated, one can move to creating the partition. To do that run diskpart at an elevated CMD or Powershell console.
In the Diskpart List and Select the disk that contains the partition to be recreated (we assume that it is disk 0)
DISKPART> List Disk
DISKPART> select disk 0
Now, create the partition (assuming the offset of 400MB calculated above; the value in the command needs to be in MB)
DISKPART> create partition msr offset=400
The partition has been recreated now!
Please note that the diskpart command may use two parameters -- size and offset but if no size is specified, the partition continues until there is no more free space in the current region, which is the intended result.