grub4efi 2022-11-28 PARTTYPE issue?
steve6375 opened this issue · 8 comments
Has been repaired.
BOOTX64.rar.txt
parttype does not return 0x00 if partition type is 0
e.g. parttype (hd0,3)
where ptn 4 is unused - does not return any text output
grub4dos (legacy) does return 0x00
parttype (0,3) ;; set rt=%@RetVal% ;; echo %rt%
parttype command should only return the partition type numbers of the 4 Protective MBR partition tables in LBA0.
parttype and partnew are only for mbr sector LBA0 use.
So in my example (and yours) only the first partition table entry is EE - all the other 3 table entries are 0.
Some disks have more than one partition table entry in the protective MBR. e.g. Hybrid MBR.
Using parttype, how could you tell if the second partition table in protective MBR of a hybrid disk was used and what type was in it? User may want to create hybrid MBR using partnew and check each of the 4 primary tables in Protective MBR.
An EE type in any one of the four tables indicated a GPT disk (or hybrid GPT).
here you see partition type is 7 but EE is reported !
Oh,there is really wrong report for partnew in GPT partition.I found it,too。
GPT partition will show 0xEE,but it should be 0x07(NTFS) or 0x0C(FAT32)
But partnew only can be used for MBR partition now.
Hybird MBR seems only exist in MAC PC?It's too complicated.