Previously I had a script to apply my second static IP and route on the default NIC on boot like so:

ip addr del dev ens5
ip route add dev ens5 src

But since upgrading to Ubuntu 18.04, occasionally the systemd/networking refresh will delete the interface around 7am (and NTPD will log to syslog soon after 'deleteting interface' sending me on a wild goose chase)

How can I translate the above commands to a netplan config that will play nice with the existing ens5 config that is autogenerated by AWS?

Alternatively I tried adding a second IP in AWS console, but it tells me it must be in 172 range.

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Browse other questions tagged or ask your own question.