Bug 733031

Summary: nfs service blocks boot when no network is present (even when no nfs mounts are present)
Product: [openSUSE] openSUSE 12.1 Reporter: Forgotten User 6pyoK8uj9i <forgotten_6pyoK8uj9i>
Component: BasesystemAssignee: Frederic Crozat <fcrozat>
Status: RESOLVED FIXED QA Contact: E-mail List <qa-bugs>
Severity: Critical    
Priority: P5 - None CC: syntron
Version: Final   
Target Milestone: ---   
Hardware: x86-64   
OS: All   
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---

Description Forgotten User 6pyoK8uj9i 2011-11-28 11:28:55 UTC
User-Agent:       Mozilla/5.0 (X11; Linux x86_64; rv:7.0) Gecko/20100101 Firefox/7.0

I'm using autofs to mount nfs directories.

The issue is that if I configure the nfs service to start automatically (so that the nfs directories will mount correctly), the machine won't boot when not connected to network.

When connected to network, the machine will boot just fine.

Reproducible: Always

Steps to Reproduce:
1. turn nfs service on
2. disconnect / turn of network
3. reboot
Actual Results:  
Machine doesn't boot.

Expected Results:  
Machine should boot correctly.
Comment 1 Frederic Crozat 2011-11-29 13:36:18 UTC
do you use NetworkManager ? there is a bug causing "infinite" wait at startup when network is not connected.
Comment 2 Forgotten User 6pyoK8uj9i 2011-11-29 14:18:13 UTC
(In reply to comment #1)
> do you use NetworkManager ? there is a bug causing "infinite" wait at startup
> when network is not connected.

Yes, this is obviously the issue. NFS service doesn't take into account the fact, that when using NetworkManager, the network will start up later. But I think that you can simulate this even without NetworkManager (I will try and report back).
Comment 3 Frederic Crozat 2011-11-29 14:33:30 UTC
please try to change in  /etc/sysconfig/network/config NM_ONLINE_TIMEOUT to 1 (instead of 0), it should fix the timeout, until it is fixed by a ongoing maintenance package for NetworkManager.
Comment 4 Matthias Pfafferodt 2011-12-04 13:00:21 UTC
> please try to change in  /etc/sysconfig/network/config NM_ONLINE_TIMEOUT to 1
> (instead of 0), it should fix the timeout, until it is fixed by a ongoing
> maintenance package for NetworkManager.
I can confirm that this fixes the issue. I did try different combinations of the boot process and network manager setup to get my laptop to boot if there is no network cable connected.

This not only happens with systemd but also using system v as init process. In the later case the laptop boots but the network is missing completely (it is not started at all). I do start it manually but at shutdown it does not finish the process (one time I got an error message in the nfs boot script line 271 - integer expression expected).

Is were a way to save/log/debug the boot process with systemd? Something like /var/log/boot.msg?
Comment 5 Matthias Pfafferodt 2011-12-04 13:17:56 UTC
I forgot to add that I do not have any nfs shares defined (no autofs, no such file systems in fstab). nfs is only started to be able to manually mount nfs shares if needed.
Comment 6 Frederic Crozat 2011-12-05 14:05:52 UTC
everything should be available in /var/log/messages (if you use systemd.log_target=syslog )
Comment 7 Frederic Crozat 2011-12-20 16:20:53 UTC
Network manager fixes was released (you can set it back to 0).