Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

efibootmgr: Make the default output cleaner #221

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

DaiZW007
Copy link

Make the default output cleaner

If you bring device information, some boot options will be displayed too much and affect the experience.

@DaiZW007
Copy link
Author

sudo efibootmgr
BootCurrent: 0006
Timeout: 3 seconds
BootOrder: 0006,0003,0001,0002,0000,0004,0005
Boot0000* Enter Setup
Boot0001 UEFI BootManagerMenuApp
Boot0002* UEFI WDC WD40EZAX-00C8UB0 WD-WX42D7404FPV
Boot0003* UEFI FORESEE 256GB SSD MP19B89519511 1
Boot0004* UEFI Shell
Boot0005 UEFI FASTBOOT App
Boot0006* UOS (EFI stub)

sudo efibootmgr -u
BootCurrent: 0006
Timeout: 3 seconds
BootOrder: 0006,0003,0001,0002,0000,0004,0005
Boot0000* Enter Setup FvVol(7cb8bdc9-f8eb-4f34-aaea-3ee4af6516a1)/FvFile(462caa21-7614-4503-836e-8ab6f4662331)І
Boot0001 UEFI BootManagerMenuApp FvVol(7cb8bdc9-f8eb-4f34-aaea-3ee4af6516a1)/FvFile(eec25bdc-67f2-4d95-b1d5-f81b2039d11d)�
Boot0002* UEFI WDC WD40EZAX-00C8UB0 WD-WX42D7404FPV PciRoot(0x0)/Pci(0x8,0x0)/Sata(0,65535,0)걎脈鼑䵙຅᫢ⱒ뉙
Boot0003* UEFI FORESEE 256GB SSD MP19B89519511 1 PciRoot(0x0)/Pci(0xd,0x0)/Pci(0x0,0x0)/NVMe(0x1,3A-5A-27-02-30-00-0F-A6)걎脈鼑䵙຅᫢ⱒ뉙Ͽ
Boot0004* UEFI Shell FvVol(7cb8bdc9-f8eb-4f34-aaea-3ee4af6516a1)/FvFile(7c04a583-9e3e-4f1c-ad65-e05268d0b4d1)Ї
Boot0005 UEFI FASTBOOT App FvVol(7cb8bdc9-f8eb-4f34-aaea-3ee4af6516a1)/FvFile(c840e6f6-0b40-4ab0-931a-d58a5992194a)�
Boot0006* UOS (EFI stub) HD(1,GPT,82f3e1c8-8654-4797-a584-90f373331323,0x800,0x96000)/\EFI\BOOT\vmlinuz.root=/dev/nvme0n1p5 resume=/dev/nvme0n1p3 ro video=efifb:nobgrt splash quiet fsck.mode=skip console=ttyS0,115200n8 loglevel=0 logo.selectlogo=1 selinux=0 ima_appraise=off libahci.ignore_sss=1

sudo efibootmgr -v
BootCurrent: 0006
Timeout: 3 seconds
BootOrder: 0006,0003,0001,0002,0000,0004,0005
Boot0000* Enter Setup FvVol(7cb8bdc9-f8eb-4f34-aaea-3ee4af6516a1)/FvFile(462caa21-7614-4503-836e-8ab6f4662331)06040000
dp: 04 07 14 00 c9 bd b8 7c eb f8 34 4f aa ea 3e e4 af 65 16 a1 / 04 06 14 00 21 aa 2c 46 14 76 03 45 83 6e 8a b6 f4 66 23 31 / 7f ff 04 00
data: 06 04 00 00
Boot0001 UEFI BootManagerMenuApp FvVol(7cb8bdc9-f8eb-4f34-aaea-3ee4af6516a1)/FvFile(eec25bdc-67f2-4d95-b1d5-f81b2039d11d)feff0000
dp: 04 07 14 00 c9 bd b8 7c eb f8 34 4f aa ea 3e e4 af 65 16 a1 / 04 06 14 00 dc 5b c2 ee f2 67 95 4d b1 d5 f8 1b 20 39 d1 1d / 7f ff 04 00
data: fe ff 00 00
Boot0002* UEFI WDC WD40EZAX-00C8UB0 WD-WX42D7404FPV PciRoot(0x0)/Pci(0x8,0x0)/Sata(0,65535,0)4eac0881119f594d850ee21a522c59b212030000
dp: 02 01 0c 00 d0 41 03 0a 00 00 00 00 / 01 01 06 00 00 08 / 03 12 0a 00 00 00 ff ff 00 00 / 7f ff 04 00
data: 4e ac 08 81 11 9f 59 4d 85 0e e2 1a 52 2c 59 b2 12 03 00 00
Boot0003* UEFI FORESEE 256GB SSD MP19B89519511 1 PciRoot(0x0)/Pci(0xd,0x0)/Pci(0x0,0x0)/NVMe(0x1,3A-5A-27-02-30-00-0F-A6)4eac0881119f594d850ee21a522c59b2ff030000
dp: 02 01 0c 00 d0 41 03 0a 00 00 00 00 / 01 01 06 00 00 0d / 01 01 06 00 00 00 / 03 17 10 00 01 00 00 00 3a 5a 27 02 30 00 0f a6 / 7f ff 04 00
data: 4e ac 08 81 11 9f 59 4d 85 0e e2 1a 52 2c 59 b2 ff 03 00 00
Boot0004* UEFI Shell FvVol(7cb8bdc9-f8eb-4f34-aaea-3ee4af6516a1)/FvFile(7c04a583-9e3e-4f1c-ad65-e05268d0b4d1)07040000
dp: 04 07 14 00 c9 bd b8 7c eb f8 34 4f aa ea 3e e4 af 65 16 a1 / 04 06 14 00 83 a5 04 7c 3e 9e 1c 4f ad 65 e0 52 68 d0 b4 d1 / 7f ff 04 00
data: 07 04 00 00
Boot0005 UEFI FASTBOOT App FvVol(7cb8bdc9-f8eb-4f34-aaea-3ee4af6516a1)/FvFile(c840e6f6-0b40-4ab0-931a-d58a5992194a)feff0000
dp: 04 07 14 00 c9 bd b8 7c eb f8 34 4f aa ea 3e e4 af 65 16 a1 / 04 06 14 00 f6 e6 40 c8 40 0b b0 4a 93 1a d5 8a 59 92 19 4a / 7f ff 04 00
data: fe ff 00 00
Boot0006* UOS (EFI stub) HD(1,GPT,82f3e1c8-8654-4797-a584-90f373331323,0x800,0x96000)/\EFI\BOOT\vmlinuz.72006f006f0074003d002f006400650076002f006e0076006d00650030006e00310070003500200072006500730075006d0065003d002f006400650076002f006e0076006d00650030006e00310070003300200072006f00200076006900640065006f003d00650066006900660062003a006e006f0062006700720074002000730070006c0061007300680020007100750069006500740020006600730063006b002e006d006f00640065003d0073006b0069007000200063006f006e0073006f006c0065003d00740074007900530030002c003100310035003200300030006e00380020006c006f0067006c006500760065006c003d00300020006c006f0067006f002e00730065006c006500630074006c006f0067006f003d0031002000730065006c0069006e00750078003d003000200069006d0061005f00610070007000720061006900730065003d006f006600660020006c006900620061006800630069002e00690067006e006f00720065005f007300730073003d003100
dp: 04 01 2a 00 01 00 00 00 00 08 00 00 00 00 00 00 00 60 09 00 00 00 00 00 c8 e1 f3 82 54 86 97 47 a5 84 90 f3 73 33 13 23 02 02 / 04 04 30 00 5c 00 45 00 46 00 49 00 5c 00 42 00 4f 00 4f 00 54 00 5c 00 76 00 6d 00 6c 00 69 00 6e 00 75 00 7a 00 2e 00 65 00 66 00 69 00 00 00 / 7f ff 04 00
data: 72 00 6f 00 6f 00 74 00 3d 00 2f 00 64 00 65 00 76 00 2f 00 6e 00 76 00 6d 00 65 00 30 00 6e 00 31 00 70 00 35 00 20 00 72 00 65 00 73 00 75 00 6d 00 65 00 3d 00 2f 00 64 00 65 00 76 00 2f 00 6e 00 76 00 6d 00 65 00 30 00 6e 00 31 00 70 00 33 00 20 00 72 00 6f 00 20 00 76 00 69 00 64 00 65 00 6f 00 3d 00 65 00 66 00 69 00 66 00 62 00 3a 00 6e 00 6f 00 62 00 67 00 72 00 74 00 20 00 73 00 70 00 6c 00 61 00 73 00 68 00 20 00 71 00 75 00 69 00 65 00 74 00 20 00 66 00 73 00 63 00 6b 00 2e 00 6d 00 6f 00 64 00 65 00 3d 00 73 00 6b 00 69 00 70 00 20 00 63 00 6f 00 6e 00 73 00 6f 00 6c 00 65 00 3d 00 74 00 74 00 79 00 53 00 30 00 2c 00 31 00 31 00 35 00 32 00 30 00 30 00 6e 00 38 00 20 00 6c 00 6f 00 67 00 6c 00 65 00 76 00 65 00 6c 00 3d 00 30 00 20 00 6c 00 6f 00 67 00 6f 00 2e 00 73 00 65 00 6c 00 65 00 63 00 74 00 6c 00 6f 00 67 00 6f 00 3d 00 31 00 20 00 73 00 65 00 6c 00 69 00 6e 00 75 00 78 00 3d 00 30 00 20 00 69 00 6d 00 61 00 5f 00 61 00 70 00 70 00 72 00 61 00 69 00 73 00 65 00 3d 00 6f 00 66 00 66 00 20 00 6c 00 69 00 62 00 61 00 68 00 63 00 69 00 2e 00 69 00 67 00 6e 00 6f 00 72 00 65 00 5f 00 73 00 73 00 73 00 3d 00 31 00

KKoukiou added a commit to KKoukiou/anaconda that referenced this pull request Dec 19, 2024
Modified the code to handle invalid UTF-8 characters in the output of the efibootmgr command by
using `errors="ignore"`. This prevents decode exceptions when encountering non-UTF-8 sequences
in the EFI boot manager output.

This should be reverted when this is fixed upstream in the efibootmgr:
Possible fix: rhboot/efibootmgr#221

Resolves: rhbz#2254801
KKoukiou added a commit to KKoukiou/anaconda that referenced this pull request Dec 19, 2024
Modified the code to handle invalid UTF-8 characters in the output of the efibootmgr command by
using `errors="ignore"`. This prevents decode exceptions when encountering non-UTF-8 sequences
in the EFI boot manager output.

This should be reverted when this is fixed upstream in the efibootmgr:
Possible fix: rhboot/efibootmgr#221

Resolves: rhbz#2254801
KKoukiou added a commit to KKoukiou/anaconda that referenced this pull request Dec 19, 2024
Modified the code to handle invalid UTF-8 characters in the output of the efibootmgr command by
using `errors="ignore"`. This prevents decode exceptions when encountering non-UTF-8 sequences
in the EFI boot manager output.

This should be reverted when this is fixed upstream in the efibootmgr:
Possible fix: rhboot/efibootmgr#221

Resolves: rhbz#2254801
@vathpela
Copy link
Contributor

I don't understand how the intent here is honored with this implementation - it triggers different output based on --unicode, which is documented as changing how input is treated. At the very least this would also need a documentation change, but honestly it just looks like a weird choice to me.

What's the goal here?

KKoukiou added a commit to KKoukiou/anaconda that referenced this pull request Dec 20, 2024
Modified the code to handle invalid UTF-8 characters in the output of the efibootmgr command by
using `errors="ignore"`. This prevents decode exceptions when encountering non-UTF-8 sequences
in the EFI boot manager output.

This should be reverted when this is fixed upstream in the efibootmgr:
Possible fix: rhboot/efibootmgr#221

Resolves: rhbz#2254801
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants