Bug 887971 - pvcreate fails if partition contains a swap signature
pvcreate fails if partition contains a swap signature
Product: Virtualization Tools
Classification: Community
Component: libguestfs (Show other bugs)
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Richard W.M. Jones
Depends On:
  Show dependency treegraph
Reported: 2012-12-17 12:38 EST by Richard W.M. Jones
Modified: 2012-12-21 04:16 EST (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2012-12-17 14:55:49 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Richard W.M. Jones 2012-12-17 12:38:02 EST
Description of problem:

$ guestfish -N part mkswap /dev/sda1 : pvcreate /dev/sda1
libguestfs: error: pvcreate: WARNING: swap signature detected on /dev/sda1. Wipe it? [y/n] 
  Aborting pvcreate on /dev/sda1.

But note that other content is fine.  For example if the
partition contained an ext2 filesystem before, then pvcreate works:

$ guestfish -N part mkfs ext2 /dev/sda1 : pvcreate /dev/sda1
[no error]

Version-Release number of selected component (if applicable):

libguestfs 1.20.0

How reproducible:


Steps to Reproduce:
See above.

Additional information:

For some reason this especially affects the test suite under
RHEL 7.  It may be that a combination of tests has been disabled,
such that when we come to test pvcreate there happens to be
a swap space signature on the partition.
Comment 1 Richard W.M. Jones 2012-12-17 14:55:49 EST
Fixed upstream in:
Comment 2 Richard W.M. Jones 2012-12-21 04:16:29 EST
With 1.20.1-2 package, this works.

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