Bug 1138523 - The name and format of volume in disk pool are changed after pool refreshed
Summary: The name and format of volume in disk pool are changed after pool refreshed
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: libvirt
Version: 6.6
Hardware: x86_64
OS: Linux
medium
medium
Target Milestone: rc
: ---
Assignee: John Ferlan
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Keywords:
Depends On: 1138516
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-09-05 05:10 UTC by yangyang
Modified: 2015-07-22 05:47 UTC (History)
8 users (show)

(edit)
Previously, using the "virsh pool-refresh" command, or restarting or refreshing the libvirtd service after renaming a virtual storage volume in some cases caused the "virsh vol-list" to display an incorrect name for the renamed storage volume. This update adds a check for the resulting name, which returns an error if the storage volume name is incorrect.
Clone Of: 1138516
(edit)
Last Closed: 2015-07-22 05:47:12 UTC


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2015:1252 normal SHIPPED_LIVE libvirt bug fix update 2015-07-20 17:50:06 UTC

Comment 5 yangyang 2015-02-27 06:23:06 UTC
Hi John,
When the provided volume name doesn't match what parted generated as the
partition name, error out. HOWEVER, checking parted, partition was indeed created. Volume appears after pool was refreshed. 

Actual results on libvirt-0.10.2-49.el6.x86_64

1. define, build and start disk pool
# virsh pool-define disk-pool.xml 
Pool disk-pool defined from disk-pool.xml

[root@rhel6u6-test yy]# virsh pool-build disk-pool --overwrite
Pool disk-pool built

[root@rhel6u6-test yy]# virsh pool-start disk-pool
Pool disk-pool started

2. check /dev/sdb, make sure no partitions.
# parted /dev/sdb
GNU Parted 2.1
Using /dev/sdb
Welcome to GNU Parted! Type 'help' to view a list of commands.
(parted) print                                                            
Model: Alcor Flash Disk (scsi)
Disk /dev/sdb: 1048MB
Sector size (logical/physical): 512B/512B
Partition Table: msdos

Number  Start  End  Size  Type  File system  Flags

(parted)                  

3. create a volume specifying name as vol1
#virsh vol-create-as disk-pool vol1 100M
error: Failed to create vol vol1
error: invalid argument: invalid partition name 'vol1', expected 'sdb1'

4. check parted
[root@rhel6u6-test yy]# parted /dev/sdb
GNU Parted 2.1
Using /dev/sdb
Welcome to GNU Parted! Type 'help' to view a list of commands.
(parted) print                                                            
Model: Alcor Flash Disk (scsi)
Disk /dev/sdb: 1048MB
Sector size (logical/physical): 512B/512B
Partition Table: msdos

Number  Start   End    Size   Type     File system  Flags
 1      32.3kB  105MB  105MB  primary

(parted)     

[sdb1 was created.]

5. list volume
 # virsh vol-list disk-pool
Name                 Path                                    
-----------------------------------------

6. refresh pool and then list volume
# virsh pool-refresh disk-pool
Pool disk-pool refreshed

[root@rhel6u6-test yy]# virsh vol-list disk-pool
Name                 Path                                    
-----------------------------------------
sdb1                 /dev/sdb1

Comment 11 yangyang 2015-03-05 02:13:58 UTC
Okay. Creating a volume with the provided volume name doesn't match what parted generated as the partition name, return an error. After refresh pool, volume with a name match what parted generated appears. According to comment #5, change the status to verified.

Comment 13 errata-xmlrpc 2015-07-22 05:47:12 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHBA-2015-1252.html


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