Hi! Got an issue I couldn’t figure out
When I use /etc/fstab to automount an SMB share using CIFS, I cannot unmount it without root privileges. If I mount it manually (as a non-privileged user), everything works just fine.
Also, an application I mount the share for (Pika Backup, based on borg) cannot access backups unless I unmount the share with root privileges and then mount it back manually.
A respective line in /etc/fstab is: //address/directory /mnt/backup cifs credentials=…,user,auto,iocharset=utf8 0 2
Highlighted user option to make it clear I didn’t forget it.
Any advice?
Ah. That’s right. You need to use the uid as the network share doesn’t have permissions the way a local partition would. Normally it’s unneeded, as the drive, folder and file permissions are set on the drive, and those are the ones that matter once it is mounted.
Note that the uid only sets access permissions. It does not actually mount the share as you, so you’ll still need to be root to unmount it, unless you change user to users.
Aha, caught that one, and indeed, you are right. Unmounts correctly now!