[07:57] Hello all! I am having some issues with netplan when adding a second NIC. I created this https://pastebin.com/EFNyR4ka to describe the problem. Your help is appreciated! Thanks! [08:28] SteelRose: hi! In your pastebin you mention wanting to connect on a different VLAN? I don't see any mention of vlan in your config file. [08:36] schopin: let me rephrase it: I need to have 1 NIC on one network with its own GW, and 1 NIC on another network with its own GW [08:37] Ah. OK. [08:37] I found this example https://netplan.io/examples/#using-multiple-addresses-with-multiple-gateways - it is OK if I have 1 NIC with 2 IP addresses but now I cannot reach the server using the secondary IP ... [08:38] having 2 IP addresses on one NIC is now what I was hoping for but it will do for now.. [08:38] SteelRose: sorry if this seems obvious, but have you invoked `netplan try` or `netplan apply`? [08:38] schopin: yes :-) [08:39] netplan create first, then apply [08:39] after the apply is when I loose connectivity with the server (my ssh session freezes right away) [08:40] so my question to the channel: do you guys have a working example of 2 NICs, each with a different IP + gateway for each range? [08:41] SteelRose: are you sure you need multiple gateways? [08:41] SteelRose: multiple gateways don't make sense on a system level. [08:41] Recent versions of netplan should actually emit a warning if multiple gateways are configured. [08:43] Also, could you paste the content of /run/systemd/network/*netplan-* after running `netplan apply`? This is where netplan puts the generated systemd-networkd configuration files. [08:44] ... wait, I just noticed you used different routing tables. Disregard my gateway comment then :) [08:45] OK; I need to rephrase again: "different IPs + routing for each range" :-) [08:46] Eh. It's morning where I am, coffee hasn't kicked in yet ;-) [08:47] schopin: it's morning here as well [08:47] Also, it would be nice to have whatever netplan outputs (if anything), as well as the output of `ip l` and `ip a`? [08:48] I'm not down on the troubleshooting routines of netplan yet :P [08:49] Oh, and perhaps simply `netplan get`. This last one dumps all the config that netplan sees. [08:52] schopin: I modified the netplan following the official example https://netplan.io/examples/#using-multiple-addresses-with-multiple-gateways - but now I cannot ping the secondary IP [08:54] The problem can be in a lot of places, from netplan failing to find the updated config, to it failing to generate the correct config for systemd-networkd, to networkd failing to configure the interface, or the routes... Hence my different questions :) [09:20] thanks schopin ... I'll review every step and might come back with some updates [09:20] re [10:03] SteelRose: in my experience, policy routing is required when you have different subnets behind different interfaces [10:04] so the example doc you linked isn't relevant for you, I think [10:04] kjetilho: do you have any working example? [10:04] (and sorry, I didn't look at your pastebin earlier, I underestimated your understanding :) [10:04] :-) [10:06] SteelRose: in my working config, I have from: nic-local-address on each route [10:07] and also the I use that nic-local-address in my routing-policy, but that shouldn't matter I think [10:07] oh, and I don't have a gateway set on the secondary NIC [10:08] *and* I have `link-local: [ ]` [10:32] kjetilho: would you mind sharing your config? of course, I expect that you fake the addresses :-) [10:33] so much work to fake addresses consistently :) [10:33] the above is a pretty accurate diff [10:39] :-/ [12:18] SteelRose: oh, another difference: I just use plain gateway4 on ens160. [13:52] kjetilho: that is what I had... anyway, I had to put that netplan config on ice as something more important landed on my desk