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

Mon Mar 18 16:40:08 UTC 2013
SilverTip257 <silvertip257 at gmail.com>

On Sat, Mar 16, 2013 at 1:08 PM, carlopmart <carlopmart at gmail.com> wrote:

> 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"
>

Not a wise idea.


>
>   default is to execute as a qemu user ...
>

Why not fiddle with group ownership and make it so the qemu user will
suffice.


>
> --
> CL Martinez
> carlopmart {at} gmail {d0t} com
> _______________________________________________
> CentOS-virt mailing list
> CentOS-virt at centos.org
> http://lists.centos.org/mailman/listinfo/centos-virt
>



-- 
---~~.~~---
Mike
//  SilverTip257  //
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.centos.org/pipermail/centos-virt/attachments/20130318/35c0935c/attachment-0003.html>