I'd like to add a new IP address to an existing interface on an Ubuntu 16.04 LTS server. I've looked at the file /etc/network/interfaces
which defines the current IP addresses/interfaces and it has the following line at the top:
source /etc/network/interfaces.d/*
Is the right thing to do to place a new file into that directory with the configuration options, and then restart the networking service?
Also, is there a reason why the source
directive is at the top of the file? Given that I'll be placing extra information into interfaces.d/*
, I'd expect those files to be sourced after my existing interfaces.
The remainder of the /etc/network/interfaces
(excluding comments) is:
auto lo
iface lo inet loopback
auto ens3
iface ens3 inet dhcp