为什么我们无法 ping Proxmox 6.1-3 上的 Open-vSwitch 网络配置上的网关?

为什么我们无法 ping Proxmox 6.1-3 上的 Open-vSwitch 网络配置上的网关?

我们正在尝试让 open vswitch 在 10 台运行 Proxmox 6.1-3 的主机上运行。我们认为我们有一个应该可以工作的配置,但它却不行,我们无法 ping 网关。这些主机有 4 个网卡,我们想用 LACP 将它们绑定,然后建立一个桥接器,这样我们就可以在不同的 VLAN 上拥有虚拟网卡。我们对 ProxMox 没有什么经验(我在家里用过单主机,这是我们实验室的一个实验),我们对 open-vswitch 也没有经验。

我们正在使用此页面,示例 2 是我们正在执行的操作的模板:https://pve.proxmox.com/wiki/Open_vSwitch

在我们的测试中,即使我们采用 LACP,我们也禁用了交换机上的 3/4 个端口以简化故障排除。使用以下配置,我们无法 ping 网关。我认为我们的 ovs 配置存在问题,具体来说,端口 vmbr0 的接口被列为 vmbr0 本身而不是 bond0,但我们不知道如何纠正它。systemctl status networking 或 systemctl status ovs-* 中没有显示任何错误。以下是 /etc/network/interfaces 的配置(请原谅任何拼写错误;我从控制台的照片中重新输入了此内容):

# Loopback interface
auto lo
iface lo inet loopback

allow-vmbr0 bond0
iface bond0 inet manual
    ovs_bridge vmbr0
    ovs_type OVSBond
    ovs_bonds eno1 eno2 eno3 eno4
    ovs_options bond-mode=balance-tcp lacp=active other_config:lacp-time=fast
    ovs_mtu 9000

allow-ovs vmbr0
iface vmbr0 inet manual
    ovs_type OVSBridge
    ovs_ports bond0 vlan10
    ovs_mtu 9000

allow-vmbr vlan10
iface vlan10 inet static
    ovs_type OVSIntPort
    ovs_bridge vmbr0
    ovs_options tag=10
    ovs_extra set interface ${IFACE} external-ids:iface-id=$(hostname -s)-${IFACE}-vif
    address 10.1.10.75
    netmask 255.255.255.0
    gateway 10.1.10.253
    ovs_mtu 9000

接下来,当我们执行“ip a”时,我们会得到以下内容

1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
        valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host
        valid_lft forever preferred_lft forever
2: eno1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq master ovs-system state UP group default qlen 1000
    link/ether 18:03:73:f5:7e:a5 brd ff:ff:ff:ff:ff:ff
    inet6 fe80::1a03:73ff:fef5:7ea5/64 scope link
        valid_lft forever preferred_lft forever
3: eno2: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc mq master ovs-system state DOWN group default qlen 1000
    link/ether 18:03:73:f5:7e:a7 brd ff:ff:ff:ff:ff:ff
4: eno3: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc mq master ovs-system state DOWN group default qlen 1000
    link/ether 18:03:73:f5:7e:a9 brd ff:ff:ff:ff:ff:ff
5: eno4: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc mq master ovs-system state DOWN group default qlen 1000
    link/ether 18:03:73:f5:7e:ab brd ff:ff:ff:ff:ff:ff
6: enp4s0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether 90:e2:ba:2b:06:24 brd ff:ff:ff:ff:ff:ff
7: ovs-system: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether 66:9a:fb:4a:4f:b0 brd ff:ff:ff:ff:ff:ff
8: vmbr0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 9000 qdisc noqueue state UNKNOWN group default qlen 1000
    link/ether 18:03:73:f5:7e:a5 brd ff:ff:ff:ff:ff:ff
    inet6 fe80::1a03:73ff:fef5:7ea5/64 scope link
        valid_lft forever preferred_lft forever
9: vlan10: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UNKNOWN group default qlen 1000
    link/ether 76:1d:a2:b8:63:09 brd ff:ff:ff:ff:ff:ff
    inet 10.1.10.75/24 scope global vlan10
        valid_lft forever preferred_lft forever
    inet6 fe80::741d:a2ff:feb8:6309/64 scope link
        valid_lft forever preferred_lft forever
10: bond0: <BROADCAST,MULTICAST,UP,LWER_UP> mtu 1500 qdisc noqueue state UNKNOWN group default qlen 1000
    link/ether 22:05:b7:42:a3:18 brd ff:ff:ff:ff:ff:ff
    inet6 fe80::2005:b7ff:fe42:a318/64 scope link
        valid_lft forever preferred_lft forever

如果我运行“ovs-vsctl show”,我们会看到以下内容:

f1733867-7e12-4d9a-bcf2-364bf38cd161
    Bridge "vmbr0"
        Port "bond0"
            Interface "eno2"
            Interface "eno3"
            Interface "eno4"
            Interface "eno1"
        Port "vmbr0"
            Interface "vmbr0"
                type: internal
        Port "vlan10"
            tag: 10
            Interface "vlan10"
                type: internal
    ovs_version: "2.10.1"

任何帮助或见解都将不胜感激!

相关内容