Disable “Waiting for network configuration” messages on Ubuntu boot

I was just creating a custom live CD for Ubuntu 12.04 and was having a problem with the boot process hanging for several minutes while waiting for the network to be configured. I was trying to see if I could fix it but I have no idea why it is happening for now. I found a bug logged on LaunchPad here https://bugs.launchpad.net/ubuntu/+source/dbus/+bug/811441/comments/24 that describes a workaround for oneric (11.10) but this fix/workaround is there by default in precise so obviously it didn’t fix my problem.

I didn’t really need networking setup at all and just wanted to skip waiting for the network to be configured. In order to do this you just need to edit the file /etc/init/failsafe.conf. In that file is where it sleeps for several minutes waiting for the network to come up. All I did was:

sudo vim /etc/init/failsafe.conf

I changed the first sleep command to

sleep 5

and then commented out the following lines:

$PLYMOUTH message --text="Waiting for network configuration..." || :
sleep 40
 
$PLYMOUTH message --text="Waiting up to 60 more seconds for network configuration..." || :
sleep 59

Just place a ‘#’ character at the beginning of each of those lines. Now it will just wait 5 seconds and then continue on.

To my surprise, the network was actually working just fine even though the script thinks it is not.

Just a note, do NOT remove the failsafe.conf file, otherwise it will hang the boot process indefinitely waiting for the network to be “configured.”

16 Comments

  1. thx thx thx!! :)

  2. This does work to make it faster, but have you had any luck actually finding the root cause of the problem?

  3. Thanks for this information. It really works
    But actually why does boot waits?

    For me, this wait situation only happens when I change interface configuration file. (it’s network configuration)

    So it might be related, thought my network still works as I want.

    I don’t understand the need for this boot delay and for this messages

  4. yeah I don’t know…I wish I could find the root cause but this is as close as I could get

  5. I only had the local interface in /etc/network/interfaces as described in the post in your link and it still gave me the error and made me wait

  6. check the file /etc/network/interfaces, the form correct is

    auto lo
    iface lo inet loopback

  7. @nicoxxl, @Alvaro, the suggestion to delete all but local loopback info from interfaces does not work in many situations. For instance, I get this extra wait when starting a KVM guest.. The network settings are properly configured with static IP (dhcp can’t be used as the guest is a server). But apparently network access is not available to the KVM guest at that stage of boot, hence the error. Commenting out the delays in failsafe.conf worked for me perfectly (the network works as expected upon completion of the boot sequence).

  8. Here you can find some rationale on introducing failsafe.conf
    https://bugs.launchpad.net/ubuntu/+source/upstart/+bug/839595
    And a set of nice looking workarounds
    https://bugs.launchpad.net/ubuntu/+source/upstart/+bug/839595/comments/39

  9. […] e con risolto un bug relattivo alla connessione internet all’avvio  (più informazioni qui). Non è necessario installare questo update se avete il sistema installato su disco fisso, […]

  10. Thanks, this helped me!

  11. Thank you

  12. Thank you for this perfect fix!!!!

  13. Thank you for the workaround. This issue starting happening to me when I disabled networkmanager and instead installed wicd. Networkmanager would absolutely not connect to my WPA protected wifi, while wicd has no problem.

    So, I think the problem is related to networkmanager not finding a connection during the boot process. I love the failsafe workaround.

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>