Sonarr version (exact version): 2.0.0.5252
Mono version (if Sonarr is not running on Windows): 4.2.1
OS: Linux nvrlnd 4.14.52 #1 SMP Thu Oct 11 15:51:48 CST 2018 aarch64 aarch64 aarch64 GNU/Linux (Ubuntu 16.04.5 LTS)
Debug logs: https://pastebin.com/yhmZyfDG
Description of issue:
When trying to update the root folder path in Series editor to “/home/qbt/Sonarr/”, I get “Folder is not writable by user qbt” error. But that folder IS writable by that user.
Sonarr is running as user “qbt”
qbt@nvrlnd:~$ ps ugxaw | grep mono
qbt 1661 1.6 28.4 1834176 289300 ? Ssl Jan06 14:34 /usr/bin/mono /opt/NzbDrone/NzbDrone.exe -nobrowser -data=/home/qbt/.config/NzbDrone
As that user I can change directory to that folder, AND create files to my hearts content:
qbt@nvrlnd:~$ cd /home/qbt/Sonarr/
qbt@nvrlnd:~/Sonarr$ ls -laus
total 0
0 drwxrwxr-x 2 qnap users 0 Jan 7 09:16 .
0 drwxrwxr-x 2 qnap users 0 Jan 7 08:43 …
0 drwxrwxr-x 2 qnap users 0 Jan 7 09:16 .RecycleBin
qbt@nvrlnd:~/Sonarr$ touch sonarr_write_test.txt
qbt@nvrlnd:~/Sonarr$ ls -laus
total 0
0 drwxrwxr-x 2 qnap users 0 Jan 7 09:16 .
0 drwxrwxr-x 2 qnap users 0 Jan 7 08:43 …
0 drwxrwxr-x 2 qnap users 0 Jan 7 09:16 .RecycleBin
0 -rwxrwxr-x 1 qnap users 0 Jan 7 09:48 sonarr_write_test.txt
qbt@nvrlnd:~/Sonarr$ rm sonarr_write_test.txt
qbt@nvrlnd:~/Sonarr$ ls -laus
total 0
0 drwxrwxr-x 2 qnap users 0 Jan 7 09:48 .
0 drwxrwxr-x 2 qnap users 0 Jan 7 08:43 …
0 drwxrwxr-x 2 qnap users 0 Jan 7 09:16 .RecycleBin
You can see in the trace log the error.
Question: why does the trace log also display : Access to the path “/home/(removed)/Sonarr/sonarr_write_test.txt” is denied. "
What is “(removed)”?? I didn’t put that there. Sonarr did.
/home/qnap/Sonarr is a symlink to a cifs mount at /mnt/smb/qnap/Video/Sonarr. I’ve also tried the full path to the mount point (/mnt/smb/qnap/Video/Sonarr) and I get the same “Folder is not writeable” error. (Trace log for full path is here: https://pastebin.com/bf2BGMA5)
Again, the user the service is running as has full access to the path:
qbt@nvrlnd:~$ cd /mnt/smb/qnap/Video/Sonarr
qbt@nvrlnd:/mnt/smb/qnap/Video/Sonarr$ ls -laus
total 0
0 drwxrwxr-x 2 qnap users 0 Jan 7 09:48 .
0 drwxrwxr-x 2 qnap users 0 Jan 7 08:43 …
0 drwxrwxr-x 2 qnap users 0 Jan 7 09:16 .RecycleBin
qbt@nvrlnd:/mnt/smb/qnap/Video/Sonarr$ touch sonarr_write_test.txt
qbt@nvrlnd:/mnt/smb/qnap/Video/Sonarr$ ls -laus
total 0
0 drwxrwxr-x 2 qnap users 0 Jan 7 09:48 .
0 drwxrwxr-x 2 qnap users 0 Jan 7 08:43 …
0 drwxrwxr-x 2 qnap users 0 Jan 7 09:16 .RecycleBin
0 -rwxrwxr-x 1 qnap users 0 Jan 7 09:59 sonarr_write_test.txt
qbt@nvrlnd:/mnt/smb/qnap/Video/Sonarr$ rm sonarr_write_test.txt
qbt@nvrlnd:/mnt/smb/qnap/Video/Sonarr$ ls -laus
total 0
0 drwxrwxr-x 2 qnap users 0 Jan 7 10:00 .
0 drwxrwxr-x 2 qnap users 0 Jan 7 08:43 …
0 drwxrwxr-x 2 qnap users 0 Jan 7 09:16 .RecycleBin
Why does sonarr think it does not have write access to the folder, when it clearly does? Any other process running at “qbt” can access that share without any issue. This tells me there is no issue with share permissions. It seems clearly a sonarr thing.