Operating System - HP-UX
1844754 Members
1841 Online
110233 Solutions
New Discussion

NFS user and default directory (hp-ux 11i v2)

 
sheevm
Regular Advisor

NFS user and default directory (hp-ux 11i v2)

Hi,

I have this user called tammis logging into server A via SFTP and transferring file to a directory in the SERVER B.

SERVER B ---NFS server /homesan is exported
SERVER A----NFS CLIENT NFS MOUNT of /homesan

User tammis will be logging on to SERVER A via sftp. I want to make the tammis default home directory to NFS mount directory /homesan
when he loggs in server A.

Does this work? Do I have to have users tanmmis on both SERVER A and SERVER B?

What are other requirements for this user in order to access remote NFS filesystem?

Thanks
Raji
be good and do good
4 REPLIES 4
Peter Godron
Honored Contributor

Re: NFS user and default directory (hp-ux 11i v2)

Raji,
if I understand you correctly I would advise against using a mounted NFS as home directory location. What would you expect to happen if server B is down or the network not working?

Server A and Server B are seperate machines and therefore have seperate /etc/passwd. The userid from server A does not need to exist on Server B, but a user with same uid and gid will become owner of data.

The only requirement for this user would be that the mount point has the correct access rights set up.
Peter Nikitka
Honored Contributor

Re: NFS user and default directory (hp-ux 11i v2)

Hi,

the sending of files via sftp is a priori independent from the fact that the home directory is NFS mounted - but only when transferring to outside the NFS-mountmoint.
NB:

1) If it is the identical directory on the NFS-client mounted from the NFS-server: why transfer the file(s) through sftp - they will be accessible already.

2) If no NIS is setup or the NFS-client and NFS-server are in different NIS-domains, the access rights - as Peter G. wrote - depend on the (local) entries in the /etc/passwd's

3) There will be only one file of these for the user:
~/.ssh/authorized_keys
~/.ssh/id_dsa* (or whatever auth-type you chose)

But that will not cause problems - if your (e.g.) id_dsa.pub data is found in the authorized_keys, an ssh/sftp access will be checked against them regardless you connect on the NFS-client or -server.

mfG Peter




The Universe is a pretty big place, it's bigger than anything anyone has ever dreamed of before. So if it's just us, seems like an awful waste of space, right? Jodie Foster in "Contact"
sheevm
Regular Advisor

Re: NFS user and default directory (hp-ux 11i v2)

Hi,

I think my question is nt clear.

The user "tammis" is connecting from outside to server A (nfs client)via SFTP to drop the file. This file should be dropped at a NFS mounted (nfs server SERVER A) directory.

How do I make this user when he loggs in to the SERVER A (nfs client machine) to go to nfs mount point to drop the file.

What type of access he needs in the NFS server?
Does this user needs to exist in the NFS SERVER and have permission to that directory?

In the sftp script is there a way cd to NFS MOUNT POINT before he drops the file.

Thanks
Rajim

be good and do good
Peter Nikitka
Honored Contributor

Re: NFS user and default directory (hp-ux 11i v2)

Hi,

| I think my question is nt clear.


| The user "tammis" is connecting from
| outside to server A (nfs client)via SFTP to | drop the file. This file
| should be dropped at a NFS mounted
| (nfs server SERVER A) directory.

What is outside? I think you mean outside your domain, so sftp is the only authorized connection between 'outside' and SERVER A + B.

BTW: I do not see SERVER B in your text now.
I guess (am I right?) that the sftp goes to SERVER B which has - as a NFS client - connection to SERVER A. Please clarify that!

| How do I make this user when he loggs in to the SERVER A
| (nfs client machine) to go to nfs mount point
| to drop the file.

There is a command 'cd ' in ftp, which changes the working directory of the daemon - it should be available in sftp, too.

| What type of access he needs in the NFS server?

You need write access to drop a file, of course.

| Does this user needs to exist in the NFS
| SERVER and have permission to that directory?

That has been answered previously.

| In the sftp script is there a way cd
| to NFS MOUNT POINT before he drops the file.

cd-command of sftp

mfG Peter
The Universe is a pretty big place, it's bigger than anything anyone has ever dreamed of before. So if it's just us, seems like an awful waste of space, right? Jodie Foster in "Contact"