Yet another Sonarr/Radarr permission issue

Joined
Jan 7, 2015
Messages
1,155
Currently you are mounting to /downloads and /tv as per the quote from above..
 
Joined
Jan 7, 2015
Messages
1,155
Ok, im going to go thru this one more time.. Sonarr is telling you that it is trying to import shows from /media/downloads/tv/Criminal.Minds.S15E06.720p.HDTV.x264-AVS/.... But the actual directory you should be importing from is /downloads/tv/Criminal.Minds.S15E06.720p.HDTV.x264-AVS as you have it

Option 1.
You should make your mounts be this,

Source: /mnt/Rivendell/media/downloads/tv
Destination: /mnt/iocage/jails/sonarr/root/media/downloads/tv
-and-
Source: /mnt/Rivendell/media/tv
Destination: /mnt/iocage/jails/sonarr/root/media/tv

Then because I know that your /media folder is owned by root you should do chown media:media /media inside the sonarr jail or issue iocage exec sonarr chown media:media /media

Option 2.
Simply tell Sonarr to import shows from /downloads/tv instead.

Then for good measure I would do iocage restart sonarr or restart the jail from the GUI.
 

ChiknNutz

Patron
Joined
Nov 6, 2015
Messages
217
I do believe we are making progress. However, I now have this warning (no longer considered an error) in Sonarr

Unable to apply permissions to: /tv/Criminal Minds/Season 15/Criminal Minds - S15E06 - Date Night HDTV-720p.mkv: Error setting file owner and/or group: EPERM

What is odd is that the episodes no longer show up in the Sonarr queue, but also do not show up in the actual media dataset (not in the "downloads" folder nor in the folder they typically get moved to...the shown name and season sub folder, not sure where they are. I did just as you mentioned with the mount points, fyi.

I read up that some of these permission issues have something to do with "Windows ACL"...not sure what that really is.
 
Joined
Jan 7, 2015
Messages
1,155
In the advanced settings of media management in Sonarr do you have something similar?? If not I would make it so. Is nogroup 816?

Screenshot from 2020-02-07 19-34-23.png
 
Joined
Jan 7, 2015
Messages
1,155
Also I noticed that the user media does in fact own the media from within freenas, but you have nogroup as the group owner. Why not also have the group media be the group? Seems cleaner. Then chown everything to user media group media, set permissions within sonarr to 0777 and chown to user media group media
 

SweetAndLow

Sweet'NASty
Joined
Nov 6, 2013
Messages
6,421
Ok, im going to go thru this one more time.. Sonarr is telling you that it is trying to import shows from /media/downloads/tv/Criminal.Minds.S15E06.720p.HDTV.x264-AVS/.... But the actual directory you should be importing from is /downloads/tv/Criminal.Minds.S15E06.720p.HDTV.x264-AVS as you have it

Option 1.
You should make your mounts be this,

Source: /mnt/Rivendell/media/downloads/tv
Destination: /mnt/iocage/jails/sonarr/root/media/downloads/tv
-and-
Source: /mnt/Rivendell/media/tv
Destination: /mnt/iocage/jails/sonarr/root/media/tv

Then because I know that your /media folder is owned by root you should do chown media:media /media inside the sonarr jail or issue iocage exec sonarr chown media:media /media

Option 2.
Simply tell Sonarr to import shows from /downloads/tv instead.
This! you need to do this. It's exactly what I told you to do 2 days ago but you never did it.
 

ChiknNutz

Patron
Joined
Nov 6, 2015
Messages
217
SSH to the sonarr jail or the freenas host and enter sonarr jail iocage console SONARRJAIL and do
ll /
and see what user owns the folders tv and downloads. Is it media:media? The owner will likely be root if you didnt create them as media. Also im pretty sure the media user UID by default on freenas and in all jails should be/is/was uid=8675309 unless you need 816 for a reason. I can't confirm if this has changed, mine has been set for so long. The key is making the two media users uid and gid match each other (8675309 by default), the media user in the jail and the media user on the host. Then of course the user media should own the actual MEDIA datasets in question on the host. Its important if using the GUI to not own anything but your media to the media user of course. And before doing anything id do a recursive snapshot of every pool.

In any case once you have two media users (one jail, one host) with matching uid/gid's a simple chown media:media /tv && chown media:media /downloads will likely fix this issue. This command should be issued from a SSH terminal inside the sonarr jail.

Follow this exact same procedure with every jail you ever create and you will be rid of this forever.

Is this also true of the Plex plugin? Meaning, should media:media also be the jail users? Plex is giving me some sporadic issues and am not sure if the user "plex" or "media" should own the media datasets. Specifically, I have new content that is visible in the Windows environment, but Plex will not pick it up. It did show up, then it inexplicably disappeared from Plex. I admit I have been playing with the permissions in the jails, so it's possible I've botched it. I have also done the "Plex Dance" several times with no love.

Point to note, I checked my plex jail in my old warden jail and "root:wheel" is the owner of all the jail folders.
 
Last edited:
Joined
Jan 7, 2015
Messages
1,155
First everything you are doing applies to each jail that you run, users, groups, mounts, permissions.. I should take time to point out that as far as I can tell it does not hurt to just have one big jail with all these "like" softwares dealing with media running in it. Instead of one for each thing you run, have one BIG media jail running plex, cp, hp, drone, transmission, etc, etc. Then one set of mounts, one set of users (media) one set of permissions. It makes all this so much simpler. But... It will be easier to "hose" the jail should you get nuts. Plex by default will run as user plex unless you tell it not to. So now the user plex wants to deal with things that user media owns. But outside of the plex jail nobody else systemwide knows who the user plex is, the user plex will be represented as its UID.

So do the same things to the plex jail that you did for the sonarr jail as far as mounts, users, permissions.
 
Top