Hello, please figure out how to share the folder to only special user? For example I have two computers host1 with users: user1, user2, user3 and host2 with same users: user1, user2, user3, how to share “test” user2 folder form host1 to only user2 from host2 ?
My system is openSuse 11.1. There is all I’ve understood:
host1
[test]
inherit acls = Yes
path = /home/user2/test (drwxr-xr-x)
read only = No
guest ok = Yes
read list = user2
valid users = user2
admin users = user2
host2
mount –t cifs //host1/test /home/user2/test
It works but either user2 from host2 can’t write to «test» share on host1 (drwxr-xr-x) OR all can write in this share (drwxrwxrwx).
But I do not use Windows. I have a cluster of two nodes under openSUSE. I need common user directory for both nodes. For example when I log in through ssh to one of this nodes as user1, I should have same home directory as if I do it with same user1 to another node.
As I say before I’v done it but I stuck with the permission issue.
I use samba only because I have no experience with NSF.
Ok, I start an NFS Server on the node1 and set for export the user home directory: /home/user1 (drwxrwxr-x)
Host Wild Card: * rw, root_squash,sync, no_subtree_check
On node2 I successfully mount this directory to the home directory of identical user:
mount -t nfs node1:/home/user1 /home/user1/test
But again I cant write to this directory! What’s wrong?
I’ve resolved my infantile problem!
Yes I’ve checked user ID on both nodes, it’s not the case. My problem was that i was trying to write as root user! When I do it as user1 shared folder become writeble! Funy, but root user is not such powerful as I thought
djurin wrote:
> I’ve resolved my infantile problem!
> Yes I’ve checked user ID on both nodes, it’s not the case. My problem
> was that i was trying to write as root user! When I do it as user1
> shared folder become writeble! Funy, but root user is not such powerful
> as I thought
>
>
let me guess that you have a lot of experience on another operating
system, and not lot on Linux…and, suggest you try to believe this:
the more experience you have on another operating system the harder it
is to come to grips with the “Linux way”…and the more often you
try to use your experience on another system the harder you are gonna
find it to proceed smoothly and happily on Linux…
with that in mind, and hoping to be helpful i offer for your
consideration:
don’t log into KDE, Gnome or any other *nix desktop environment as
root…not even once, because as far as i can tell there is always
a better, safer, more secure and less destructive way to “become root”
while logged in as a user…
now i know there is a popular notion: it is my machine and i will use
it as i wish…to which i say, more power to you…do administrator
duties logged into the other system’s desktop as administrator,
ok…but not here, please read more here:
I know a little about root user paradigm on *nix systems. My idea was that with root you always have less restrictions, less settings should adjust correctly. So, in this case, I use root to simplify my problem only, as a first step. Nevertheless, thanks for post and links!