File Ownership problems when NFS Share/Mount a drive

Hi all,

I am new to solaris. I'm facing file ownership problems when NFS Share/Mount a drive.

Please read the scenario below for more details

I have two solaris boxes which have solaris9 installed on both.

I have NFS shared and mounted a file system as follows

Host1

Shared a folder /sharedFromHost1 from host1 to host2 with the following command in dfstab file

share -F nfs -o ro,rw=host2,root=host2 /sharedFromHost1

Host2

Created mount point /mountToShare in host2, then Mounted the shared drive from host1 with the following command

mount host1:/sharedFromHost1 /mountToShare

If I create any file under /sharedFromHost1 from host1, it's getting reflected in host2's /mountToShare directory. And the same is working fine when created a file from the otherside also.

But the problem is with the users and user ownership to the files created in the hosts.

We have a user/group 'user1/group1' created on both the hosts. So that we can change(su) to the user user1 and can create files. Then that file should be owned by user1(user)/user1(group).

The issue here is, as 'user1'

when we create a file in /sharedFromHost1 from host1, and if we see the same file in /mountToShare directory from host2, the ownership of the file is shown as 2001(user)/606(group) instead of user1(user)/user1(group)

Also when we create a file in /mountToShare from host2, and if we see the same file in /sharedFromHost1 directory from host1, the ownership of the file is shown as 103(user)/sssteam(group) instead of user1(user)/user1(group)

But strictly we want to see the user/group as user1/user1 for all the files created by user1.

Did anyone of you gone through similar kind of situation or anybody who knows the solution? It would be great if you can help me regarding this.

Please let me know if you need any more details about the scenario

Thanks in advance

[1974 byte] By [Neo369a] at [2007-11-27 2:18:02]
# 1

Since you have Solaris 9, you're limited to NFS2/NFS3. NFS2/3 does not handle usernames at all, only UIDs.

You must synchronize the UIDs for NFS users on the machines if you want the name mapping to be correct.

NFS 4 does this differently, passing usernames rather than UIDs. I believe that you need Solaris 10 before you can use NFS4.

--

Darren

Darren_Dunhama at 2007-7-12 2:17:07 > top of Java-index,Solaris Operating System,Solaris Essentials - General Technical Questions...