Mount NFS as remote user

2

I have debian as an NFS client. I would like to mount a remote NFS with a specific user permissions (to specify the remote user account)

How can I do that?

Himberjack

Posted 2010-03-16T13:39:36.923

Reputation: 121

Answers

2

NFS, while useful, is not generally great at dealing with user perms. In order to do this you have to do a few things:

  1. The UID of the files on the mount need to be the same as the user's UID on the local box
  2. If the user has local root you'll want to make sure root-squash is active on the NFS server. This ensures that access to files as the local root user is blocked.
  3. That said, if the user does have local root, it's pretty trivial for that user to create a local account with the same UID as the files he wants to get access to, and su to the new local user account, thus giving access to any file with the same UID as the newly created local user.

skarface

Posted 2010-03-16T13:39:36.923

Reputation: 1 088

-2

Under Ubuntu, a debian-based distribution, you should enter the command:

 sudo apt-get install nfs-common

You should then be able to connect and mount any available NFS-available directory.

jfmessier

Posted 2010-03-16T13:39:36.923

Reputation: 2 530

4This question neither addresses the specifics of connecting to an NFS server nor addressing the permissions issues in the question. – bobmagoo – 2012-08-27T18:57:51.277