Sunday, May 5, 2024
 Popular · Latest · Hot · Upcoming
6
rated 0 times [  6] [ 0]  / answers: 1 / hits: 78678  / 2 Years ago, wed, december 29, 2021, 8:15:51

The Question



How can ubuntu be configured so that you don't got the "waiting for network configuration..." message at boot if you got more than one adapter?



Facts




  • I've got an untouched Ubuntu here in Virtual Box and In VM-Ware Workstation.


  • My /etc/network/interfaces file is untouched and I've activated a Nat adapter to use the host systems real network card.


  • Additionally I've activated a host only adapter to be able to use a separate IP for connections between the VM and the host system.



Deduction



I figured out that the interfaces file needs only one gateway entry and this is given trough



auto eth0



iface eth0 inet dhcp.



So this is the entry for the first network adapter that provides gateway information and so the second configuration has no need for a line called



gateway 192.168.1.1.



For me that means the second entry has to look like this:



address 192.168.217.131



depending on what the router tells you as network address for the interface configured trough dcp and the second line here is the netmask. In common cases this is



netmask 255.255.255.



So the entire `/etc/network/interfaces'-file looks like this:



#This file describe the network interfaces available on your system
#and how to activate them. For more information see interfaces(5).

#The loopack network interface

auto lo
iface lo inet loopback

#The primary network interface

# ethernet 0
auto eth0
iface eth0 inet dhcp

auto eth1
iface eth1 inet static

address 192.168.217.131
netmask 255.255.255

#No need for gateway here because this is already provided by the dhcp entry.


In this example I've taken the IP address provided by Ubuntu's ^server (Basic Ubuntu Server) package what was 192.168.217.130 and increased it by one.



Now I restart Ubuntu and got the message Waiting for network Configuration... where Ubuntu try to wait for network connection about 2 minutes.



I've had the same on Virtual Box.


More From » networking

 Answers
4

There are two things to know




  1. As already mentioned above there is no need for a second gateway with a dhcp server in your network because the gateway entry is generated from there.


  2. After you've added a host-onely adapter you have to copy the ip-adress from your windows host.




So far.



Here is an example configuration for a host only connection with one additional adapter:



auto eth1

iface eth1 inet static
address 192.168.253.128
netmask 255.255.255.0
network 192.168.253.1
broadcast 192.168.253.255


The Third block of the network line depends on your ip.
the broadcast line is needed for network communication between the host and the guest. This is a networking protocol related thing.


[#29503] Thursday, December 30, 2021, 2 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
corsee

Total Points: 479
Total Questions: 122
Total Answers: 106

Location: Barbados
Member since Sat, May 9, 2020
4 Years ago
;