Folder is not writable by user nzbdrone


#1

Sonarr version (exact version): 2.0.0.5252
Mono version (if Sonarr is not running on Windows): 4.6.2
OS: Ubuntu 18.04.1 LTS
Debug logs: https://pastebin.com/Ph4RPULz
Description of issue: I apologise for the n00b question. I have searched, but have found nothing that appeared to help.

I have a QNAP TS-410 NAS on my network, running QTS 4.2.6 (2018/08/29), with one of the shares being //192.168.20.18/NASTV which is where I’m moving all my TV shows to from the Windows box that was previously doing all this.

I have been using Sonarr for quite some time without issue on one of my Windows 10 PCs, but I now want to retire that machine from that duty and use the Ubuntu box instead.

When I attempt to do Series - > Add Series -> Import Existing Series On Disk -> and enter /share/NASTV (which is the mountpoint set in /etc/fstab, and all the existing directories show in the list), when I attempt to select it, I get the error: Folder is not writable by user nzbdrone

I’m unsure how to fix this. I’ve tried adding a user nzbdrone on the NAS and giving it full read and write permissions for that folder, according to the NAS permissions all users, including guest have full read/write access to that folder.

Here’s the relevant section of my /etc/fstab:
//192.168.20.18/TV /share/NASTV cifs defaults,rw,credentials=/etc/nas-credentials

and in /etc/nas-credentials:
username=plex
password=********** (not putting the real password here)

I have tried using nzbdrone as the username in /etc/nas-credentials and that didn’t change anything.

Any help would be very much appreciated, please and thank you.


#2

I attempted to follow the troubleshooting steps in this topic: Can't Add Series, Folder is not writable by user nzbdrone

specifically the steps written by @gtwy

Go into the terminal and run these commands to become user ‘nzbdrone’

sudo -i su - nzbdrone

You will now be nzbdrone. Try to browse

cd /media/plex/Media/TV\ Shows/

Try to write a file

touch test

Somewhere along the way you are going to get an error here, let me know at which point you cannot proceed further.

And here’s the terminal output:

troy@Mini-PC:/media/NASTV$ sudo -i su - nzbdrone
$ cd /share/NASTV
$ touch test
touch: cannot touch ‘test’: Permission denied
$


#3

An example first;

image

The above is one of the files that’s shown when I do a ls -al in a folder I use on a machine of mine. The first set of letters are the permissions in a set of 3 groups of RWX for User, Group and Other, respectively. Then you have the file count, owner name, owner group, filesize (in blocks), date&time, and filename at the end.

Which user and group are owner of the files in your /share/NASTV tree?

Because your nzbdrone must have the right to write to this directory either by

  1. Being the owner of the directory
  2. Being a member in the owner group of the directory
  3. “All” (others) must have a right to write to the directory.

If you do a ls -ald /share/NASTV you should get a line similar to the one above showing you the permissions and ownership of your share.


#4

troy@Mini-PC:~$ ls -ald /share/NASTV
drwxr-xr-x 2 root root 0 Nov 6 13:31 /share/NASTV


#5

And that’s the same for most/all of the files in the share?

Can you reach the share & browse it from another computer?


#6

Yes, as far as I can tell, it’s the same for all files in the share and yes, I can reach the share and browse it from other computers, even write to it from other computers no problem (I currently have one of my Windows 10 machines moving files to it now, and it isn’t even logged in with a username/password to the NAS).


#7

I guess it’s a NAS thing then since (as you said) most/all of the files in that tree are owned by root and only writable by root. Not sure what the “right” way to go about making sure sonarr would be allowed to write there as well is.


#8

Yeah, it’s strange. Oh well, thanks anyway, I guess the next step is to find a forum for the QNAP devices and ask there if anyone has any suggestions?


#9

I’m sure others here would have to have an idea, I’m just running a plain vanilla linux server so to me it just looks like your setup shouldn’t work :smiley: Hopefully somebody else will have a better idea of what you’re running and why it isn’t behaving like expected.