View previous topic :: View next topic |
Author |
Message |
Conzar Tux's lil' helper
Joined: 04 Feb 2004 Posts: 89
|
Posted: Mon Jun 13, 2005 7:14 pm Post subject: mounting nfs with specific user id |
|
|
Is there anyway to mount a nfs partition with a specific userid and password?
If not, then can you use a local userid (for the client) and use NIS for just the NFS mounts?
Thanks |
|
Back to top |
|
|
alechiko Guru
Joined: 01 Feb 2004 Posts: 465 Location: Inside piano, do not disturb.
|
Posted: Mon Jun 13, 2005 7:32 pm Post subject: |
|
|
I mount a networked storage device with these parameters in my /etc/fstab
Code: | //Linkstation/share /mnt/linkstation smbfs password=root,user,rw,auto,noatime,umask=000,nls=utf8 0 0 |
Not sure if that helps? _________________ None |
|
Back to top |
|
|
beandog Bodhisattva
Joined: 04 May 2003 Posts: 2072 Location: /usa/utah
|
Posted: Mon Jun 13, 2005 7:35 pm Post subject: |
|
|
If you mean mounting an NFS share and chowing the files to uid=xxx and gid=yyy then yes, you can.
man exports will explain it much better than me. _________________ If it ain't broke, tweak it. dvds | blurays | blog | wiki |
|
Back to top |
|
|
Conzar Tux's lil' helper
Joined: 04 Feb 2004 Posts: 89
|
Posted: Mon Jun 13, 2005 7:40 pm Post subject: |
|
|
Sort of ---- basically there is a server with a user account that has specific permissions on the nfs. I have another machine with a different user id. What I want to do is to be able to mount the nfs partition with my local account but be able to have the permissions of my "network" account.
I was told that I can force both my local user id and my networked user id to match by chaning it in the password file (either on the server or local box). What do you think of this solution? Is there a better way of doing it? |
|
Back to top |
|
|
Conzar Tux's lil' helper
Joined: 04 Feb 2004 Posts: 89
|
Posted: Mon Jun 13, 2005 8:20 pm Post subject: |
|
|
It looks like the samba stuff you posted should work; however, is there another way to provided the password so its not clear text? |
|
Back to top |
|
|
Conzar Tux's lil' helper
Joined: 04 Feb 2004 Posts: 89
|
Posted: Tue Jun 14, 2005 12:42 pm Post subject: |
|
|
OK, I tried using samba and this is the error that I am getting.
sudo mount -t smbfs -o username=xxxx,password=xxxx //x.x.x.x:/shared /mnt/shared
Password:
27289: Connection to 192.168.2.126: failed
any thoughts? |
|
Back to top |
|
|
Conzar Tux's lil' helper
Joined: 04 Feb 2004 Posts: 89
|
Posted: Tue Jun 14, 2005 6:11 pm Post subject: |
|
|
OK, I've got it all worked out.
The syntax for nfs is differnt then smba so its //server_name/shared_dir
so in the fstab file you can do this
//server_name/shared /mnt/shared smbfs username=xxx,rw,defaults,... 0 0
If you don't include a password, then when you go to mount it, the server will ask.
Also, having sudo is very helpfull so you don't have to switch to root to mount it.
Thanks for the help! |
|
Back to top |
|
|
|