I'm using fresh Ubuntu Server 18.10 (Cosmic) installation with netplan. What I'm trying to achieve is to setup network interface via DHCP and add some static routes.
With static IP settings things are working correctly. With DHCP 'routes:' are not applied
Any ideas how to change that?
Commands used to apply settings:
netplan generate
netplan apply
WORKS
network:
ethernets:
enp0s3:
addresses: []
dhcp4: true
dhcp6: true
enp0s8:
dhcp4: false
addresses:
- 192.168.1.10/24
routes:
- to: 10.10.0.0/24
via: 192.168.1.2
- to: 10.9.0.0/24
via: 192.168.1.2
version: 2
DOES NOT WORK
network:
ethernets:
enp0s3:
addresses: []
dhcp4: true
dhcp6: true
enp0s8:
dhcp4: true # <- CHANGED
addresses: [] # <- CHANGED
routes:
- to: 10.10.0.0/24
via: 192.168.1.2
- to: 10.9.0.0/24
via: 192.168.1.2
version: 2
EDIT: [20.12.2018]: After new research I was able to find that my issue is an animal (a bug to be specific).
addresses: []
be there? – George Udosen Dec 19 '18 at 19:12sudo netplan --debug apply
and post the specific errors! – George Udosen Dec 19 '18 at 19:16