我们有 3 台 Unix(1 台 Ubuntu 2 台 Redhat)服务器,通过 10 Gbit 网卡连接到 10 Gbit 交换机(我们的 IT 人员确保我们获得了正确的电缆)。我们在服务器之间发送文件时遇到了一些奇怪的行为(通过 scp 10Gbit-ip 或使用 10 Gbit ip 通过 fstab 安装的文件夹)。速度通常远低于 10 Gbit,但略高于 1 Gbit。在其中一台服务器上,进度条非常快,但随后会长时间停留在 100%。该服务器上的 scp 也是如此。
为了确保我们获得全双工和 10000 Mbit/s,我使用了两个不同的函数,它们给出了相互矛盾的信息。有人知道发生了什么吗?mii-tools 和 ethtool 给出的信息不一样:
em1 = 1 Gbit 网络(通过 10 Gbit 端口) em2 = 10 Gbit 网络(通过 10 Gbit 端口)
ifconfig:
[admin@XXXX ~]$ ifconfig
em1: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet XXXX netmask 255.255.255.0 broadcast XXXXX
inet6 fe80::eef4:bbff:fed5:c230 prefixlen 64 scopeid 0x20<link>
ether ec:f4:bb:d5:c2:30 txqueuelen 1000 (Ethernet)
RX packets 3938043336 bytes 17103106879433 (15.5 TiB)
RX errors 0 dropped 28 overruns 0 frame 0
TX packets 8178327495 bytes 8360136815032 (7.6 TiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
em2: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet XXXXX netmask 255.255.255.0 broadcast XXXX
inet6 fe80::eef4:bbff:fed5:c232 prefixlen 64 scopeid 0x20<link>
ether ec:f4:bb:d5:c2:32 txqueuelen 1000 (Ethernet)
RX packets 3314001 bytes 28089131102 (26.1 GiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 7632971 bytes 7936298958 (7.3 GiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions
mii工具:
[admin@XXX ~]$ sudo mii-tool em1
[sudo] password for admin:
SIOCGMIIREG on em1 failed: Invalid argument
SIOCGMIIREG on em1 failed: Invalid argument
SIOCGMIIREG on em1 failed: Invalid argument
em1: 1000 Mbit, half duplex, link ok
[admin@XXX ~]$ sudo mii-tool em2
SIOCGMIIREG on em2 failed: Invalid argument
SIOCGMIIREG on em2 failed: Invalid argument
SIOCGMIIREG on em2 failed: Invalid argument
em2: 1000 Mbit, half duplex, link ok
乙醇:
[admin@XXXX ~]$ sudo ethtool em1
Settings for em1:
Supported ports: [ TP ]
Supported link modes: 100baseT/Full
1000baseT/Full
10000baseT/Full
Supported pause frame use: No
Supports auto-negotiation: Yes
Advertised link modes: 100baseT/Full
1000baseT/Full
10000baseT/Full
Advertised pause frame use: No
Advertised auto-negotiation: Yes
Speed: 1000Mb/s
Duplex: Full
Port: Twisted Pair
PHYAD: 0
Transceiver: external
Auto-negotiation: on
MDI-X: Unknown
Supports Wake-on: umbg
Wake-on: g
Current message level: 0x00000007 (7)
drv probe link
Link detected: yes
[admin@XXXX ~]$ sudo ethtool em2
Settings for em2:
Supported ports: [ TP ]
Supported link modes: 100baseT/Full
1000baseT/Full
10000baseT/Full
Supported pause frame use: No
Supports auto-negotiation: Yes
Advertised link modes: 100baseT/Full
1000baseT/Full
10000baseT/Full
Advertised pause frame use: No
Advertised auto-negotiation: Yes
Speed: 10000Mb/s
Duplex: Full
Port: Twisted Pair
PHYAD: 0
Transceiver: external
Auto-negotiation: on
MDI-X: Unknown
Supports Wake-on: umbg
Wake-on: g
Current message level: 0x00000007 (7)
drv probe link
Link detected: yes
如您所见,使用 ethtool(全双工和全速)一切正常,但使用 mii-tool(1000 Mb/s 和半双工)则不然。可能的原因是什么以及可能的测试/修复方法是什么?