Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 658556 - app-emulation/libvirt-4.3.0 - fails to run VMs - error: Unable to get devmapper targets for </dev volpath> No such file or directory
Summary: app-emulation/libvirt-4.3.0 - fails to run VMs - error: Unable to get devmapp...
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Linux bug wranglers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-06-20 08:31 UTC by Anton Gubarkov
Modified: 2018-06-30 11:10 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Anton Gubarkov 2018-06-20 08:31:49 UTC
One of my hosts refuse to start any VM if the storage is a block device (with <source dev='/dev...'>).
I tested rge following cases: 1) whole disk mapped to VM; 2) zvol mapped to VM; 3) CDROM mapped to VM via /dev/sr0

All these cases result in a message:
error: Unable to get devmapper targets for /dev/zvol/home64/lab/zfs-lab-root-ext4: No such file or directory

All storage that is contained in a file (qcow2, raw and iso images) works OK.

I can't understand what went wrong. Can you suggest further debugging steps?
Comment 1 Anton Gubarkov 2018-06-20 08:35:25 UTC
qemu is run as qemu user, member of cdrom and disk groups to allow direct disk access.

home64 ~ # groups qemu
disk cdrom kvm disk cdrom kvm qemu
Comment 2 Žilvinas Žaltiena 2018-06-30 09:41:51 UTC
(In reply to Anton Gubarkov from comment #0)
> One of my hosts refuse to start any VM if the storage is a block device
> (with <source dev='/dev...'>).
> I tested rge following cases: 1) whole disk mapped to VM; 2) zvol mapped to
> VM; 3) CDROM mapped to VM via /dev/sr0
> 
> All these cases result in a message:
> error: Unable to get devmapper targets for
> /dev/zvol/home64/lab/zfs-lab-root-ext4: No such file or directory
> 
> All storage that is contained in a file (qcow2, raw and iso images) works OK.
> 
> I can't understand what went wrong. Can you suggest further debugging steps?

Do you have your kernel compiled with Device Mapper support (CONFIG_BLK_DEV_DM)? Since version 4.3 it is needed for sucessfully attaching block devices to vm.
Comment 3 Anton Gubarkov 2018-06-30 11:10:30 UTC
No CONFIG_BLK_DEV_DM was the culprit. Big thanks!