> The "default bionic install" uses only netplan yaml and /etc/systemd/network/ is empty.
yes, but netplan creates .network config files named in a deterministic way so you know what the name of the networkd file it creates will be. I don't think netplan currently has a mechanism to include keep-configuration options in the networkd config it creates.
> Using '/etc/systemd/network/10-netplan-ens160.network.d/override.conf' with KeepConfiguration works perfectly the same.
exactly, which is why you should use the drop-in instead of manually duplicating and editing the entire netplan-created .network config file, as you complained about when you said:
> Now I need to have IP and gateway in two files
since, no, you don't.
Or, drop netplan and just directly configure systemd-networkd.
> The "default bionic install" uses only netplan yaml and /etc/systemd/ network/ is empty.
yes, but netplan creates .network config files named in a deterministic way so you know what the name of the networkd file it creates will be. I don't think netplan currently has a mechanism to include keep-configuration options in the networkd config it creates.
> Using '/etc/systemd/ network/ 10-netplan- ens160. network. d/override. conf' with KeepConfiguration works perfectly the same.
exactly, which is why you should use the drop-in instead of manually duplicating and editing the entire netplan-created .network config file, as you complained about when you said:
> Now I need to have IP and gateway in two files
since, no, you don't.
Or, drop netplan and just directly configure systemd-networkd.