seanmckinney Posted June 3, 2008 Report Share Posted June 3, 2008 Just curious really as I can alway su to root and umount it. fstab contains the line //Mk4/250G /home/sean/samba_mounts/250G smbfs noauto,user It may be primitive but it works allowing me, as a user, to mount this but, as the same user, I cant umount it, I am just curious as to why I cant umount it? Thanks. Quote Link to comment Share on other sites More sharing options...
ianw1974 Posted June 4, 2008 Report Share Posted June 4, 2008 You can try "users" as well and see if it makes a difference. Quote Link to comment Share on other sites More sharing options...
seanmckinney Posted June 4, 2008 Author Report Share Posted June 4, 2008 You can try "users" as well and see if it makes a difference. Ahhh would this be the explanation http://unixhelp.ed.ac.uk/CGI/man-cgi?mount+8. It worked, thanks, I copied "user" from the settings made 'by install' for other devices. Quote Link to comment Share on other sites More sharing options...
ianw1974 Posted June 4, 2008 Report Share Posted June 4, 2008 Aye :) From the link: For more details, see fstab(5). Only the user that mounted a filesystem can unmount it again. If any user should be able to unmount, then use users instead of user in the fstab line. The owner option is similar to the user option, with the restriction that the user must be the owner of the special file. This may be useful e.g. for /dev/fd if a login script makes the console user owner of this device. The group option is similar, with the restriction that the user must be member of the group of the special file. so in essence, if you put users instead of user, you can then unmount it regardless of the user. If you put user, then only the user that mounted it can unmount it, in this instance, only root. If you put a group, then of course, you just need to add yourself to the group, and then you can unmount it. This is good, since you can have multiple users on the system, one can unmount it, but the other cannot unless they are a member of the group. If you are the only user, then putting users is enough to fix this problem as you've just done ;) Quote Link to comment Share on other sites More sharing options...
scarecrow Posted June 4, 2008 Report Share Posted June 4, 2008 (edited) Either use cifs instead of smbfs (IMHO a better solution/performer), or tell samba mount to run suid root (it's not such a big security risk): # chmod u+s /usr/bin/smbmnt # chmod u+s /usr/bin/smbumount Also, get sure that the mountpoint ( /home/sean/samba_mounts/250G ) permissions aren't borked, and user "sean" has at least full read/write access, if not full ownership. Edited June 4, 2008 by scarecrow Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.