SABNZBD / Sickbeard Permissions Error on Synology NAS

Get help with all aspects of SABnzbd
Forum rules
Help us help you:
  • Are you using the latest stable version of SABnzbd? Downloads page.
  • Tell us what system you run SABnzbd on.
  • Adhere to the forum rules.
  • Do you experience problems during downloading?
    Check your connection in Status and Interface settings window.
    Use Test Server in Config > Servers.
    We will probably ask you to do a test using only basic settings.
  • Do you experience problems during repair or unpacking?
    Enable +Debug logging in the Status and Interface settings window and share the relevant parts of the log here using [ code ] sections.
Post Reply
Witchdoc
Newbie
Newbie
Posts: 3
Joined: March 20th, 2016, 6:15 am

SABNZBD / Sickbeard Permissions Error on Synology NAS

Post by Witchdoc »

Hello,

I am having a strange issue whereby files that are downloaded and then run through the Sickbeard Post Processing Scripts don't inherit the permissions that are set on my Synology.
I have narrowed this down to the Sickbeard post-processing script (that is executed from SABNZBD) - as using an ssh session logged in as root (which is what SABNZBD and Sickbeard are running as) - if I simply copy the file from the Download directory to the destination (/volume1/Media/TV/Current/<show>/<season>/file.ext) - the file inherits all the permissions no problem.

If I then delete the file, and execute a manual post processing from Sickbeard - the file ends up in the correct directory no problem (with correct naming etc), but only has explicit rights assigned for the admin user and is not inheriting the correct rights from the parent directory.

In the Sickbeard logs - I can see that it says "Setting permissions for <file> to 600 as parent directory has 700" - although I just want this to inherit the rights already on the parent folder - like what happens with the standard copy above. The line before in the logs shows it copies the file, so it would be good to leave out the permissions step to see if that will leave it with the inherited rights.

Does anyone know where this script is located or know how to fix this issue?

Thanks!
User avatar
shypike
Administrator
Administrator
Posts: 19773
Joined: January 18th, 2008, 12:49 pm

Re: SABNZBD / Sickbeard Permissions Error on Synology NAS

Post by shypike »

All of SABnzbd's scripts are in its own scripts folder.
So start from there.
BTW in Unix you normally don't inherit permissions, they need to be set explicitly (or through umask).
It can even be necessary to set ownership.
Witchdoc
Newbie
Newbie
Posts: 3
Joined: March 20th, 2016, 6:15 am

Re: SABNZBD / Sickbeard Permissions Error on Synology NAS

Post by Witchdoc »

The funny thing is this was all working fine before - but 2 disks in my Synology died and I had to rebuild from scratch.
At the moment I have to manually go into Synology and click on the file and chose to inherit permissions then all is good - but I have to do it for every new file it downloads which is unworkable.

The sabtoSickbeard.py script I have checked - that looks fine.

Any other ideas?
Witchdoc
Newbie
Newbie
Posts: 3
Joined: March 20th, 2016, 6:15 am

Re: SABNZBD / Sickbeard Permissions Error on Synology NAS

Post by Witchdoc »

Ok - hacked around a bit and modified the helpers.py script to comment out the line that sets the permissions after the file copies.

This interestingly puts three explicit permissions on the file after the post processing. The first two allow admin and administrators all rights except take ownership, set permissions and delete, and the third allows Everyone Read access.
This is still not what I am after - but will allow my read only user access to play the file (as they are a standard user on the Synology box).

Still require assistance as I would love to have this sorted....
User avatar
shypike
Administrator
Administrator
Posts: 19773
Joined: January 18th, 2008, 12:49 pm

Re: SABNZBD / Sickbeard Permissions Error on Synology NAS

Post by shypike »

Please report this also on the SickBeard forum, because it's their issue.
Post Reply