Can't mount ISO to VM: Permission denied

anodos

Sambassador
iXsystems
Joined
Mar 6, 2014
Messages
9,553
Hello, I found a solution for myself. I needed to include user libvirt-qemu to all of the parent datasets and then it worked!
Yeah, this is a fairly common mistake with those unfamiliar with permissions on Unix (Linux / FreeBSD). Users need execute on all parent path components (directories) in order to access a given path. I added extra validation in our ACL editor for 22.02.2 to walk back each path component and raise a validation error if you try to grant access for a user / group in an ACL for a path to which the user can't chdir.
 

Rod_

Cadet
Joined
Jul 18, 2021
Messages
2
Hi,

Had the same issue today with the ISO permission and also when i tried to "chmod" with the root user got "Operation not permitted".

I have tired what @anodos said and it worked.

used the GUI, attached screenshot.
In my ACL permission i have "Group - builtin_users" with Full control.

What i did, searched for the "libvirt-qemu" user in users credentials and add this user to "builtin_users" as an "Auxiliary Groups".

Then it worked.

Hope this help

View attachment 55691

View attachment 55690​

WORKED!
 

Kasazn

Explorer
Joined
Apr 17, 2021
Messages
60
Hi,

Had the same issue today with the ISO permission and also when i tried to "chmod" with the root user got "Operation not permitted".

I have tired what @anodos said and it worked.

used the GUI, attached screenshot.
In my ACL permission i have "Group - builtin_users" with Full control.

What i did, searched for the "libvirt-qemu" user in users credentials and add this user to "builtin_users" as an "Auxiliary Groups".

Then it worked.

Hope this help

View attachment 55691

View attachment 55690​


Thank you for the guide. It worked.
 

TheRiceKing

Dabbler
Joined
Jan 14, 2023
Messages
11
I have the same problem updating from TrueNAS Core 12 few days ago. Must be a bug when upgrading. Does anyone having same problem install a fresh copy of TrueNAS Scale then restore, and importing previous ZFS? I initially upload the ISO to my /mnt/NAS/Data1/AppLib/ISO/ubuntu-22.04-desktop-amd64.iso, it was able to upload the file to it, but can't read. Does that mean it uses different account to upload then libvirt-qemu to read the ISO?

I followed the kb gave libvirt-qemu modify/full access without any luck.
I checked /etc/libvirt/qemu.conf #dynamic_ownership = 1 is the default.
I've Strip ACL, and reset ACL

I'm stuck! :(
I can confirm that this was the solution for me too. Thank you.
 

jayO

Cadet
Joined
Mar 3, 2024
Messages
1
Running TrueNAS-SCALE-23.10.2 for the first time and had the same issue. Was able to select the .iso after relaxing the User - libvirt-qemu ACL on the Dataset where the .iso was located from Read -> Read, Write, and Execute.
 

Attachments

  • Screenshot 2024-03-03 at 21.01.08.png
    Screenshot 2024-03-03 at 21.01.08.png
    456.2 KB · Views: 981
Top