在 Ubuntu 20.04 上可以使用 netplan 配置多少个虚拟适配器?

问题描述

我的 Ubuntu 20 服务器机器上有一个名为 enp65s0f1 的以太网接口。我想创建许多虚拟接口,每个接口都有自己的 mac 地址和 ip 地址,这些接口承载在这个接口上,并从我的 DHCP 服务器获取它们自己的 IP 地址。我正在使用以下 netplan 配置来完成此操作,但是从未创建第 8 个(以及它之后的任何内容)虚拟设备,并且任何日志中都没有关于它失败的任何日志(尽管我确实看到了有关它设置的日志)其余的)。您可以使用 netplan 创建的虚拟设备数量是否有限制?如果是这样,它是真的 8 吗?希望我只是做错了什么。谢谢!

# This is the network config written by 'home-lab'
network:
  version: 2
  ethernets:

    enp65s0f1v0:
      macaddress: 52:54:00:6b:3c:57
      dhcp4: true
      dhcp4-overrides:
        hostname: plex
        send-hostname: true

    enp65s0f1v1:
      macaddress: 52:54:00:6b:3c:58
      dhcp4: true
      dhcp4-overrides:
        hostname: sabnzbd
        send-hostname: true

    enp65s0f1v2:
      macaddress: 52:54:00:6b:3c:59
      dhcp4: true
      dhcp4-overrides:
        hostname: sonarr
        send-hostname: true

    enp65s0f1v3:
      macaddress: 52:54:00:6b:3c:60
      dhcp4: true
      dhcp4-overrides:
        hostname: radarr
        send-hostname: true

    enp65s0f1v4:
      macaddress: 52:54:00:6b:3c:61
      dhcp4: true
      dhcp4-overrides:
        hostname: minecraft
        send-hostname: true

    enp65s0f1v5:
      macaddress: 52:54:00:6b:3c:62
      dhcp4: true
      dhcp4-overrides:
        hostname: sevendaystodie
        send-hostname: true

    enp65s0f1v6:
      macaddress: 52:54:00:6b:3c:63
      dhcp4: true
      dhcp4-overrides:
        hostname: portainer
        send-hostname: true

    enp65s0f1v7:
      macaddress: 52:54:00:6b:3c:64
      dhcp4: true
      dhcp4-overrides:
        hostname: PHPvirtualBox
        send-hostname: true

    enp65s0f1v8:
      macaddress: 52:54:00:1b:3d:00
      dhcp4: true
      dhcp4-overrides:
        hostname: eco-nds
        send-hostname: true

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)