No documentation of solution for 'one NIC with multiple IPv4s with different gateways'
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Netplan |
Fix Committed
|
Undecided
|
Unassigned |
Bug Description
Currently, NetPlan doesn't have documentation on how to configure a single network interface with multiple IP addresses with different gateways.
In the ifupdown days, this could be achieved in /etc/network/
auto ens3
iface ens3 inet static
address 192.184.82.FOO
netmask 255.255.255.0
gateway 192.184.82.1
auto ens3:1
iface ens3:1 inet static
address 107.161.23.BAR
netmask 255.255.255.0
gateway 107.161.23.1
dns-nameserver 8.8.8.8 8.8.4.4
Currently, NetPlan does not have this functionality documented.
There are many cases where this type of setup could be needed, such as with some VPSes, etc. which only have a single NIC that you can utilize on the system, and no ability to add additional NICs bound to the same 'connection'. Therefore, it stands to reason we might need this to be an example in documentation somewhere.
Can we get such documentation and/or examples made available?
Thanks to Cyphermox for their very useful example and description of how to achieve this.
The functionality therefore clearly exists, so maybe we can get a documentation example added?