Netplan 的多个接口和网络:无法 ping 本地网络

Netplan 的多个接口和网络:无法 ping 本地网络

我的 netplan 配置具有多个接口和网络,除了 ping 到(或从?)本地网络外,其他都运行正常。

这是我的设置:

network:
  version: 2
  ethernets:
    ens160:
      dhcp4: no
      addresses:
      - 172.16.1.114/16
      match:
          macaddress: 00:50:56:aa:00:1d
      mtu: 1500
      nameservers:
        addresses:
        - 172.16.1.11
        - 172.16.1.20
        search:
        - domain.com
      set-name: production
      routes:
        - to: 0.0.0.0/0
          via: 172.16.1.1
          metric: 100
          on-link: true
          table: 800
      routing-policy:
        - from: 0.0.0.0/0
          table: 800
    ens192:
      dhcp4: no
      addresses:
      - 172.21.2.114/16
      match:
          macaddress: 00:50:56:aa:6f:ed
      mtu: 1500
      nameservers:
        addresses:
        - 172.16.1.11
        - 172.16.1.20
        search:
        - domain.com
      set-name: quality
      routes:
        - to: 0.0.0.0/0
          via: 172.21.1.1
          metric: 100
          on-link: true
          table: 801
      routing-policy:
        - from: 0.0.0.0/0
          table: 801
    ens224:
      dhcp4: no
      addresses:
      - 172.21.1.114/16
      match:
          macaddress: 00:50:56:aa:16:92
      mtu: 1500
      nameservers:
        addresses:
        - 172.16.1.11
        - 172.16.1.20
        search:
        - domain.com
      set-name: development
      routes:
        - to: 0.0.0.0/0
          via: 172.21.1.1
          metric: 100
          on-link: true
          table: 802
      routing-policy:
        - from: 0.0.0.0/0
          table: 802

感谢您的帮助!

顺便问一下,为了排除故障,有没有办法选择从哪个设备发送数据包?

相关内容