!tCyGickeVqkHsYjWnh:nixos.org

NixOS Networking

900 Members
on your Router! Declaratively manage your switching, routing, wireless, tunneling and more.268 Servers

You have reached the beginning of time (for this room).


SenderMessageTime
26 Jun 2025
@matthewcroughan:defenestrate.itmatthewcroughanBut I thought it would be given I put this in the networkd config13:28:29
@matthewcroughan:defenestrate.itmatthewcroughan
...
      "30-enp196s0" = {
        matchConfig.Name ="enp196s0";
        linkConfig = {
          Unmanaged = "yes";
        };
        linkConfig.RequiredForOnline = "enslaved";
        networkConfig = {
          Bridge = "br0";
        };
      };
...
13:28:33
@matthewcroughan:defenestrate.itmatthewcroughanIs this not telling enp196s0 to be a slave to the bridge?13:29:26
@matthewcroughan:defenestrate.itmatthewcroughanI am really just following https://wiki.nixos.org/wiki/Systemd/networkd#Bridge13:29:56
@adam:robins.wtfadamcstephensnetworkConfig.Bridge should yes. but I've not seen/used linkConfig.Unmanaged. Why did you add that?13:30:25
@matthewcroughan:defenestrate.itmatthewcroughanAh, copy paste from somewhere 13:30:38
@matthewcroughan:defenestrate.itmatthewcroughanhttps://discourse.nixos.org/t/setup-networking-between-multiple-vms/44910/213:30:44
@matthewcroughan:defenestrate.itmatthewcroughanI looked here first 13:30:47
@matthewcroughan:defenestrate.itmatthewcroughanI'll remove it and see what happens 13:30:50
@adam:robins.wtfadamcstephens

When "yes", no attempts are made to bring up or configure matching links, equivalent to when there are no matching network files. Defaults to "no".

13:30:54
@adam:robins.wtfadamcstephensthat seems undesirable13:30:59
@adam:robins.wtfadamcstephensI'd encourage reading the docs on the options you're setting :)13:31:52
@matthewcroughan:defenestrate.itmatthewcroughanIn any case, removing that line didn't change the behavior 13:32:35
@matthewcroughan:defenestrate.itmatthewcroughan
  systemd.network = {
    networks = {
      "10-eth-priority" = {
        matchConfig.Name = "enp196s0";
        DHCP = "yes";
        dhcpV4Config.RouteMetric = 1023;
        dhcpV6Config.RouteMetric = 1023;
      };
      "30-enp196s0" = {
        matchConfig.Name ="enp196s0";
        linkConfig.RequiredForOnline = "enslaved";
        networkConfig = {
          Bridge = "br0";
        };
      };
      "40-tap0" = {
        matchConfig.Name ="tap0";
        bridgeConfig = {   };
        linkConfig.RequiredForOnline = "enslaved";
        networkConfig = {
          Bridge = "br0";
        };
      };
      "40-br0" = {
        matchConfig.Name = "br0";
        bridgeConfig = {};
        linkConfig = {
          RequiredForOnline = "carrier";
        };
      };
    };
    netdevs = {
      "20-tap0" = {
       enable = true;
        netdevConfig = {
          Kind = "tap";
          Name = "tap0";
        };
      };
      "20-br0" = {
        enable = true;
        netdevConfig = {
          Kind = "bridge";
          Name = "br0";
        };
      };
    };
  };

13:33:02
@matthewcroughan:defenestrate.itmatthewcroughanIs there some state in the network stack that can only be fixed by rebooting now?13:34:00
@adam:robins.wtfadamcstephensthere can be changes that are easiest fixed by rebooting, yes.13:34:58
@matthewcroughan:defenestrate.itmatthewcroughanNope, a reboot did not change this state13:40:26
@matthewcroughan:defenestrate.itmatthewcroughanenp196s0 is still not attached to the bridge in the above config13:40:34
@matthewcroughan:defenestrate.itmatthewcroughan bridge link still only shows tap0 13:40:52
@antifuchs:asf.computerantifuchsWhy are you dhcp’ing on the bridge participant interface instead of the bridge itself? That can’t result in a working config (this is unrelated, but also a problem)13:55:07
@antifuchs:asf.computerantifuchsAnyway I recall something like this happened on one of my machine, I’ll go take a look13:56:07
@adam:robins.wtfadamcstephensi don't think it's a violation to put the IP on the individual interface, but it is preferable to put it on the bridge for sure14:03:42

Show newer messages


Back to Room ListRoom Version: 6