从昨天晚上开始,我的(自制的)Linux(OpenSuSE Leap 15.0)家庭服务器出现了以下问题:它的两个板载以太网链路之一不断下降,然后上升,然后再次下降,......经常发生。
通常,这些中断会持续几秒钟并且不会引起注意,但我也遇到过几分钟的停机时间。其中之一甚至导致我服务器上的 RAID 失去一致性。
这是dmesg
(不受影响的其他网络接口的消息已被删除)的输出:
[ 815.518384] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Up 1000 Mbps Full Duplex, Flow Control: RX/TX
[ 835.069925] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Down
[ 838.322327] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Up 1000 Mbps Full Duplex, Flow Control: RX/TX
[ 897.277739] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Down
[ 900.218140] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Up 1000 Mbps Full Duplex, Flow Control: RX/TX
[ 974.621515] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Down
[ 977.501918] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Up 1000 Mbps Full Duplex, Flow Control: RX/TX
[ 1069.501256] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Down
[ 1073.073644] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Up 1000 Mbps Full Duplex, Flow Control: RX/TX
[ 1126.653085] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Down
[ 1129.465504] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Up 1000 Mbps Full Duplex, Flow Control: RX/TX
[ 1440.928076] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Down
[ 1444.176477] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Up 1000 Mbps Full Duplex, Flow Control: RX/TX
[ 1447.680055] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Down
[ 1450.888453] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Up 1000 Mbps Full Duplex, Flow Control: RX/TX
[ 1532.575777] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Down
[ 1535.812158] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Up 1000 Mbps Full Duplex, Flow Control: RX/TX
[ 1554.875708] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Down
[ 1557.728109] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Up 1000 Mbps Full Duplex, Flow Control: RX/TX
[ 1688.103281] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Down
[ 1691.411675] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Up 1000 Mbps Full Duplex, Flow Control: RX/TX
[ 1753.243072] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Down
[ 1756.119469] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Up 1000 Mbps Full Duplex, Flow Control: RX/TX
[ 1781.274983] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Down
[ 1814.927299] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Up 1000 Mbps Full Duplex, Flow Control: RX/TX
[ 1839.818791] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Down
[ 2108.682340] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Up 1000 Mbps Full Duplex, Flow Control: RX/TX
[ 2119.769891] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Down
[ 2128.118276] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Up 1000 Mbps Full Duplex, Flow Control: RX/TX
[ 2172.877720] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Down
[ 2203.106035] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Up 1000 Mbps Full Duplex, Flow Control: RX/TX
[ 2207.337608] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Down
[ 2465.245184] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Up 1000 Mbps Full Duplex, Flow Control: RX/TX
[ 4206.183121] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Down
[ 4209.203544] igb 0000:01:00.0 eth2: igb: eth2 NIC Link is Up 1000 Mbps Full Duplex, Flow Control: RX/TX
网络接口是华硕主板上的 I210 千兆位网络连接 (eth2)。这是操作系统版本:
╭─root@valen ~
╰─➤ uname -a
Linux valen 4.12.14-lp150.12.64-default #1 SMP Mon Jun 17 16:53:50 UTC 2019 (3edfd41) x86_64 x86_64 x86_64 GNU/Linux
最后一次系统更新是在上周二,但问题是周五晚上开始的,所以我认为这不是驱动程序问题。
可能是什么原因?谢谢你。
更新:
根据要求,这里是ethtool
输出:
╭─root@valen ~
╰─➤ ethtool -S eth2
NIC statistics:
rx_packets: 257315
tx_packets: 603706
rx_bytes: 85237411
tx_bytes: 775258267
rx_broadcast: 1023
tx_broadcast: 419
rx_multicast: 75
tx_multicast: 104
multicast: 75
collisions: 0
rx_crc_errors: 0
rx_no_buffer_count: 0
rx_missed_errors: 0
tx_aborted_errors: 0
tx_carrier_errors: 0
tx_window_errors: 0
tx_abort_late_coll: 0
tx_deferred_ok: 0
tx_single_coll_ok: 0
tx_multi_coll_ok: 0
tx_timeout_count: 0
rx_long_length_errors: 0
rx_short_length_errors: 0
rx_align_errors: 0
tx_tcp_seg_good: 82646
tx_tcp_seg_failed: 0
rx_flow_control_xon: 21
rx_flow_control_xoff: 21
tx_flow_control_xon: 0
tx_flow_control_xoff: 0
rx_long_byte_count: 85237411
tx_dma_out_of_sync: 0
tx_smbus: 0
rx_smbus: 0
dropped_smbus: 0
os2bmc_rx_by_bmc: 0
os2bmc_tx_by_bmc: 0
os2bmc_tx_by_host: 0
os2bmc_rx_by_host: 0
tx_hwtstamp_timeouts: 0
tx_hwtstamp_skipped: 0
rx_hwtstamp_cleared: 0
rx_errors: 0
tx_errors: 0
tx_dropped: 0
rx_length_errors: 0
rx_over_errors: 0
rx_frame_errors: 0
rx_fifo_errors: 0
tx_fifo_errors: 0
tx_heartbeat_errors: 0
tx_queue_0_packets: 103348
tx_queue_0_bytes: 114658835
tx_queue_0_restart: 0
tx_queue_1_packets: 61601
tx_queue_1_bytes: 77258944
tx_queue_1_restart: 0
tx_queue_2_packets: 94305
tx_queue_2_bytes: 97486823
tx_queue_2_restart: 0
tx_queue_3_packets: 344452
tx_queue_3_bytes: 483419252
tx_queue_3_restart: 0
rx_queue_0_packets: 30966
rx_queue_0_bytes: 4981061
rx_queue_0_drops: 0
rx_queue_0_csum_err: 0
rx_queue_0_alloc_failed: 0
rx_queue_1_packets: 137558
rx_queue_1_bytes: 65059503
rx_queue_1_drops: 0
rx_queue_1_csum_err: 0
rx_queue_1_alloc_failed: 0
rx_queue_2_packets: 42880
rx_queue_2_bytes: 7877235
rx_queue_2_drops: 0
rx_queue_2_csum_err: 0
rx_queue_2_alloc_failed: 0
rx_queue_3_packets: 45911
rx_queue_3_bytes: 6290352
rx_queue_3_drops: 0
rx_queue_3_csum_err: 0
rx_queue_3_alloc_failed: 0
好吧,我想我已经找到答案了:交换机上的 RJ45 插座,从我服务器的 eth2 运行的电缆曾经连接到原来是有故障的!我将电缆连接到以前未使用的连接器上,从那时起,到目前为止一切正常。
尽管如此,还是谢谢大家的提示!