Bug 918217 - [PATCH] Parted incorrectly fails when writing a label to a loop device
Summary: [PATCH] Parted incorrectly fails when writing a label to a loop device
Keywords:
Status: CLOSED WORKSFORME
Alias: None
Product: Fedora
Classification: Fedora
Component: parted
Version: 19
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Brian Lane
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-03-05 17:56 UTC by Torrie Fischer
Modified: 2014-02-01 00:44 UTC (History)
1 user (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2014-02-01 00:44:23 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
Patch to ignore partition limits on loop devices (525 bytes, patch)
2013-03-05 17:56 UTC, Torrie Fischer
no flags Details | Diff

Description Torrie Fischer 2013-03-05 17:56:39 UTC
Created attachment 705564 [details]
Patch to ignore partition limits on loop devices

Description of problem:

Parted incorrectly fails when writing a label to a loop device


Version-Release number of selected component (if applicable):
3.1-9.fc18.i686

How reproducible:

Every time

Steps to Reproduce:

1. Setup a koji builder running kernel 2.6.32-276.el6.x86_64
2. Submit a mostly empty kickstart file to spin an appliance
  
Actual results:

appliance.log contains:
Adding disk sda as /var/tmp/imgcreate-8WhAhT/tmp-vFtiAE/koji-image-dist-aether-1-build-395-201303051105-sda.raw
Extending sparse file /var/tmp/imgcreate-8WhAhT/tmp-vFtiAE/koji-image-dist-aether-1-build-395-201303051105-sda.raw to 10737418240
Losetup add /dev/loop0 mapping to /var/tmp/imgcreate-8WhAhT/tmp-vFtiAE/koji-image-dist-aether-1-build-395-201303051105-sda.raw
Formatting disks
Initializing partition table for /dev/loop0 with msdos layout
Unable to create appliance : Failed mount disks : Error writing partition table on /dev/loop0
Losetup remove /dev/loop0

Expected results:

A successful build

Additional info:

Upstream parted bug tracker seems to be down, so I can't send this upstream for any kind of review. However, this is a small patch that would be really super nice to have in the next F18 update.

The patch lets parted assume that the underlying device has no limit on partitions if it is a loop device. It also skips telling the OS that it should reload the partition table, which isn't supported for loop devices on Linux anyways afaik.

Comment 1 Brian Lane 2013-03-13 17:54:32 UTC
I'm not sure what's going on, but parted works fine with loop devices.

Comment 2 Fedora End Of Life 2013-04-03 13:49:05 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 19 development cycle.
Changing version to '19'.

(As we did not run this process for some time, it could affect also pre-Fedora 19 development
cycle bugs. We are very sorry. It will help us with cleanup during Fedora 19 End Of Life. Thank you.)

More information and reason for this action is here:
https://fedoraproject.org/wiki/BugZappers/HouseKeeping/Fedora19


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