RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 952973 - create a invalid logical pool via pool-create-as with wrong --target device
Summary: create a invalid logical pool via pool-create-as with wrong --target device
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: libvirt
Version: 7.0
Hardware: x86_64
OS: Linux
medium
medium
Target Milestone: rc
: ---
Assignee: Martin Kletzander
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-04-17 05:18 UTC by Huang Wenlong
Modified: 2014-06-18 00:48 UTC (History)
8 users (show)

Fixed In Version: libvirt-1.1.1-1.el7
Doc Type: Bug Fix
Doc Text:
Clone Of: 952972
Environment:
Last Closed: 2014-06-13 09:21:05 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Huang Wenlong 2013-04-17 05:18:25 UTC
+++ This bug was initially created as a clone of Bug #952972 +++

Description of problem:
create a invalid logical pool via pool-create-as with wrong --target device
vg should be new which has not lv in it .

Version-Release number of selected component (if applicable):
libvirt-0.10.2-18.el6_4.4.x86_64
libvirt-1.0.4-1.el7.x86_64

How reproducible:
100

Steps to Reproduce:
1. create a logical pool or define then start
create a invalid logical pool via pool-create-as with wrong --target
device which vg has not lv in it.
# virsh pool-create-as sd3 --type logical --target /dev
Pool sd3 created

2.try to create vol via vol-create
# virsh vol-create-as sd3 v1 100M
error: Failed to create vol v1
error: cannot stat file '/dev/v1': No such file or directory

3.create vol via lvm cmd
# lvcreate sd3 --name v1 -L 100M
Logical volume "v1" created
[root@6-217 tmp]# lvs
LV VG Attr LSize Pool Origin Data% Move Log Cpy%Sync Convert
v1 sd3 -wi-a---- 100.00m
[root@6-217 tmp]# ll /dev/sd3/v1
lrwxrwxrwx. 1 root root 7 Apr 16 03:14 /dev/sd3/v1 -> ../dm-0

4.the vol created by lvm cmd will disappear after run vol-create-as
# virsh vol-create-as sd3 v1 100M
error: Failed to create vol v1
error: internal error Child process (/sbin/lvcreate --name v1 -L 102400K
sd3) unexpected exit status 5: Logical volume "v1" already exists in
volume group "sd3"

# lvs
# ll /dev/sd3/v1
ls: cannot access /dev/sd3/v1: No such file or directory

Actual results:
as steps

Expected results:
check target if wrong report error
step4 should not affect vol already created .

Additional info:

Comment 2 Martin Kletzander 2013-06-03 15:06:05 UTC
Patch proposed upstream:

http://www.redhat.com/archives/libvir-list/2013-June/msg00056.html

Comment 3 Martin Kletzander 2013-07-10 17:11:55 UTC
Second proposed version:

http://www.redhat.com/archives/libvir-list/2013-June/msg01177.html

Comment 4 Martin Kletzander 2013-07-15 09:15:45 UTC
v3 proposed:

http://www.redhat.com/archives/libvir-list/2013-July/msg00875.html

Comment 5 Martin Kletzander 2013-07-16 10:26:31 UTC
Moving to POST with commit v1.1.0-198-gefab27a:

commit efab27afbf02743a3a2582e9a111eb1b7d985b26
Author: Martin Kletzander <mkletzan>
Date:   Tue Apr 30 13:48:46 2013 +0200

    Make logical pools independent on target path

Comment 12 Ludek Smid 2014-06-13 09:21:05 UTC
This request was resolved in Red Hat Enterprise Linux 7.0.

Contact your manager or support representative in case you have further questions about the request.


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