lshw 工具和返回的选项及其含义

lshw 工具和返回的选项及其含义

该工具lshw报告有关所有连接硬件的信息。

一些报告的选项和功能足够简单易懂,而另一些则不然。

找到的文档页面这里项目页面不要定义所有这些功能及其描述。

一个例子:

sudo lshw -C net

  *-usb:1                 
       description: Wireless interface
       product: USB2.0 WLAN
       vendor: ATHEROS
       physical id: 3
       bus info: usb@1:1.3
       logical name: wlan2
       version: 1.08
       serial: 12345
       capabilities: usb-2.00 ethernet physical wireless
       configuration: broadcast=yes driver=ath9k_htc driverversion=4.9.35-v7+ firmware=1.3 ip=192.168.2.254 link=yes maxpower=500mA multicast=yes speed=480Mbit/s wireless=IEEE 802.11
  *-usb:2
       description: Wireless interface
       product: 802.11n NIC
       vendor: Realtek
       physical id: 4
       bus info: usb@1:1.4
       logical name: wlan1
       version: 0.00
       serial: 123456
       capabilities: usb-2.00 ethernet physical wireless
       configuration: broadcast=yes driver=rtl8812au ip=192.168.1.254 maxpower=500mA multicast=yes speed=480Mbit/s wireless=IEEE 802.11AC
  *-network:0
       description: Wireless interface
       physical id: 2
       logical name: wlan0
       serial: b8:27:eb:b0:32:ae
       capabilities: ethernet physical wireless
       configuration: broadcast=yes driver=brcmfmac driverversion=7.45.41.26 firmware=01-df77e4a7 ip=192.168.8.254 multicast=yes wireless=IEEE 802.11
  *-network:1
       description: Ethernet interface
       physical id: 3
       logical name: eth0
       serial: b8:27:eb:e5:67:fb
       size: 100Mbit/s
       capacity: 100Mbit/s
       capabilities: ethernet physical tp mii 10bt 10bt-fd 100bt 100bt-fd autonegotiation
       configuration: autonegotiation=on broadcast=yes driver=smsc95xx driverversion=22-Aug-2005 duplex=full firmware=smsc95xx USB 2.0 Ethernet ip=192.168.0.254 link=yes multicast=yes port=MII speed=100Mbit/s

通过查看每个 NIC,我们可以推断出以下内容:

  1. 网卡有4个,其中2个是USB网卡

  2. 可以看到链接速度、物理地址、IP地址、逻辑名称、驱动程序名称等。

  3. 此外,如果适配器支持多播、广播等。

问题:

然而,像(可能还有其他)这样的选项link尚不清楚或无法理解,任何文档中也没有给出任何定义或描述。

这些配置/功能的描述记录在哪里?

答案1

找到了“能力”

命令:lshw -class network -json

    "capabilities" : {
      "pm" : "Power Management",
      "msi" : "Message Signalled Interrupts",
      "msix" : "MSI-X",
      "pciexpress" : "PCI Express",
      "bus_master" : "bus mastering",
      "cap_list" : "PCI capabilities listing",
      "rom" : "extension ROM",
      "ethernet" : true,
      "physical" : "Physical interface",
      "tp" : "twisted pair",
      "10bt-fd" : "10Mbit/s (full duplex)",
      "100bt-fd" : "100Mbit/s (full duplex)",
      "1000bt-fd" : "1Gbit/s (full duplex)",
      "autonegotiation" : "Auto-negotiation"}

相关内容