Attaching local SAS devices to VMs

Latest response

Hello,

 

I have some local SAS storage that I would like to attach to my VMs but when I try and launch the VM I get the following error.

 

VM gluster02 is down. Exit message: Bad volume specification {'index': '1', 'iface': 'virtio', 'format': 'raw', 'type': 'disk', 'specParams': {}, 'readonly': 'false', 'deviceId': '1b4bb57a-2ec8-4d39-acd3-2555e30a7f9a', 'propagateErrors': 'off', 'device': 'disk', 'shared': 'false', 'GUID': '3600508b1001c9b0489fc22889750f1bf', 'optional': 'false'}.

 

Is it possible to mount local SAS volumes to a VM in the manner with RHEV? I couldn't find much about it on google.

 

Thanks,

 

Andrew

Responses

If the SAS disk is on a DASD, it should be visible to all the hosts via multipath, and that means you can set it up as a directLUN disk. To use local storage, there is a separate procedure in the Admin guide

Hi, I found this but am having problems getting it to work.

The RAID set is there, and I have set it up as a disk.

gluster02_Disk2
1b4bb57a-2ec8-4d39-acd3-2555e30a7f9a
gluster02
1117 GB
3600508b1001c9b0489fc22889750f1bf
SHP_LOGICAL_VOLUME_5001438022587150
HP
LOGICAL VOLUME

This is a volume on the local HP smart array. I have 4 machines (DL380 Gen8) servers with 715k SAS disks and 1SSD in them. I want to give the disks to a VM on each host so I can export them as gluster or other scale out NAS type storage.

When I try to start the VM with the disk attached I get the following error.

VM gluster02 is down. Exit message: Bad volume specification {'index': '1', 'iface': 'virtio', 'format': 'raw', 'type': 'disk', 'specParams': {}, 'readonly': 'false', 'deviceId': '1b4bb57a-2ec8-4d39-acd3-2555e30a7f9a', 'propagateErrors': 'off', 'device': 'disk', 'shared': 'false', 'GUID': '3600508b1001c9b0489fc22889750f1bf', 'optional': 'false'}.

I found this in the guide:
https://access.redhat.com/knowledge/docs/en-US/Red_Hat_Enterprise_Virtualization/3.1/html-single/Evaluation_Guide/index.html#Evaluation_Guide-Create_Storage
I do not want to create a filesystem on the local storage and put image files on there because the performance with that was terrible in the testing that I did.

With virt-install I would do something like: "--disk path=/dev/vg0/pcheese36,device=disk,bus=virtio" or "--disk path=/dev/sda,device=disk,bus=virtio"

Thanks,

Andrew

So let me understand, were you able to set up the local disk as a directLUN? 

That is what I am trying to do although it is failing. After having a look through the logs on the host it appears that qemu is trying to mount the device as an image rather than a file.

Thread-17027::DEBUG::2012-12-08 14:06:36,382::vm::969::vm.Vm::(setDownStatus) vmId=18d9378a-bbe9-4de7-883b-c89b510c004b::Changed state to Down: internal error process exited while connecting to monitor: qemu-kvm: -drive file=/dev/mapper/3600508b1001c9b0489fc22889750f1bf,if=none,id=drive-virtio-disk1,format=raw,serial=,cache=none,werror=stop,rerror=stop,aio=native: could not open disk image /dev/mapper/3600508b1001c9b0489fc22889750f1bf: Permission denied

Here is a screenshot of the GUI.

https://dl.dropbox.com/u/98200887/Screen%20Shot%202012-12-08%20at%201.00.52%20PM.png

Thanks,

Andrew

Some logs

Whole /var/log dir - https://dl.dropbox.com/u/98200887/logs.tar.gz

/var/log/vdsm/libvirt.log

2012-12-08 14:06:34.571+0000: 13513: debug : virDomainCreateXML:1956 : conn=0x7f44b01b6a90, xmlDesc=

gluster02
18d9378a-bbe9-4de7-883b-c89b510c004b
4194304
4194304
4


































<readonly/>




6f392acf-8647-40a9-a5b3-e14d36911f59










hvm




Red Hat
RHEV Hypervisor
6.3-20121121.0.el6_3
32333536-3030-5A43-3232-323830463831_00:9C:02:24:1A:E0
18d9378a-bbe9-4de7-883b-c89b510c004b






<acpi/>


SandyBridge



, flags=0
2012-12-08 14:06:36.372+0000: 13513: error : virNetClientProgramDispatchError:174 : internal error process exited while connecting to monitor: qemu-kvm: -drive file=/dev/mapper/3600508b1001c9b0489fc22889750f1bf,if=none,id=drive-virtio-disk1,format=raw,serial=,cache=none,werror=stop,rerror=stop,aio=native: could not open disk image /dev/mapper/3600508b1001c9b0489fc22889750f1bf: Permission denied

/var/log/vdsm/vdsm.log

Thread-17029::DEBUG::2012-12-08 14:06:35,686::task::588::TaskManager.Task::(_updateState) Task=723f9045-1ca4-48d4-a8b9-7115ea1fd0cf::moving from state init -> state preparing
Thread-17029::INFO::2012-12-08 14:06:35,693::logUtils::37::dispatcher::(wrapper) Run and protect: repoStats(options=None)
Thread-17029::INFO::2012-12-08 14:06:35,694::logUtils::39::dispatcher::(wrapper) Run and protect: repoStats, Return response: {'b2a3daf4-7315-4cd8-a076-4ab005db7410': {'delay': '0.00253701210022', 'lastCheck': '7.2', 'code': 0, 'valid': True}}
Thread-17029::DEBUG::2012-12-08 14:06:35,694::task::1172::TaskManager.Task::(prepare) Task=723f9045-1ca4-48d4-a8b9-7115ea1fd0cf::finished: {'b2a3daf4-7315-4cd8-a076-4ab005db7410': {'delay': '0.00253701210022', 'lastCheck': '7.2', 'code': 0, 'valid': True}}
Thread-17029::DEBUG::2012-12-08 14:06:35,695::task::588::TaskManager.Task::(_updateState) Task=723f9045-1ca4-48d4-a8b9-7115ea1fd0cf::moving from state preparing -> state finished
Thread-17029::DEBUG::2012-12-08 14:06:35,695::resourceManager::809::ResourceManager.Owner::(releaseAll) Owner.releaseAll requests {} resources {}
Thread-17029::DEBUG::2012-12-08 14:06:35,696::resourceManager::844::ResourceManager.Owner::(cancelAll) Owner.cancelAll requests {}
Thread-17029::DEBUG::2012-12-08 14:06:35,696::task::978::TaskManager.Task::(_decref) Task=723f9045-1ca4-48d4-a8b9-7115ea1fd0cf::ref 0 aborting False
Thread-17027::DEBUG::2012-12-08 14:06:36,373::vm::607::vm.Vm::(_startUnderlyingVm) vmId=18d9378a-bbe9-4de7-883b-c89b510c004b::_ongoingCreations released
Thread-17027::ERROR::2012-12-08 14:06:36,373::vm::631::vm.Vm::(_startUnderlyingVm) vmId=18d9378a-bbe9-4de7-883b-c89b510c004b::The vm start process failed
Traceback (most recent call last):
File "/usr/share/vdsm/vm.py", line 597, in _startUnderlyingVm
File "/usr/share/vdsm/libvirtvm.py", line 1419, in _run
File "/usr/lib64/python2.6/site-packages/vdsm/libvirtconnection.py", line 83, in wrapper
File "/usr/lib64/python2.6/site-packages/libvirt.py", line 2489, in createXML
libvirtError: internal error process exited while connecting to monitor: qemu-kvm: -drive file=/dev/mapper/3600508b1001c9b0489fc22889750f1bf,if=none,id=drive-virtio-disk1,format=raw,serial=,cache=none,werror=stop,rerror=stop,aio=native: could not open disk image /dev/mapper/3600508b1001c9b0489fc22889750f1bf: Permission denied

Thread-17027::DEBUG::2012-12-08 14:06:36,382::vm::969::vm.Vm::(setDownStatus) vmId=18d9378a-bbe9-4de7-883b-c89b510c004b::Changed state to Down: internal error process exited while connecting to monitor: qemu-kvm: -drive file=/dev/mapper/3600508b1001c9b0489fc22889750f1bf,if=none,id=drive-virtio-disk1,format=raw,serial=,cache=none,werror=stop,rerror=stop,aio=native: could not open disk image /dev/mapper/3600508b1001c9b0489fc22889750f1bf: Permission denied

The disks are owned by user 'disk' not 'qemu'.

http://lists.ovirt.org/pipermail/users/2012-June/002653.html

Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.