Ubuntu 无法检测 100mbps 以太网连接

Ubuntu 无法检测 100mbps 以太网连接

最近我买了一台新机器,并在其上安装了 ubuntu。我连接了一个 1000mbps 以太网连接。后来出于某种原因,我不得不连接到另一个只有 100mbps 的以太网连接。现在机器无法检测到新的 100mbps 连接。Ubuntu 显示“电缆已拔出”。但是如果我连接之前的 1000mbps 连接,它就可以正常工作。我检查了一下,后面的 100mbps 连接没有问题,并且可以在不同的机器上运行。所以我推测,ubuntu 中存在一些问题/配置,只接受 1000mbps 连接而不接受其他连接。我该如何解决这个问题?

输出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 state UP group default qlen 1000
    link/ether 3c:ec:ef:83:6e:90 brd ff:ff:ff:ff:ff:ff
    altname enp96s0f0
    inet 192.168.31.248/24 brd 192.168.31.255 scope global dynamic noprefixroute eno1
       valid_lft 80859sec preferred_lft 80859sec
    inet6 fe80::b8c7:a5b7:d509:df63/64 scope link noprefixroute 
       valid_lft forever preferred_lft forever
3: eno2: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc mq state DOWN group default qlen 1000
    link/ether 3c:ec:ef:83:6e:91 brd ff:ff:ff:ff:ff:ff
    altname enp96s0f1

编辑2:的内容/etc/netplan/01-network-manager-all.yaml

# Let NetworkManager manage all devices on this system
network:
  version: 2
  renderer: NetworkManager

答案1

  1. 确保您使用的是可用的以太网电缆。
  2. 安装ethtool
  3. 运行sudo ethtool eno1并检查Supported link modesAdvertised link modesSupports auto-negotiation/ Auto-negotiation
    Supported link modes:   10baseT/Half 10baseT/Full
                            100baseT/Half 100baseT/Full
                            1000baseT/Full
    Supports auto-negotiation: Yes
    Advertised link modes:  10baseT/Half 10baseT/Full
                            100baseT/Half 100baseT/Full
                            1000baseT/Full
    Advertised auto-negotiation: Yes
    Auto-negotiation: on
  1. 如果没有连接,请在另一台与问题端口连接的计算机上运行此命令,并检查相应的值Link partner
    Link partner advertised link modes:  10baseT/Half 10baseT/Full
                                         100baseT/Half 100baseT/Full
    Link partner advertised pause frame use: Symmetric
    Link partner advertised auto-negotiation: Yes
    Speed: 100Mb/s
    Duplex: Full
    Auto-negotiation: on
  1. 如果两者都具有兼容模式,请尝试使用ethtool更改命令更改您的卡参数以满足链接伙伴的参数,如其帮助中所示:
        ethtool [ FLAGS ] -s|--change DEVNAME   Change generic options
        [ speed %d ]
        [ lanes %d ]
        [ duplex half|full ]
        [ port tp|aui|bnc|mii|fibre|da ]
        [ mdix auto|on|off ]
        [ autoneg on|off ]
        [ advertise %x[/%x] | mode on|off ... [--] ]
        [ phyad %d ]
        [ xcvr internal|external ]
        [ wol %d[/%d] | p|u|m|b|a|g|s|f|d... ]
        [ sopass %x:%x:%x:%x:%x:%x ]
        [ msglvl %d[/%d] | type on|off ... [--] ]
        [ master-slave preferred-master|preferred-slave|forced-master|forced-slave ]

相关内容