-2

During the boot time I get this error message:

Failed to start NetworkManager-wait-online 

and immediately after the network shares fail to mount. But once the system is up, issuing mount -a mounts them fine. How can I make sure that network is completely started at boot time before /etc/fstab is executed?

#uname -a localhost.localdomain 4.15.15-200.fc26.x86_64 #1 SMP Mon Apr 2 16:25:08 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux 

@Patrick asked below for the fstab entry, which I think is not necessary as the stated purpose of NetworkManager-waitonline is to guarantee that network initialization is complete before fstab is processed.

2
  • 2
    please show the line from your fstab. Commented Apr 18, 2018 at 1:53
  • How's this relevant if mount -a works? Commented Apr 18, 2018 at 1:55

2 Answers 2

9

You need to add _netdev to your mount options in /etc/fstab.

//10.10.10.2/DRIVED /home/use0/DriveD cifs credentials=/etc/smbcredentials,iocharset=utf8,fsc,uid=use0,gid=use0,file_mode=0644,dir_mode=0777,_netdev 0 0 

For details, see man 8 mount, or this question. But basically it prevents the system from trying to mount the filesystem unless the network is available.

 

On another note, the timeout on NetworkManager-wait-online indicates you have another issue in that NetworkManager isn't starting up properly. I'd look into that as well. journalctl -u NetworkManager.service should be a good start.

5
  • Is this still required if NetworkManager is nixed and replaced with conventional networking? Commented Apr 18, 2018 at 15:14
  • Yes, although you're going to need to make sure you inform systemd properly when the network is online, etc, so that it knows how to order services. Commented Apr 18, 2018 at 16:53
  • Do you have any more background on this change, as I do not get it. Why all of a sudden the onus in on me to make things work, while in previous versions it all worked out of the box? It worked, but now it does not and I have to jump through the hoops to fix things just because of the version change. Kind of counter intuitive/productive. What is the benefit of making breaking changes to networking which need to be fixed at user level? Commented Apr 18, 2018 at 17:24
  • We cannot help on this (provide background as you request) because it's a home-brew implementation. NetworkManager is the standard networking implementation. If you want to not follow standards, then it becomes your problem. We might be able to answer very specific questions, but not an overarching "how do I get this whole thing to work". Commented Apr 18, 2018 at 18:23
  • What are you referring to as "home brew implementation"? I do not understand. And now that look at this more and more, this should not even matter due to NetworkManager-wait-online used. The stated purpose of that service is to wait until networking is all set up. So the question is not what switches I should add to fstab, but why NetworkManager-wait-online is failing. Commented Apr 18, 2018 at 18:34
0

Likely to Patrick's et al horror, the solution was to shut down NetworkManager (which I always did in the past as the monstrosity never worked) and start network.

After a couple reboots two things changed at boot time:

  1. Shares started mounting themselves w/o making any of the proposed changes to fstab
  2. NTP service is now able to sync time from our NTP server, which previously it could not.

So everything is back to normal after flipping the network service to On.

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.