In Red Hat Enterprise Virtualization, attempting to re-use LUNs for block storage domains results in an error due to an issue with LVM that is not likely to be resolved. As a workaround, a certain number of steps can be performed, and these should be called out to users. From: https://bugzilla.redhat.com/show_bug.cgi?id=1215427#c4 pvcreate will fail if a partition exists on the LUN, even with force flag. If you run pvcreate with vvv for verbose ,and a partition is found , the following warning will be logged : 'Skipping: Partition table signature found' pvcreate -ffvvv /dev/mapper/3600a09803753795a64244531644f7846 ........ /dev/mapper/3600a09803753795a64244531644f7846: Skipping: Partition table signature found [none:(nil)] ........ Device /dev/mapper/3600a09803753795a64244531644f7846 not found (or ignored by filtering). In order to be able to be able to create the PV, the partition table needs to be deleted. It can be done by zeroing the first blocks: dd if=/dev/zero of=/dev/mapper/3600a09803753795a64244531644f7846 bs=1M count=1 I don't think that this operation should be done by the application, as it can be destructive to user data. I suggest to document this situation with explanation on how to fix manually.
I suggest adding oflag=direct to the command line to ensure this is not buffered.
I'd suggest 'wipefs -a /dev/...' since it will also call BLKRRPART ioctl to inform kernel about the partition table change.
This sounds more of a KCS material to me, isn't it? Unless we are going to have a troubleshooting storage guide. Once we have such a KCS (not article, but solution), we can reference it from the guide that talks about creating storage domains.
(In reply to Marina from comment #4) > This sounds more of a KCS material to me, isn't it? > Unless we are going to have a troubleshooting storage guide. > Once we have such a KCS (not article, but solution), we can reference it > from the guide that talks about creating storage domains. Lucy / Adam, Please check the attached KCS(there 2) and see if we can point the docs to them and get this bug fixed.
Hi Marina, Thank you for the needinfo request. Changing this to Lucy, who is now directly connected with the RHV documentation. It looks like a quick fix, but Lucy will have a better handle on the current capacity and priorities of the team. Kind regards, Andrew
Thanks for checking on this one, Marina. I agree that pointing to the existing KCS articles would provide a quick and useful fix in this case. Proposing this fix for 4.1 and 4.2.