Jianfeng Tang
2014-Aug-05 23:23 UTC
[libvirt-users] Ubuntu Trusty: failed to create VM due to permission denied
>Hi, libvirt experts, I used libvirt to create a VM and used backing store to a local file. It works fine until I installed my box to Unbuntu Trusty (14.04). I got the following errors when I tried to start the VM: Could not open backing file: Could not open <path to my backing file>: Permission denied However, if I moved my image file (not base image) to default location /var/lib/libvirt/images. It works. It seems something related to selinux. However, my box seems not have selinux installed at all. Anyone knows how to fix this? Thanks, ~Frank>
Eric Blake
2014-Aug-06 01:27 UTC
Re: [libvirt-users] Ubuntu Trusty: failed to create VM due to permission denied
On 08/05/2014 05:23 PM, Jianfeng Tang wrote:> > However, if I moved my image file (not base image) to default location > /var/lib/libvirt/images. It works. > > It seems something related to selinux. However, my box seems not have > selinux installed at all.It's probably AppArmor, not SELinux; but the concepts are the same - if you have a mandatory access control that libvirt can use, then you have to make sure that non-default locations are permitted through your control mechanism, in order for libvirt sVirt protections to work with your layout.> > Anyone knows how to fix this?Sadly, I don't use AppArmor myself to offer actual advice on it. -- Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org
Jianfeng Tang
2014-Aug-06 16:02 UTC
Re: [libvirt-users] Ubuntu Trusty: failed to create VM due to permission denied
Thank you Eric. Yes, it looks like AppArmor caused the problem. I will google on how to disable it. On 8/5/14 8:27 PM, "Eric Blake" <eblake@redhat.com> wrote:>On 08/05/2014 05:23 PM, Jianfeng Tang wrote: > >> >> However, if I moved my image file (not base image) to default location >> /var/lib/libvirt/images. It works. >> >> It seems something related to selinux. However, my box seems not have >> selinux installed at all. > >It's probably AppArmor, not SELinux; but the concepts are the same - if >you have a mandatory access control that libvirt can use, then you have >to make sure that non-default locations are permitted through your >control mechanism, in order for libvirt sVirt protections to work with >your layout. > >> >> Anyone knows how to fix this? > >Sadly, I don't use AppArmor myself to offer actual advice on it. > >-- >Eric Blake eblake redhat com +1-919-301-3266 >Libvirt virtualization library http://libvirt.org >
Possibly Parallel Threads
- Re: Ubuntu Trusty: failed to create VM due to permission denied
- Re: Ubuntu Trusty: failed to create VM due to permission denied
- Ubuntu Trusty: failed to create VM due to permission denied
- Re: drive-backup command permission denied.. and need some clarification
- Re: Efficient live disk backup with active blockcommit : Failed 'block-commit': Could not reopen file: Permission denied