I have a fresh installation of Ubuntu 16.04 and I'm having issues setting up multiple static IPs. The first interface 'ens3' I was able to setup without any issues. On the rest of the interfaces, ens4-ens9, I keep getting an error message when trying to restart the networking service after setting the interface to static.
itdept@IT-DHCP:~$ sudo /etc/init.d/networking restart
[sudo] password for itdept:
[....] Restarting networking (via systemctl): networking.serviceJob for networking.service failed because the control process exited with error code. See "systemctl status networking.service" and "journalctl -xe" for details.
failed!
Here's what my /etc/network/interfaces file looks like...
# The loopback network interface
auto lo
iface lo inet loopback
# The primary network interface
# DMZ
auto ens3
iface ens3 inet static
address 10.0.0.36
netmask 255.255.224.0
gateway 10.0.1.1
dns-nameserver 10.0.0.21 10.0.0.22
# ADMIN_LAN
auto ens4
iface ens4 inet static
address 10.0.33.110
netmask 255.255.224.0
gateway 10.0.32.2
dns-nameserers 10.0.0.21 10.0.0.22
I have ens5-ens9 still set to dhcp till I figure out what's going on.
The interesting thing is that the static IP will work just fine after I reboot. I can ping 10.0.33.110 from my laptop just fine, but restarting the service will always fail. I feel like this is going to be an issue later on and would like to fix it, even if it's technically working.