1

I've created a folder /mnt/ramdisk. I've got the following line in /etc/fstab to create the ramdisk at startup and mount it to /mnt/ramdisk:

tmpfs      /mnt/ramdisk tmpfs     size=4096M,mode=0777,uid=998,gid=998 0    0

When the machine boots the ramdisk is successfully mounted and I have a systemd script that copies contents to the ramdisk. However, the program that's supposed to access the files on the ramdisk fails to launch because /etc/ramdisk permissions do not permit write access to the user/group that the program is launched with.

Despite specifying the mode, uid and gid in fstab as above, this is what's shown on startup:

drwxr-xr-x  6 samba samba   300 Mar  7 23:38 ramdisk

How is it uid and gid are assigned to samba and why are the permissions, uid and gid not being set according to that specified in /etc/fstab?

  • Can you add the output of grep 998 /etc/passwd? – chaos Mar 10 '15 at 6:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.