24

I have recently installed ubuntu server 16.04 LTS.a message is coming at the starting time " a start job is running for the raise network " & it takes too much time under offline network. but, when it comes to online makes no problem. how to make faster the startup process without this annoying message if I want to come offline ? and also there is a bridge connection named "virbr0" but not the simple ethernet network, why is this happening ?

need help .

user632465
  • 249
  • 1
  • 2
  • 4

4 Answers4

18
auto eno1
iface eno1 inet dhcp

to

allow-hotplug eno1
iface eno1 inet dhcp

For more information https://manpages.debian.org/stretch/ifupdown/interfaces.5.en.html

  • 4
    This fixed slow startup on Ubuntu 18.04 after installing KVM for Android Studio. My Android Emulators (VMs) + I still have internet connection so I guess nothing broke. Thanks alot! – hb0 Dec 12 '19 at 16:09
  • 1
    Thanks, this solved our problem for laptops managed by puppet/debnet. This commit is available for other folks in the same boat: https://github.com/rtib/tib-debnet/pull/18/commits/c1944642c8860085f87b92ed2494612f346fa6c5 – Bill McGonigle May 11 '22 at 17:21
  • This shoul be the accepted answer. Works like a charm – borekon Mar 07 '23 at 07:58
  • This should be accepted as the correct answer! Man, for the newbies ones, you should also add that the file you've changed is `/etc/network/interfaces` – FtheBuilder Jun 11 '23 at 05:58
18

I seem to get the same issue and I also have a bridged network interface, probably from my VirtualBox setup, enp0s31f6:avahi.

My system is ubuntu 16.04 LTS server variant, installed on a laptop, so primary use is as a workstation. As pr the comments this still applies for ubuntu 20.04 LTS.

The issue is there if the bridged interface is there, not if it's not present, say if VirtualBox has not been started inbetween reboots.

The reason is as in the other answer that this interface lacks init info.

My sollution was to reduce the timeout, and to do so without messing with the base installed networking.services systemd file. This will persist during updates in any package.

sudo mkdir -p /etc/systemd/system/networking.service.d/
sudo bash -c 'echo -e "[Service]\nTimeoutStartSec=20sec" > /etc/systemd/system/networking.service.d/timeout.conf'
sudo systemctl daemon-reload
sastorsl
  • 453
  • 5
  • 11
  • 1
    Works on Ubuntu 18.04 LTS (desktop) as well, thanks! I appreciate the additive nature of this solution. – Raphael Jul 23 '18 at 07:43
  • This solved the long waiting time for me as well, however the root cause is not fixed which is that the bridged network interface suddenly stoped connecting to the internet. So the ubunut box within vb now has no internet connection. – merlin Feb 12 '19 at 18:33
  • I'm using a WLAN USB adapter and have the same issue. This fix makes the boot faster but then the wireless adapter does not work anymore. Resetting settings and plugging it out and in again helped. Damn, I was happy to find a quick solution. – hb0 Dec 05 '19 at 08:48
  • 2
    Works also for Ubuntu 20.04 LTS. My boot time was more than 5 min (crazy) and not is around 2.5 min. The only solution would be to make a clean install, rather than and upgrade. – vasiauvi Jun 21 '20 at 16:39
4

Follow these steps:

  • Open Terminal (Ctrl + Alt + T)
  • Open /etc/network/interfaces file with gedit or nano:

    sudo nano /etc/network/interfaces
    
  • Set below text for any interfaces in this file:

    auto lo
    iface lo inet loopback  
    auto eth0
    iface eth0 inet dhcp  
    auto wlan0
    iface wlan0 inet dhcp
    
  • Save the file and reboot

Ghasem Pahlavan
  • 1,805
  • 14
  • 20
1
  1. Open Terminal (Ctrl + Alt + T)
  2. Open /etc/network/interfaces file with gedit or nano:

    sudo nano /etc/network/interfaces
    
  3. Set below text for any interfaces in this file:

    auto lo
    iface lo inet loopback
    
  4. Remove any other entries.

  5. Save the file and reboot

It solved for me.

Daniele Santi
  • 3,084
  • 4
  • 30
  • 30
john maxwell
  • 111
  • 2