# NFS mounting causing gnome to fail

## kismet

I am a new user to Gentoo and have tried to find the answer to my question searching in the forums, but I haven't been able to so it's time to post my own.

I am having problems startting a gnome-session with any non-root users. This is most likely due to my NFS mounted /home not working properly. If I log into my machine without running gdm, or log into an xterm failsafe session (any user) I can see all the dot files and such in user directories in /home, however if I log into gnome as root (the only user it works for) I cannot see all the files on the mount. It can see some and not see others. It consistently can't or can see the same files, but there doesn't seem to be any scheme to it. I can create new directories on the client machine and new files and those can be seen on the server as well.

When I try to log into Gnome with a non-root user I get this error message:

 *Quote:*   

> 
> 
> Please contact your system administrator to resolve the following problem:
> 
> Could not lock the file "/home/<username>/.gconf-test-locking-file"; this indicates that there may be a problem with your operating system configuration. If you have an NFS-mounted home directory, either the client or the server may be set up incorrectly. See the rpc.statd and rpc.lockd documentation. A common cause of this error is tht the "nfslock" service has been disabled. The error was "No locks available" (errno = 37).
> ...

 

So this leads into my nfs configurations... I am mounting /home from a Redhat 8.0 box. On this machine I have correctly configured /etc/exports, run /etc/init.d/nfs and /etc/init.d/nfslock. This has been sufficient to mount to other redhat machines. However, my gentoo box cannot seem to mount correctly. I have set up /etc/fstab to mount with:

```

rivera:/home            /home           nfs             rw,rsize=8192,wsize=8192    0 0

```

As well I have done 

```
 emerge nfs-utils

/etc/init.d/nfs start

/etc/init.d/nfsmount start

rc-update add nfs default

rc-update add nfsmount default

```

I am pretty sure I don't need all these but I tried to run anything nfs. I cannot find any nfslock port or anything like that.

Also, here is rpcinfo -p <hostmachine>

 *Quote:*   

>    program vers proto   port
> 
>     100000    2   tcp    111  portmapper
> 
>     100000    2   udp    111  portmapper
> ...

 

And here it is for the gentoo client:

 *Quote:*   

>    program vers proto   port
> 
>     100000    2   tcp    111  portmapper
> 
>     100000    2   udp    111  portmapper
> ...

 

Now that my log windedness has subsided.. any suggestions would be very appriciated.  :Rolling Eyes: 

----------

## kerframil

I would recommend using these options for your nfs mount: "hard,intr,users".

Also, I had the same problem with Gnome on a client then realised that I hadn't started the /etc/init.d/nfs service on the client, which solved the problem. You need if for locking even through the actual client ability for NFS networking is built into the kernel. I'm running a Gentoo client off a Gentoo server exporting /home which is also running NIS. I don't recall having to fiddle with lock settings or anything, nor do I have /etc/init.d/nfsmount started on either machine. In fact my systems don't have a service called /etc/init.d/nfslock so I'm not sure what that's about. All works well.

----------

## kismet

It's been a while since this was posted and since I received a reply. I do want to thank you Kerframil, it was a good idea and it was something I hadn't done, but I am still having the exact same problem. It didn't change at all when I changed how it was mounting. I am running nfs on client and server.

I thought I'd post this reply because I see there are quite a few others with similar problems, but no one helps any of them. So, the more the merrier.

----------

## jalminger

I had the exact same problem and I added nolock to the options in fstab for the mount of /home which made it work.

/jonas

----------

## kpoman

 *jalminger wrote:*   

> I had the exact same problem and I added nolock to the options in fstab for the mount of /home which made it work.
> 
> /jonas

 

that worked perfecly for me (options rw,nolock)

----------

## dnix

thanks

now I can log everywhere!

there is a lot of people with this problem and this is a clear solution.

I'd also tried to put 

ORBIIOPIPv4=1

in /etc/orbitrc to allow multiple connection to the server.

bye,

Dnix

----------

## SavageMindz

Hi,

I was having the same problem but I think I have worked it out.

You can run the /etc/init.d/nfs service on all your machine but this leaves you running nfs servers on all your clients. Instead run the /etc/init.d/nfsmount on all the clients. This runs the statd process ( and also takes care of lockd for you) without running and nfs server on the client.

Hope this helps  :Wink: 

----------

## Sugarat

Hows this for resurrecting a post. 

I have this exact same problem and cannot seem to fix it!

I have now specified rw and nolock in /etc/fstab but it still doesnt work for me.. someone please help!

----------

