I am running a server (Ubuntu 16.04) which has two network cards eno1 and eno2.
- eno1 is connected to the outside and receives a public IP address over dhcp
- eno2 is connected to a private network and receives a private IP address over dhcp (say 192.168.0.2 for simplicity)
The server netboots and receives everything from a second server on the private network (say 192.168.0.1). I follwed the Diskless Ubuntu HowTo and everything works pretty well.
- the server gets 192.168.0.2 as ip address
- then it loads the kernel and initramfs over tftp (from 192.168.0.1) and continues
- later it mounts
/which is also located on 192.168.0.1
With the last step there is however a problem. More or less simultaneously the system tries to get IP addresses for both eno1 and eno2, and sometimes eno1 finishes first. Then the system tries to find 192.168.0.1 through eno1, which it of course can't and times out.
As stated in the tutorial I included
iface eno2 inet manual in my
/etc/network/interfaces, to prevent eno2 from losing its address, but this does not seem to help.
Any idea how to force it to use eno2 instead of whichever network interface to use first