owner permission

Sick Beard is a PVR for newsgroup users (with limited torrent support). It watches for new episodes of your favorite shows and when they are posted it downloads them, sorts and renames them, and optionally generates metadata for them. It currently supports NZBs.org, NZBMatrix, NZBs'R'Us, Newzbin, Womble's Index, NZB.su, TVTorrents and EZRSS and retrieves show information from theTVDB.com and TVRage.com.
Post Reply
igracgq
Posts: 34
youtube meble na wymiar Warszawa
Joined: Sun Nov 17, 2013 4:57 am

owner permission

Post by igracgq »

I use sickbeard with sabnzbd and for some reason ever time the sabtosickbard.py script processes the download, it defaults to root owner and then my plex server can't pick it up when it scan the folder. How do i have the owner be admin user by default instead or root?

thanks
AS-602 with 3GB ram, 4TB WD Red

Qnap TS-119, DD-WRT Linksys 310n, WDlxTV player, RasperryPi OpenELEC
User avatar
clinton.hall
Posts: 845
Joined: Thu May 09, 2013 7:01 pm
Location: New Zealand
Contact:

Re: owner permission

Post by clinton.hall »

Have you updated to the latest sabnzbd and SickBeard in AppCentral. I recently changed this so that the services run as admin, not root. Therefore any postprocessing should now be running as admin.

For any TV folders that are already created as root owner (previous version of SickBeard) you will need to change these to admin ownership. I.e if your media is at /volume1/Public/TV you will need to log in as root via ssh and issue

Code: Select all

chown -R admin /volume1/Public/TV
AS-604T
3 x ST4000DM0000 (Seagate 4TB) in Raid5
2 GB RAM expansion
AS-302T

Apps (user)
NZBGet - CouchPotato - SickBeard - Git - Python

Apps (maintainer):
NZBGet - BitTorrent Sync - Mylar - LazyLibrarian - Gamez
-Maintenance of Apps acquired from JohhnyFive since ADM2.0:
SABnzbd - CouchPotato - SickBeard - HeadPhones - Subsonic

About Me: http://fockwulf.wix.com/index
User avatar
JohnnyFive
Posts: 37
Joined: Wed Dec 26, 2012 3:27 am

Re: owner permission

Post by JohnnyFive »

Clinton, I hope you are aware that if Sickbeard updates and restarts itself. it will change it's PID. This will break the way the start-stop-daemon works and stops the proces...
No Disassemble! Johnny Five Alive!
User avatar
clinton.hall
Posts: 845
Joined: Thu May 09, 2013 7:01 pm
Location: New Zealand
Contact:

Re: owner permission

Post by clinton.hall »

Hi JohnnyFive,

I use the start-stop-daemon to launch the process, but the stop function still uses your original code, so this should still try and shutdown via the pid and then do a force kill all if that doesn't work.

And SickBeard doesn't update.... It has been so long since that happened :P
AS-604T
3 x ST4000DM0000 (Seagate 4TB) in Raid5
2 GB RAM expansion
AS-302T

Apps (user)
NZBGet - CouchPotato - SickBeard - Git - Python

Apps (maintainer):
NZBGet - BitTorrent Sync - Mylar - LazyLibrarian - Gamez
-Maintenance of Apps acquired from JohhnyFive since ADM2.0:
SABnzbd - CouchPotato - SickBeard - HeadPhones - Subsonic

About Me: http://fockwulf.wix.com/index
User avatar
JohnnyFive
Posts: 37
Joined: Wed Dec 26, 2012 3:27 am

Re: owner permission

Post by JohnnyFive »

i don't get it? pid from the start stop deamon differs from the pid of the app itself.

will download you latest package and see what you've been up to ;)

same issue with couch by the way. that is why i eventually steared away from the start-stop-deamons. kept it as simple as possible
No Disassemble! Johnny Five Alive!
User avatar
clinton.hall
Posts: 845
Joined: Thu May 09, 2013 7:01 pm
Location: New Zealand
Contact:

Re: owner permission

Post by clinton.hall »

Ah... Well that is interesting.

I thought the pid was the dame for both.... In any case, what I do is use the start-stop-daemon simply so I can launch the process as admin, not root (you can also change the RUNAS if you want). But then the actual starting of SB and CP etc will overwrite the pid file with their own pid anyway...

If needed I could always use a separate pid file for the start-stop-daemon and the starting of the actual service.

So far this appears to have worked fine with CouchPotato (has updated many times).

The key driver behind all of this is that any files/folders created by these apps couldn't be deleted/modified via the web file browser since the owner was root and web file browser accesses as admin.
AS-604T
3 x ST4000DM0000 (Seagate 4TB) in Raid5
2 GB RAM expansion
AS-302T

Apps (user)
NZBGet - CouchPotato - SickBeard - Git - Python

Apps (maintainer):
NZBGet - BitTorrent Sync - Mylar - LazyLibrarian - Gamez
-Maintenance of Apps acquired from JohhnyFive since ADM2.0:
SABnzbd - CouchPotato - SickBeard - HeadPhones - Subsonic

About Me: http://fockwulf.wix.com/index
Post Reply

Return to “SickBeard”