Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
DescriptionAlexander Todorov
2015-12-02 12:57:44 UTC
Description of problem:
I have /dev/sda1 which is a so called biosboot partition and blkid only shows the UUID for it:
# blkid /dev/sda1
/dev/sda1: PARTUUID="990fa6f6-634a-4097-ab48-4215b1a74ffc"
# parted -l
Model: ATA WDC WD1002FAEX-0 (scsi)
Disk /dev/sda: 1000GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt
Disk Flags: pmbr_boot
Number Start End Size File system Name Flags
1 1049kB 2097kB 1049kB bios_grub
2 2097kB 526MB 524MB xfs
3 526MB 1000GB 1000GB lvm
... skip ...
# fdisk -l
WARNING: fdisk GPT support is currently new, and therefore in an experimental phase. Use at your own discretion.
Disk /dev/sda: 1000.2 GB, 1000204886016 bytes, 1953525168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk label type: gpt
# Start End Size Type Name
1 2048 4095 1M BIOS boot parti
2 4096 1028095 500M Microsoft basic
3 1028096 1953523711 931G Linux LVM
Version-Release number of selected component (if applicable):
util-linux-2.23.2-26.el7.x86_64
How reproducible:
Always
Steps to Reproduce:
1. Install a non UEFI x86_64 system with gpt on the kernel command line during install.
2. Selected automatic partitioning.
3.
Actual results:
blkid doesn't give us any indication that sda1 is a biosboot partition.
Expected results:
The opposite.
Additional info:
I'm working on a test which uses blkid output and this is a corner case which isn't covered. blkid is very handy in bash scripts and we need it to somehow identify biosboot partitions.
It depends what are you looking for, I guess (also according to bug #128761) you want to check partition type. GPT uses GUIDs:
"Partition type GUIDs" at https://en.wikipedia.org/wiki/GUID_Partition_Table
blkid provides this by
blkid -p -o udev /dev/sda1
as ID_PART_ENTRY_TYPE= variable, but this is expensive root-only method (it probes for many another things). It's better to reuse information already gathered in udev db,
lsblk -n -o PARTTYPE /dev/sda1
or if you really want to read the data directly from the device (system without udev, etc.) than use:
partx -g -o TYPE /dev/sda1
but recommended is lsblk.
Note that GPT also uses special flags for mark partition as LegacyBIOSBootable (in your parted output), this is provided by blkid as ID_PART_ENTRY_FLAGS=, by partx as FLAGS and by lsblk as PARTFLAGS, in all cases as hex
$ lsblk -n -o PARTFLAGS /dev/sdc1
0x4
Note the same variable is used for MBR flags.
See wikipedia about GPT, section "Partition attributes".
on fedora (>=f22) you can use fdisk/sfdisk to translate the flag to human readable string:
# sfdisk --part-attrs /dev/sdc 1
LegacyBIOSBootable
... note that I don't plan extend libblkid to translate the flags (so WONTFIX, sorry).