I am on TomatoUSB, and using the feature to have a NAS.

The only way I can write to the Samba share is if I force root:

[global]
interfaces = 127.0.0.1, 192.168.1.1/24
bind interfaces only = no
workgroup = WORKGROUP
netbios name = TOMATO
security = share
wins support = yes
name resolve order = wins lmhosts hosts bcast
guest account = nobody

[Public]
path = /mnt/sda2
read only = no
public = yes
only guest = yes
guest ok = yes
browseable = yes
comment = Network share
force user = root
writeable = yes

I dont really like the idea having to use root to allow write access to my share. I have a samba account created already named nobody to allow access to the share. However every time I try to write I get access denied error.

fstab: /dev/sda2 /mnt/sda2 vfat defaults 0 0

Further more every time I try to chmod 777 /tmp/mnt/sda2 the permissions are not changed, and no error is produced. They stay 755.

drwxr-xr-x    2 root     root          4096 Jun  4 01:49 sda2

Basically; how can I give the user nobody write permissions to my mount?

dev name: /dev/sda2
dev mount: /tmp/mnt/sda2
link|improve this question
feedback

1 Answer

The FAT filesystem does not support Unix permissions, so the ones specified in fstab apply to all files.

Add the options fmask=0111,dmask=0 to give a+rw to files and a+rwx to directories.

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.