[CentOS-virt] Problems with qemu img disks allocated in a nfs share

carlopmart carlopmart at gmail.com
Sat Mar 16 17:08:42 UTC 2013


On 16/03/2013 16:38, carlopmart wrote:
> Hi all,
>
>   I have a strange problem with qemu img disks allocated in a nfs share
> on a CentOS 6.4 host. Every time when I try to start a vm this error
> appears:
>
> char device redirected to /dev/pts/1
> qemu-kvm: -drive
> file=/data/vmachines/win2k12adsrv/win2k12vol01.img,if=none,id=drive-virtio-disk0,format=qcow2,cache=none:
> could not open disk image /data/vmachines/win2k12adsrv/win2k12vol01.img:
> Permission denied
>
>   Obviously, qemu disk exists:
>
> [root at c64kvm qemu]# ls -la /data/vmachines/win2k12adsrv/win2k12vol01.img
> -rw-r--r-- 1 root root 262144 Mar 16 16:11
> /data/vmachines/win2k12adsrv/win2k12vol01.img
>
>   If I change this qemu disk stored in a nfs share by another stored on
> local disk, all works ok.
>
>   Mount permissions in this kvm host:
>
>   sansrv:/ on /exports type nfs4
> (rw,rsize=32768,wsize=32768,hard,intr,addr=172.25.60.1,clientaddr=172.25.60.2)
>
>
>   and selinux is disabled ... Any idea??

Ok, problem fixed. I've edited the "/etc/libvirt/qemu.conf" file and add 
the lines:

user = "root"
group = "root"

  default is to execute as a qemu user ...

-- 
CL Martinez
carlopmart {at} gmail {d0t} com


More information about the CentOS-virt mailing list