Description of problem: The parted patch to introduce XVD (xen virtual device) support doesn't update the string table parted uses to print descriptions for different device types ("transports" in parted). This causes parted to die with a message like this when run against an XVD device: [root@dhcp-5-79 ~]# parted /dev/xvda GNU Parted 1.8.1 Using /dev/xvda Welcome to GNU Parted! Type 'help' to view a list of commands. (parted) p Model: Xen Virtual Block Device ( You found a bug in GNU Parted! Here's what you have to do: Don't panic! The bug has most likely not affected any of your data. Help us to fix this bug by doing the following: Check whether the bug has already been fixed by checking the last version of GNU Parted that you can find at: http://ftp.gnu.org/gnu/parted/ Please check this version prior to bug reporting. If this has not been fixed yet or if you don't know how to check, please visit the GNU Parted website: http://www.gnu.org/software/parted for further information. Your report should contain the version of this release (1.8.1) along with the error message below, the output of parted DEVICE unit co print unit s print and additional information about your setup you consider important. Error: SEGV_MAPERR (Address not mapped to object)Aborted (core dumped) Running the suggested "parted DEVICE unit co print unit s print" command causes parted to get stuck in a loop in strlen. Disabling the segfault handler gives corrupted output of the device description, pointing at a problem in the do_print function. The do_print routine has a table mapping PED_DEVICE_* types to string descriptions. This was not updated to include a description for XVD devices, causing the routine to overshoot the end of the array and either segfault or loop inside strlen (and then eventually segfault). Version-Release number of selected component (if applicable): How reproducible: 100% Steps to Reproduce: 1. start parted with an xvd device on the commandline, e.g.: $ parted /dev/xvda 2. Run the print ("p") command Actual results: Parted dies with the above message. If the segfault handler is disabled output appears but the device description is garbage. Expected results: Parted handles xvd devices properly and prints the partition table. Additional info:
Created attachment 248381 [details] fix parted print command for xvd devices Fix the transport array in do_print: - char* transport[13] = {"unknown", "scsi", "ide", "dac960", + char* transport[14] = {"unknown", "scsi", "ide", "dac960", "cpqarray", "file", "ataraid", "i2o", - "ubd", "dasd", "viodasd", "sx8", "dm"}; + "ubd", "dasd", "viodasd", "sx8", "dm", + "xvd"};
This request was evaluated by Red Hat Product Management for inclusion in a Red Hat Enterprise Linux maintenance release. Product Management has requested further review of this request by Red Hat Engineering, for potential inclusion in a Red Hat Enterprise Linux Update release for currently deployed products. This request is not yet committed for inclusion in an Update release.
Partner has tested & verified the patch in comment #1
*** Bug 254621 has been marked as a duplicate of this bug. ***
Fixed in parted-1.8.1-14.el5, moving to MODIFIED.
*** Bug 280181 has been marked as a duplicate of this bug. ***
added to RHEl5.2 release notes under "Resolved Issues": <quote> (ia64) Parted can now understand and correctly print out Xen Virtual Device (XVD) partition labels. This enables paravirtualized guests to now use the parted utility. As such, you no longer need to use parted within dom0 to configure disk partitions on paravirtualized guests. </quote> please advise if any further revisions are required. thanks!
Does this need the "(ia64)" tag? The original problem in parted occurred irrespective of architecture. (Sorry if I've misunderstood comment #11).
The reason this has the ia64 tag is that parted is required on ia64, because fdisk doesn't understand EFI GUID Partition Tables (aka GPT). Most i386/x86_64 use DOS partition tables by default, so they're able to use fdisk. However you're right, the bug would affect any architecture that uses GPT. Since there are x86_64 machines using EFI now, I suspect they're also using GPT and would suffer from this bug. Hope that helps.
Thanks Bryn, Aron. removed ia64 tag, release note will be available in all architectures.
This appears to be the underlying cause of #433950, which I opened probably before searching for parted bugs. My fault, sorry. This breaks conga's storage management when using Xen VMs as cluster nodes.
Right, doesn't actually need any GPT in use - my tests were done with no GPT, iirc. Stuart, if you want I can give you some test packages & you can confirm bug 433950 is a dup of this one if you like?
Hi, the RHEL5.2 release notes will be dropped to translation on April 15, 2008, at which point no further additions or revisions will be entertained. a mockup of the RHEL5.2 release notes can be viewed at the following link: http://intranet.corp.redhat.com/ic/intranet/RHEL5u2relnotesmockup.html please use the aforementioned link to verify if your bugzilla is already in the release notes (if it needs to be). each item in the release notes contains a link to its original bug; as such, you can search through the release notes by bug number. Cheers, Don
An advisory has been issued which should help the problem described in this bug report. This report is therefore being closed with a resolution of ERRATA. For more information on the solution and/or where to find the updated files, please follow the link below. You may reopen this bug report if the solution does not work for you. http://rhn.redhat.com/errata/RHBA-2008-0322.html