Useful Commands/Hardware: Difference between revisions
Jump to navigation
Jump to search
| (35 intermediate revisions by the same user not shown) | |||
| Line 1: | Line 1: | ||
== | == Banchmark == | ||
=== Test read performance of device on root mount point === | |||
< | <syntaxhighlight lang="bash"> | ||
# TODO | |||
sudo hdparm -tT $(df -h | awk '/\/$/ { print $1 }') | |||
</syntaxhighlight> | |||
<pre> | |||
/dev/md0: | |||
Timing cached reads: 4286 MB in 2.00 seconds = 2143.42 MB/sec | |||
Timing buffered disk reads: 574 MB in 3.00 seconds = 191.08 MB/sec | |||
</pre> | |||
== Read Hardware Information == | |||
=== List PCI Devices === | |||
<syntaxhighlight lang="bash"> | |||
lspci -k | lspci -k | ||
</ | </syntaxhighlight> | ||
< | <pre> | ||
06:00.1 Class 0200: Device 1077:8070 (rev 02) | |||
Subsystem: Device 7053:1002 | |||
Kernel driver in use: qede | |||
07:00.0 Class 0200: Device 8086:15e4 (rev 11) | |||
Subsystem: Device 8086:0000 | |||
Kernel driver in use: ixgbe | |||
</pre> | |||
Device ID could be search here: | |||
https://devicehunt.com/ | |||
=== Display Ethernet card information === | |||
<syntaxhighlight lang="bash"> | |||
ethtool -i eth4 | |||
</syntaxhighlight> | |||
<pre> | |||
driver: qede | |||
version: 8.33.9.0 [storm 8.33.8.0] | |||
firmware-version: mbi 8.30.29 [mfw 8.30.18.0] | |||
bus-info: 0000:06:00.0 | |||
supports-statistics: yes | |||
supports-test: yes | |||
supports-eeprom-access: yes | |||
supports-register-dump: yes | |||
supports-priv-flags: yes | |||
</pre> | |||
=== List USB Devices === | |||
<syntaxhighlight lang="bash"> | |||
lsusb | lsusb | ||
</ | </syntaxhighlight> | ||
<pre> | |||
|__usb1 1d6b:0002:0404 09 2.00 480MBit/s 0mA 1IF (Linux 4.4.59+ xhci-hcd xHCI Host Controller 0000:00:15.0) hub | |||
|__1-2 051d:0002:0106 00 1.10 1.5MBit/s 2mA 1IF (APC Back-UPS ES 550G FW:843.K4 .D USB FW:K4 4B1621P13816 ) | |||
|__1-4 f400:f400:0100 00 2.00 480MBit/s 200mA 1IF (Synology DiskStation 7F008C199FCA6095) | |||
|__usb2 1d6b:0003:0404 09 3.00 5000MBit/s 0mA 1IF (Linux 4.4.59+ xhci-hcd xHCI Host Controller 0000:00:15.0) hub | |||
|__2-1 0b95:1790:0100 ff 3.00 5000MBit/s 496mA 1IF (ASIX Elec. Corp. AX88179 00000000000008) | |||
</pre> | |||
=== List loaded kernel modules === | |||
< | <syntaxhighlight lang="bash"> | ||
lsmod | lsmod | ||
</ | </syntaxhighlight> | ||
== Module name of Ethernet Cards == | == Module name of Ethernet Cards == | ||
Linux built-in driver listed here: | |||
https://www.kernel.org/doc/html/latest/networking/device_drivers/ethernet/index.html | |||
Information of popular cards: | |||
{| class="wikitable" | {| class="wikitable" | ||
! Chipset || Speed || kernel<br/>module || bonding<br/>balance-alb || RoCE | ! Chipset || Speed || kernel<br/>module || bonding<br/>balance-alb || RoCE | ||
|- | |- | ||
| [https://docs.mellanox.com/display/MLNXENv493150/Introduction | | Mellanox ConnectX-3 Pro EN || 40G || [https://docs.mellanox.com/display/MLNXENv493150/Introduction mlx4] || || | ||
|- | |- | ||
| Intel X710 || | | Intel X710 || 40G || [https://www.kernel.org/doc/html/latest/networking/device_drivers/ethernet/intel/i40e.html i40e] || || | ||
|- | |- | ||
| Intel X540/X550 || 10G || ixgbe || || | | Intel X540/X550 || 10G || [https://www.kernel.org/doc/html/latest/networking/device_drivers/ethernet/intel/ixgbe.html ixgbe] || || | ||
|- | |- | ||
| Marvell QL41xx || 10G/25G || qede || || | | Marvell QLogic QL41xx || 10G/25G || qede || || | ||
|- | |- | ||
| Marvell AQtion | | Marvell AQtion AQC107 || 10G || [https://www.kernel.org/doc/html/latest/networking/device_drivers/ethernet/aquantia/atlantic.html atlantic] [https://github.com/Aquantia/AQtion/blob/master/README.txt atlantic(vendor)] || || | ||
|- | |- | ||
| Marvell AQtion | | Marvell AQtion AQC111U || 5G || [https://www.kernel.org/doc/html/latest/networking/device_drivers/ethernet/aquantia/atlantic.html atlantic] || || | ||
|- | |- | ||
| Realtek RTL8156 || 2.5G || r8152 || || | | Marvell AQtion AQC112U || 2.5G || [https://www.kernel.org/doc/html/latest/networking/device_drivers/ethernet/aquantia/atlantic.html atlantic] || || | ||
|- | |||
| Realtek RTL8156 || 2.5G || [https://www.realtek.com/en/component/zoo/category/network-interface-controllers-10-100-1000m-gigabit-ethernet-usb-3-0-software r8152(vendor)] [https://github.com/bb-qq/r8152 r8152(DSM)] || || | |||
|- | |- | ||
| Realtek RTL8153 || 1G || r8152 || || | | Realtek RTL8153 || 1G || r8152 || || | ||
|- | |- | ||
| ASIX AX88179 || 1G || ax88179_178a || X || | | ASIX AX88179 || 1G || [https://www.asix.com.tw/en/support/download ax88179_178a(vendor)] || X || | ||
|} | |||
Kernel drivers were placed in this directory '''/lib/modules'''. | |||
These commands can list ethernet drivers. | |||
{| class="wikitable" | |||
|- | |||
! Commands | |||
|- | |||
| | |||
<syntaxhighlight lang="bash"> | |||
# Goto ethernet directory than list. | |||
cd /lib/modules/$(uname -r)/kernel/drivers/net/ethernet | |||
find . -name '*.ko*' | |||
# Or list directly. | |||
find /lib/modules/$(uname -r)/kernel/drivers/net/ethernet -name '*.ko*' | |||
</syntaxhighlight> | |||
|- | |||
! Output | |||
|- | |||
| | |||
<pre> | |||
... | |||
./intel/i40e/i40e.ko.xz | |||
./intel/iavf/iavf.ko.xz | |||
./intel/ice/ice.ko.xz | |||
./intel/igb/igb.ko.xz | |||
./intel/igbvf/igbvf.ko.xz | |||
./intel/igc/igc.ko.xz | |||
./intel/ixgbe/ixgbe.ko.xz | |||
./intel/ixgbevf/ixgbevf.ko.xz | |||
./mellanox/mlx4/mlx4_core.ko.xz | |||
./mellanox/mlx4/mlx4_en.ko.xz | |||
./mellanox/mlx5/core/mlx5_core.ko.xz | |||
... | |||
</pre> | |||
|} | |} | ||
Latest revision as of 20:15, 3 April 2025
Banchmark
Test read performance of device on root mount point
# TODO
sudo hdparm -tT $(df -h | awk '/\/$/ { print $1 }')
/dev/md0: Timing cached reads: 4286 MB in 2.00 seconds = 2143.42 MB/sec Timing buffered disk reads: 574 MB in 3.00 seconds = 191.08 MB/sec
Read Hardware Information
List PCI Devices
lspci -k
06:00.1 Class 0200: Device 1077:8070 (rev 02)
Subsystem: Device 7053:1002
Kernel driver in use: qede
07:00.0 Class 0200: Device 8086:15e4 (rev 11)
Subsystem: Device 8086:0000
Kernel driver in use: ixgbe
Device ID could be search here:
Display Ethernet card information
ethtool -i eth4
driver: qede version: 8.33.9.0 [storm 8.33.8.0] firmware-version: mbi 8.30.29 [mfw 8.30.18.0] bus-info: 0000:06:00.0 supports-statistics: yes supports-test: yes supports-eeprom-access: yes supports-register-dump: yes supports-priv-flags: yes
List USB Devices
lsusb
|__usb1 1d6b:0002:0404 09 2.00 480MBit/s 0mA 1IF (Linux 4.4.59+ xhci-hcd xHCI Host Controller 0000:00:15.0) hub |__1-2 051d:0002:0106 00 1.10 1.5MBit/s 2mA 1IF (APC Back-UPS ES 550G FW:843.K4 .D USB FW:K4 4B1621P13816 ) |__1-4 f400:f400:0100 00 2.00 480MBit/s 200mA 1IF (Synology DiskStation 7F008C199FCA6095) |__usb2 1d6b:0003:0404 09 3.00 5000MBit/s 0mA 1IF (Linux 4.4.59+ xhci-hcd xHCI Host Controller 0000:00:15.0) hub |__2-1 0b95:1790:0100 ff 3.00 5000MBit/s 496mA 1IF (ASIX Elec. Corp. AX88179 00000000000008)
List loaded kernel modules
lsmod
Module name of Ethernet Cards
Linux built-in driver listed here:
https://www.kernel.org/doc/html/latest/networking/device_drivers/ethernet/index.html
Information of popular cards:
| Chipset | Speed | kernel module |
bonding balance-alb |
RoCE |
|---|---|---|---|---|
| Mellanox ConnectX-3 Pro EN | 40G | mlx4 | ||
| Intel X710 | 40G | i40e | ||
| Intel X540/X550 | 10G | ixgbe | ||
| Marvell QLogic QL41xx | 10G/25G | qede | ||
| Marvell AQtion AQC107 | 10G | atlantic atlantic(vendor) | ||
| Marvell AQtion AQC111U | 5G | atlantic | ||
| Marvell AQtion AQC112U | 2.5G | atlantic | ||
| Realtek RTL8156 | 2.5G | r8152(vendor) r8152(DSM) | ||
| Realtek RTL8153 | 1G | r8152 | ||
| ASIX AX88179 | 1G | ax88179_178a(vendor) | X |
Kernel drivers were placed in this directory /lib/modules.
These commands can list ethernet drivers.
| Commands |
|---|
# Goto ethernet directory than list.
cd /lib/modules/$(uname -r)/kernel/drivers/net/ethernet
find . -name '*.ko*'
# Or list directly.
find /lib/modules/$(uname -r)/kernel/drivers/net/ethernet -name '*.ko*'
|
| Output |
... ./intel/i40e/i40e.ko.xz ./intel/iavf/iavf.ko.xz ./intel/ice/ice.ko.xz ./intel/igb/igb.ko.xz ./intel/igbvf/igbvf.ko.xz ./intel/igc/igc.ko.xz ./intel/ixgbe/ixgbe.ko.xz ./intel/ixgbevf/ixgbevf.ko.xz ./mellanox/mlx4/mlx4_core.ko.xz ./mellanox/mlx4/mlx4_en.ko.xz ./mellanox/mlx5/core/mlx5_core.ko.xz ... |