The mystery of the creation of Win8 computer OEM partition

  
        Most of the computers pre-installed with Win8 now use the new UEFI firmware + GPT format disk, no longer like the previous BiOS + MBR. The benefits of using UEFI and GPT are many, such as enabling new features such as secure boot, and supporting more hard disk partitions and larger partition capacity.
Like laptops like Dell have some diagnostic tools that can be run before the system boots. In fact, these tools are often stored in a hidden OEM partition on the hard drive. If you accidentally delete the system when you reinstall it yourself, how do you restore the OEM hidden attributes of the partition even if you copy the program files from elsewhere?

For the MBR format hard disk, we can get the solution through Baidu search. For the GPT format hard disk, there is no effective solution on the network. In the following, I will reveal how to use GPT. Hard disk application OEM partition properties.
First, let's quickly review how to set up an OEM partition on the MBR disk: In the Diskpart command, execute "create partition primary id=xx size=xx" on the selected partition, where id identifies the OEM vendor, for example Id=DE is to declare to Windows that it is Dell's OEM partition. For more vendor code descriptions, you can execute the command "help create par pri" to understand:

So what about GPT formatted disks?
The above command is of course no longer applicable. Is it as online that you can only use the "one-click recovery" software sent by the OEM to completely format and restore the disk partition, or use Ghost to reload the previous hard disk backup to set it up? Some of the answers from foreign forums also indicated that they had to contact the OEM to recover. In fact, the answer is that we can set it ourselves, and the same is the tool that comes with the Diskpart system, but it is easily overlooked by everyone.
The new version of Diskpart has a command "gpt". With this command and the corresponding partition attribute code, you can easily set its properties. For example, we need to set the OEM partition attribute, let Windows automatically hide the partition, then we can set it to OEM partition after executing a primary partition (create par pri size=xxx) and executing "Gpt attributes=0x0000000000000001".
What is the meaning of 0x0000000000000001 here? We can do this by executing "help gpt":

In addition to setting a primary partition as an OEM partition with the 0x0000000000000001 attribute, we can also apply other attributes to the partition by other code:
< Br> To cancel an applied attribute, simply add a minus sign "-" to the attribute ID in the gpt <64-bit attribute ID> command. It is not excluded that Microsoft will add more new properties for GPT disks in the next version of Windows

Copyright © Windows knowledge All Rights Reserved