Networking
如何在 RHEL 機器上查找網卡詳細資訊
是否可以找到有關 Linux 卡的詳細資訊?
例如我們嘗試過:
dmidecode | grep -i network Function key-initiated network boot is supported Port Type: Network Port Port Type: Network Port Port Type: Network Port Port Type: Network Port # dmidecode | grep -i eth Type: Ethernet Type: Ethernet Type: Ethernet Type: Ethernet
這個細節並沒有說明網卡和性能等。
關於可以提供有關網卡的這些詳細資訊的工具有什麼建議嗎?
要獲取網卡的品牌/型號,通常執行:
$ lspci | grep -i Ethernet 02:01.0 Ethernet controller: Intel Corporation 82545EM Gigabit Ethernet Controller (Copper) (rev 01)
或獲取 NIC 的更多詳細資訊:
$ sudo lshw -class network *-network description: Ethernet interface product: 82545EM Gigabit Ethernet Controller (Copper) vendor: Intel Corporation physical id: 1 bus info: pci@0000:02:01.0 logical name: eth0 version: 01 serial: 00:0c:29:25:4d:0e size: 1Gbit/s capacity: 1Gbit/s width: 64 bits clock: 66MHz capabilities: pm pcix bus_master cap_list rom ethernet physical logical tp 10bt 10bt-fd 100bt 100bt-fd 1000bt-fd autonegotiation configuration: autonegotiation=on broadcast=yes driver=e1000 driverversion=7.3.21-k8-NAPI duplex=full ip=192.168.5.143 latency=0 link=yes mingnt=255 multicast=yes port=twisted pair speed=1Gbit/s resources: irq:19 memory:fd5c0000-fd5dffff memory:fdff0000-fdffffff ioport:2000(size=64) memory:fd500000-fd50ffff
Grepping
dmesg
網路設備也可能有幫助:$ dmesg | grep eth0 [ 1.635942] e1000 0000:02:01.0 eth0: (PCI:66MHz:32-bit) 00:0c:29:25:4d:0e [ 1.635960] e1000 0000:02:01.0 eth0: Intel(R) PRO/1000 Network Connection [ 3.736090] e1000: eth0 NIC Link is Up 1000 Mbps Full Duplex, Flow Control: None [ 3.742639] 8021q: adding VLAN 0 to HW filter on device eth0
至於
dmidecode
,dmidecode -t baseboard
可能會顯示有關主機板中內置的 NIC 的資訊。PS 至於 Unix SE 問題,在處理硬體問題時,完整的
lscpi
輸出可能更有用。