SABnzbd file permissions

Status
Not open for further replies.

skirven

Cadet
Joined
Feb 27, 2012
Messages
9
Hi,
I've seen several references to this issue, and I can't seem to get a resolution on it. I have SABnzbd installed in a jail, and when I try to set the folders for incomplete and complete, I keep getting "error accessing".

Things I've tried:
1) Setting the ZFS permissions to be root / wheel, and fill permissions (but the Other / write bit won't save... ?)
2) Setting the ZFS permissions to be nobody / nogroup and same global permissions
3) Setting the ZFS permissions to be Windows, and it also doesn't work
4) chmod in my terminal says I can't do it, and sudo won't work either (even though I have the bit checked in my admin user)

I'm confused on the permissions issue, because if it's full permit, wouldn't *anything* be able to access it? I feel like I'm overlooking something silly, but just can't seem to find it.

Here's a sample of the permissions as I see them.

drwxrwxr-x+ 43 nobody nogroup

As for the install, I'm using the latest pbi I could find, and just loaded it. I didn't do anything else in that.
Thanks!
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
Hi,
I've seen several references to this issue, and I can't seem to get a resolution on it. I have SABnzbd installed in a jail, and when I try to set the folders for incomplete and complete, I keep getting "error accessing".

Things I've tried:
1) Setting the ZFS permissions to be root / wheel, and fill permissions (but the Other / write bit won't save... ?)
2) Setting the ZFS permissions to be nobody / nogroup and same global permissions
3) Setting the ZFS permissions to be Windows, and it also doesn't work
4) chmod in my terminal says I can't do it, and sudo won't work either (even though I have the bit checked in my admin user)

I'm confused on the permissions issue, because if it's full permit, wouldn't *anything* be able to access it? I feel like I'm overlooking something silly, but just can't seem to find it.

Here's a sample of the permissions as I see them.

drwxrwxr-x+ 43 nobody nogroup

As for the install, I'm using the latest pbi I could find, and just loaded it. I didn't do anything else in that.
Thanks!
Are you setting ownership/permissions for the dataset that you are mounting into the jail?
Or the actual sabnzbd jail's dataset? (DONT DO THIS)

Did you already create the folders for complete/incomplete downloads?
Can you "Browse" to the folder from sabnzbd's Folders page?
Can you see the folders when on the commandline as root in the jail?
 

skirven

Cadet
Joined
Feb 27, 2012
Messages
9
Ahhh.. I wonder now if I'm misconfigured. I've got it like this:
1) Jail Root: /mnt/Main
2) Media Jail Storage Mount: /mnt/Main/Video

So I'm running both from the *same* dataset. Do I create a Dataset for Jails and one for the media?
My Complete and Incomplete folders already existed, and I could browse to them.
I could see the files in the Jail. Unfortunately, I've done something weird, and it won't start now.
I've only been making permissions changes against the dataset, inside the Freenas UI. I'm not running chmod commands.

So really, at this point, I can start over. What step am I missing? If there's a how to I haven't found, I'm glad to have that too. :)
Thanks!

ETA - I recreated the jail, using a new "jail" set, and I'm having the same issue in Sabnzbdplus. I consoled to the jail using the Freenas gui, and I was able to create a file into the incomplete folder, and the entire folder was showing the same permissions and owned by root/wheel. So something's still not right. :(
 
Last edited:

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
I suggest you..
  • delete everything you setup thus far. (plugins & jails)
  • create a jail dataset /mnt/Main/jails and set this as your "Jail Root". I think FreeNAS would have set this up by default if you downloaded+installed sabnzbd from the plugins repo instead of loading the PBI.
  • create a dataset for your videos/downloads, I personally put these all on the same dataset names "media"
  • mount this dataset in the sabnzbd jail
  • only change ownership/permissions for the dataset with your media. If you mess with the permissions of the actual jail dataset (which are basically operating system + program files) the jail will likely stop working properly
There are tons of guides around but I can't vouch for a specific one. On my blog (search jruehlig) I have a writeup of my exact steps to setup a complete downloading system, but this may be more than you want to do.
 

skirven

Cadet
Joined
Feb 27, 2012
Messages
9
Thanks. And yes, I did update the jail as you mentioned. The permissions look basically the same, and I can touch my incomplete folder. :( I'll just have to keep digging. I'll update this post if/when I find a solution. :)
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
Following your guide here: https://www.jruehlig.com/wordpress/installation-configuration-of-freenas-plugins/ - I created a user called "media" and updated the chown for the sabnzbd folder (like you did in your example for Sickbeard), but yet, I still get the permissions error, and am still able to touch files in that folder... :(
Just to clarify, can you "Browse" to them from the sabnzbd config>folders page? This would verify that they exist and are readable from the "media" user that sabnzbd is running as.

If you can browse to it, show the output of "ls -l" on the folders when on the command line in the jail.
 

skirven

Cadet
Joined
Feb 27, 2012
Messages
9
Yes, I can see the folder in the browse in Sabnzbd.

root@Media:/media/downloaded_tv/incomplete # ls -all
total 82
drwxrwxr-x+ 2 816 816 4 Nov 11 19:07 .
drwxrwxr-x+ 60 816 816 65 Nov 11 17:47 ..
-rwxrwxr-x+ 1 816 816 39940 Nov 2 14:26 .DS_Store
-rwxrwxr-x+ 1 816 816 0 Nov 11 17:24 test
root@Media:/media/downloaded_tv/incomplete #

How can I verify the user "media" is running sabnzbd? I'm not finding the daemon script so I can check it myself. :( I also looked back over your notes, and didn't see where you called that out. I was going to watch the Youtube video in the morning.... :(
Thanks again!
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
Yes, I can see the folder in the browse in Sabnzbd.

root@Media:/media/downloaded_tv/incomplete # ls -all
total 82
drwxrwxr-x+ 2 816 816 4 Nov 11 19:07 .
drwxrwxr-x+ 60 816 816 65 Nov 11 17:47 ..
-rwxrwxr-x+ 1 816 816 39940 Nov 2 14:26 .DS_Store
-rwxrwxr-x+ 1 816 816 0 Nov 11 17:24 test
root@Media:/media/downloaded_tv/incomplete #

How can I verify the user "media" is running sabnzbd? I'm not finding the daemon script so I can check it myself. :( I also looked back over your notes, and didn't see where you called that out. I was going to watch the Youtube video in the morning.... :(
Thanks again!
It looks like you did this from the jail's perspective, which is correct. However it's showing the UID 816, instead of the "media" user, which leads me to believe you don't have the "media" user added in your jail. This should be added by default with the sabnzbd plugin.

It is "media" by default, it's set in /usr/local/etc/rc.d/sabnzbd (from the jail's perspective). you can verify by running "ps aux" and seeing the user running the sabnzbd process.
 

skirven

Cadet
Joined
Feb 27, 2012
Messages
9
I think I see where this is going. I used the PBI you indicated. However, I didn't have a "media" user configured. So I'll have to blow this out again, and recreate the jail with the user permissions in place for the "media" user. I'll take a look at this tomorrow. Thanks again!
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
I think I see where this is going. I used the PBI you indicated. However, I didn't have a "media" user configured. So I'll have to blow this out again, and recreate the jail with the user permissions in place for the "media" user. I'll take a look at this tomorrow. Thanks again!
you shouldn't have to add a media user for inside the jail, it should be created automatically. K, welcome.
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949

Christopher Joyson

Contributor
Joined
May 22, 2014
Messages
105
I now have this Same problem, but previously Had Sabnzbd working, this problem has arisen since using 9.3 and Plugin 7.2.0 I originally followed the Freenas team youtube video and have also followed yours Joshua.

I have tried it with Windows as the permission Type and also Unix each time fresh installs. I even went into change the sabnzbd.ini file to full access for everyone. Ive also tried changing my Jail folders to the same.

Lastly I have just installed the Plugin only from a fresh jail not changed anything, or added separate mount points, and still my folders will not change. The only change to folders that it will allow is "permissions for completed downloads". I cannot add a scripts folder or a watch folder.

below are the permissions as allocated after the plugin is installed.

drwxr-xr-x 5 media media 7 Dec 21 12:58 sabnzbd

root@sabnzbd_1:/var/db/sabnzbd # ls -al
total 36
drwxr-xr-x 5 media media 7 Dec 21 12:58 .
drwxr-xr-x 11 root wheel 13 Dec 21 12:58 ..
drwxr-xr-x 4 media media 4 Dec 21 13:01 Downloads
drwxr-xr-x 2 media media 10 Dec 21 13:09 admin
drwxr-xr-x 2 media media 4 Dec 21 12:58 logs
-rw------- 1 media media 4220 Dec 21 13:09 sabnzbd.ini
-rw-r--r-- 1 media media 4220 Dec 21 13:09 sabnzbd.ini.bak

Jails (my Dataset) is owned by nobody & nogroup according to the GUI
/mnt/Nas_Volume/Jails/.warden-template-pluginjail is owned by root & wheel and so is the jail /mnt/Nas_Volume/Jails/sabnzbd_1

I created a user id Media (does the capitalization make a difference) with ID 816 but have not allocated anything t this user - I had never created users before and had it all running once (however it never seemed to be stable..

I should add I am useless at permissions and FREEBSD/Linux
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
I now have this Same problem, but previously Had Sabnzbd working, this problem has arisen since using 9.3 and Plugin 7.2.0 I originally followed the Freenas team youtube video and have also followed yours Joshua.

I have tried it with Windows as the permission Type and also Unix each time fresh installs. I even went into change the sabnzbd.ini file to full access for everyone. Ive also tried changing my Jail folders to the same.

Lastly I have just installed the Plugin only from a fresh jail not changed anything, or added separate mount points, and still my folders will not change. The only change to folders that it will allow is "permissions for completed downloads". I cannot add a scripts folder or a watch folder.

below are the permissions as allocated after the plugin is installed.

drwxr-xr-x 5 media media 7 Dec 21 12:58 sabnzbd

root@sabnzbd_1:/var/db/sabnzbd # ls -al
total 36
drwxr-xr-x 5 media media 7 Dec 21 12:58 .
drwxr-xr-x 11 root wheel 13 Dec 21 12:58 ..
drwxr-xr-x 4 media media 4 Dec 21 13:01 Downloads
drwxr-xr-x 2 media media 10 Dec 21 13:09 admin
drwxr-xr-x 2 media media 4 Dec 21 12:58 logs
-rw------- 1 media media 4220 Dec 21 13:09 sabnzbd.ini
-rw-r--r-- 1 media media 4220 Dec 21 13:09 sabnzbd.ini.bak

Jails (my Dataset) is owned by nobody & nogroup according to the GUI
/mnt/Nas_Volume/Jails/.warden-template-pluginjail is owned by root & wheel and so is the jail /mnt/Nas_Volume/Jails/sabnzbd_1

I created a user id Media (does the capitalization make a difference) with ID 816 but have not allocated anything t this user - I had never created users before and had it all running once (however it never seemed to be stable..

I should add I am useless at permissions and FREEBSD/Linux
Don't change the permissions of the Jail folder/dataset. Only your own media folder you mount into the jail.

So, just to clarify, your issue is you cant change certain settings on sabnzbd?
 

Christopher Joyson

Contributor
Joined
May 22, 2014
Messages
105
Josua
This Time I have not changed any permissions in the Jail, not added any external storage mounts to the Jail and still cannot change the following:

Cannot move the Completed Download folder or even add a Watched folder or scripts folder in the default base folder.
This time I wanted to see what a blank Sabnzbd install could do.
other settings I am able to change, although I haven't tried to change every setting!

Oh and Ive deleted all other jails and will not add them till this one is sorted.
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
Josua
This Time I have not changed any permissions in the Jail, not added any external storage mounts to the Jail and still cannot change the following:

Cannot move the Completed Download folder or even add a Watched folder or scripts folder in the default base folder.
This time I wanted to see what a blank Sabnzbd install could do.
other settings I am able to change, although I haven't tried to change every setting!

Oh and Ive deleted all other jails and will not add them till this one is sorted.
hmm, just to confirm. you are on version 0.7.20?
if so, I don't know the cause of the issue =\
 

Christopher Joyson

Contributor
Joined
May 22, 2014
Messages
105
Joshua
Correct

FreeNAS-9.3-STABLE-201412200530
SABNZBD 0.7.20
 

Christopher Joyson

Contributor
Joined
May 22, 2014
Messages
105
Hi I've got sabnzbd to allow me to add the right folder path.
I added the media user (816) that didn't work then I changed the sabnzbd jail, all after a fresh jail install, to full access with media as the owner.
now however sabnzbd cannot create sub folders below are the permissions for my download folder now:

root@sabnzbd_1 :/media # ls -al
drwxrwxrwx 5 media media 5 Dec 21 22:26 .
drwxrwxrwx 18 media media 22 Dec 21 20:36 ..
drwxrwxr-x+ 2 nobody nogroup 2 Dec 16 11:54 Complete
drwxrwxr-x+ 2 nobody nogroup 2 Dec 22 01:52 NZB
drwxrwxr-x+ 2 nobody nogroup 7 Dec 12 12:23 scripts
root@sabnzbd_1:/media # getfacl Complete
# file: Complete
# owner: nobody
# group: nogroup
owner@:rwxpDdaARWcCos:fd----:allow
group@:rwxpDdaARWcCos:fd----:allow
everyone@:r-x---a-R-c---:fd----:allow
root@sabnzbd_1:/media #
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
Hi I've got sabnzbd to allow me to add the right folder path.
I added the media user (816) that didn't work then I changed the sabnzbd jail, all after a fresh jail install, to full access with media as the owner.
now however sabnzbd cannot create sub folders below are the permissions for my download folder now:

root@sabnzbd_1 :/media # ls -al
drwxrwxrwx 5 media media 5 Dec 21 22:26 .
drwxrwxrwx 18 media media 22 Dec 21 20:36 ..
drwxrwxr-x+ 2 nobody nogroup 2 Dec 16 11:54 Complete
drwxrwxr-x+ 2 nobody nogroup 2 Dec 22 01:52 NZB
drwxrwxr-x+ 2 nobody nogroup 7 Dec 12 12:23 scripts
root@sabnzbd_1:/media # getfacl Complete
# file: Complete
# owner: nobody
# group: nogroup
owner@:rwxpDdaARWcCos:fd----:allow
group@:rwxpDdaARWcCos:fd----:allow
everyone@:r-x---a-R-c---:fd----:allow
root@sabnzbd_1:/media #
you changed ownership/permissions of the jail dataset or a dataset you mounted into the jail?
Don't change it for the jail dataset, things will start breaking because these are mostly jail OS/ application files that need certain ownership/permissions.
Only ever change it for a dataset that you mount into the jail.


also, I don't think this should affect sabnzbd ability to save settings. so even with a new install of sabnzbd, no changes, it cant save certain settings?
permissions
 
Status
Not open for further replies.
Top