Using multiple devices within a logical storage pool
This document (7020980) is provided subject to the disclaimer at the end of this document.
Environment
SUSE Linux Enterprise Server 12 Service Pack 2 (SLES 12 SP2)
SUSE Linux Enterprise Server 12 Service Pack 1 (SLES 12 SP1)
Virtual Machine Manager
Situation
kvm_host:~ # virsh pool-define-as eng logical - - '/dev/sda6;/dev/sda7' vg /dev/vg
Pool eng defined
kvm_host:~ # virsh pool-build eng
error: Failed to build pool eng
error: cannot open device '/dev/sda6;/dev/sda7': No such file or directory
Multiple devices have been specified with the following delimiters resulting in the same error: No such file or directory.
'/dev/sda6;/dev/sda7'
'/dev/sda[6-7]'
'/dev/sda6 /dev/sda7'
'/dev/sda6:/dev/sda7'
When attempting to create a logical volume with more than one device, similar error dialogs are observed:
From virt-manager, selct Edit > Connection Details > Storage > "+"
Name: lvm-pool, Type: logical: LVM Volume Group > Forward
Target Path: /dev/vg00, Source Path: /dev/sda5,/dev/sda6, Build Pool: Checked
The following error is observed:
"Error creating pool: Could not build storage pool: cannot open device '/dev/sda5,/dev/sda6': No such file or directory"
Resolution
kvm_host:~ # pvcreate /dev/sda[5-7]
Physical volume "/dev/sda5" successfully created
Physical volume "/dev/sda6" successfully created
Physical volume "/dev/sda7" successfully created
kvm_host:~ # vgcreate vg00 /dev/sda[5-7]
Volume group "vg00" successfully created
kvm_host:~ # pvs
PV VG Fmt Attr PSize PFree
/dev/sda5 vg00 lvm2 a-- 100.00g 100.00g
/dev/sda6 vg00 lvm2 a-- 100.00g 100.00g
/dev/sda7 vg00 lvm2 a-- 100.00g 100.00g
kvm_host:~ # vgs
VG #PV #LV #SN Attr VSize VFree
vg00 3 0 0 wz--n- 299.99g 299.99g
From virt-manager, selct Edit > Connection Details > Storage > "+"
Name: lvm-pool, Type: logical: LVM Volume Group > Forward
Target Path: /dev/vg00, Source Path: <null>, Build Pool: Not Checked
Add New Volumes to the Storage Pool for virtual machine use.
Volumes "+", Name: vol1, Capacity: 20G > Finish
Notice vol1 appears in the list of volumes. If you run the lvs command on the server, you will also notice that a new logical volume named vol1 has been created.
kvm_host:~ # lvs
LV VG Attr LSize Pool Origin Data% Meta% Move Log Cpy%Sync Convert
vol1 vg00 -wi-a----- 20.00g
Cause
Disclaimer
This Support Knowledgebase provides a valuable tool for SUSE customers and parties interested in our products and solutions to acquire information, ideas and learn from one another. Materials are provided for informational, personal or non-commercial use within your organization and are presented "AS IS" WITHOUT WARRANTY OF ANY KIND.
- Document ID:7020980
- Creation Date: 16-Jun-2017
- Modified Date:03-Mar-2020
-
- SUSE Linux Enterprise Server
For questions or concerns with the SUSE Knowledgebase please contact: tidfeedback[at]suse.com