Bug 1045854 - livecd-iso-to-disk doesn't validate GPT when trying to create UEFI bootable LiveCD
Summary: livecd-iso-to-disk doesn't validate GPT when trying to create UEFI bootable L...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: livecd-tools
Version: 19
Hardware: All
OS: Unspecified
unspecified
medium
Target Milestone: ---
Assignee: Brian Lane
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-12-22 15:12 UTC by Guillaume Bougard
Modified: 2014-01-25 02:21 UTC (History)
6 users (show)

Fixed In Version: livecd-tools-19.8-1.fc19
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-01-21 05:51:41 UTC
Type: Bug


Attachments (Terms of Use)

Description Guillaume Bougard 2013-12-22 15:12:20 UTC
Description of problem:
Trying to create a F20 LiveCD bootable USB stick for an Asus Netbook, the commande fails with the following message:
[root@pkg ~]# livecd-iso-to-disk --reset-mbr --format --noverify --efi Fedora-Live-MATE-Compiz-x86_64-20-1.iso /dev/sde1
WARNING: THIS WILL DESTROY ANY DATA ON /dev/sde!!!
Press Enter to continue or ctrl-c to abort

/dev/sde : 8 octets ont été écrasés à l'index 0x00000200 (gpt) : 45 46 49 20 50 41 52 54
/dev/sde : 8 octets ont été écrasés à l'index 0x1e1fffe00 (gpt) : 45 46 49 20 50 41 52 54
Waiting for devices to settle...
mkfs.fat 3.0.22 (2013-07-19)
EFI boot requires a GPT partition table.
This can be done manually or you can run with --format
[root@pkg ~]#

Version-Release number of selected component (if applicable):
livecd-tools-19.6-1.fc19.x86_64 (but I guess the problem is also on RAWHIDE)

How reproducible:
Important: My system language is "fr_FR.utf8" ...
So "export LANG=fr_FR.utf8" to be sure to reproduce.
livecd-iso-to-disk --reset-mbr --format --efi some.iso /dev/sde1

Additional info:
I guess this is not really a livecd-iso-to-disk but parted one as looking at the code I find first test with "/sbin/parted -m $device p 2>/dev/null |grep -ic :gpt:" in checkGPT sub (L.535 in git repo at that time) fails.
Launching "LANG=C livecd-iso-to-disk ..." will avoid the problem.
I think the fix could be using the same syntax from L.541, so the patch should be:
@@ -528,7 +528,7 @@
     dev=$1
     getdisk $dev
 
-    if [ "$(/sbin/parted -m $device p 2>/dev/null |grep -ic :gpt:)" -eq "0" ]; then
+    if [ "$(LC_ALL=C /sbin/parted -m $device print 2>/dev/null |grep -ic :gpt:)" -eq "0" ]; then
         echo "EFI boot requires a GPT partition table."
         echo "This can be done manually or you can run with --format"
         exitclean

And last point "parted -m /dev/sde print" and "LC_ALL=C parted -m /dev/sde p" work while "parted -m /dev/sde p" doesn't on my "fr_FR.utf8" F19 system. So this is maybe a parted bug too.

Comment 1 Fedora Update System 2014-01-07 23:12:59 UTC
livecd-tools-20.3-1.fc20 has been submitted as an update for Fedora 20.
https://admin.fedoraproject.org/updates/livecd-tools-20.3-1.fc20

Comment 2 Fedora Update System 2014-01-07 23:16:08 UTC
livecd-tools-19.8-1.fc19 has been submitted as an update for Fedora 19.
https://admin.fedoraproject.org/updates/livecd-tools-19.8-1.fc19

Comment 3 Fedora Update System 2014-01-09 07:44:36 UTC
Package livecd-tools-20.3-1.fc20:
* should fix your issue,
* was pushed to the Fedora 20 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing livecd-tools-20.3-1.fc20'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2014-0493/livecd-tools-20.3-1.fc20
then log in and leave karma (feedback).

Comment 4 Guillaume Bougard 2014-01-09 21:52:17 UTC
Tested on F19 with the same iso and same USB key: it works.
Tested also on a computer with F20: it works too.
This issue is fixed for me.
Thank you !!

Comment 5 Fedora Update System 2014-01-21 05:51:41 UTC
livecd-tools-20.3-1.fc20 has been pushed to the Fedora 20 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 6 Fedora Update System 2014-01-25 02:21:45 UTC
livecd-tools-19.8-1.fc19 has been pushed to the Fedora 19 stable repository.  If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.