Mount network drive - Folder is not writable by user

Hello

Been using DietPi on RPi4 for over an year with Sonarr, Radarr, Lidarr, Deluge and a directly connected USB drive, all great!

I’m having some problems trying to use an old Seagate Central NAS. I add the drive through DietPi-Drive Manager and the mount its visible and accessible by (for ex.) Sonarr, when I try to select it I get the error “Folder is not writable by user sonarr” (same for Radarr and Lidarr) but a blank sonarr_write_test.txt is created

Tried with a different NAS (WD My Clould EX2 Ultra) and everything works fine

Noticed the Seagate drive uses CIFS 1.0 and the WD CIFS 3.1.1, dont know if might be it and if/how get around it

//192.168.X.XXX/XXX /mnt/Seagate cifs username=XXX,password=XXX,iocharset=utf8,uid=dietpi,gid=dietpi,file_mode=0770,dir_mode=0770,vers=1.0,_netdev,nofail,noauto,x-systemd.automou$

Hi,

you could change mount options in /etc/fstab to user sonarr and / or file permission to 777. The following part to be changed:

uid=dietpi,gid=dietpi,file_mode=0770,dir_mode=0770

btw: if possible don’t use SMBv1 anymore :sunglasses:

Tried this variants, none worked:

uid=dietpi,gid=dietpi,file_mode=777,dir_mode=777
uid=sonarr,gid=dietpi,file_mode=777,dir_mode=777
uid=sonarr,gid=sonarr,file_mode=777,dir_mode=777



yeah, i know… that’s why i’m “retiring” this NAS to an “isolated” group.

stupid question but did you rebooted your DietPi device after changing the mount option?

well… i would swear i did…

uid=sonarr,gid=dietpi,file_mode=777,dir_mode=777

Did the trick with Sonarr

How can I make the same to Radarr and Lidarr?

you mounted your share with permission for user sonarr and group dietpi now

uid=sonarr,gid=dietpi

however you mounted the share with full r/w permission as well

file_mode=777,dir_mode=777

so it should work for everybody.

Anyway, you could add all users for Sonarr, Radarr, Lidarr and Deluge to dietpi group.

Excample for Sonarr user

usermod -a -G dietpi sonarr

Just do it with all the other users as well

usermod -a -G dietpi sonarr
usermod -a -G dietpi radarr

Doesn’t seem to work (I did reboot)

uid=radarr,gid=dietpi,file_mode=777,dir_mode=777

Replacing user with radarr makes radarr works but sonarr doesn’t work anymore

Can I check if the users are effectively added to dietpi group?

you could try to display all groups the user belongs to

groups <username>

not sure if this will have any side effects but you could try to change primary group as well

usermod -g groupname username

sonarr : sonarr dietpi media
radarr : radarr dietpi media



No good. Any other idea before I pickup the screwdriver?

can you try to make dietpi as primary group for user sonarr and radarr

usermod -g dietpi username

dietpi should now appear on first place if you check the user again

if this was working, change the mount back to uid=dietpi,gid=dietpi and reboot you system