Wednesday 19 August 2015

How to Map ethx coming from which PCI slot

ethtool -i eth0

lspci -bv |grep -i Eth

dmidecode -t slot


[root@pratap ~]# ethtool -i eth0
driver: igb
version: 4.0.1-k1-1
firmware-version: 3.29, 0x027a8000
bus-info: 0000:04:00.0
[root@pratap ~]#




[root@pratap ~]# lspci -bv | grep -i Eth
03:00.0 Ethernet controller: Emulex Corporation OneConnect 10Gb NIC (be3) (rev 01)
03:00.1 Ethernet controller: Emulex Corporation OneConnect 10Gb NIC (be3) (rev 01)
04:00.0 Ethernet controller: Intel Corporation 82580 Gigabit Network Connection (rev 01)
        Subsystem: Hewlett-Packard Company NC365T 4-port Ethernet Server Adapter
04:00.1 Ethernet controller: Intel Corporation 82580 Gigabit Network Connection (rev 01)
        Subsystem: Hewlett-Packard Company NC365T 4-port Ethernet Server Adapter
04:00.2 Ethernet controller: Intel Corporation 82580 Gigabit Network Connection (rev 01)
        Subsystem: Hewlett-Packard Company NC365T 4-port Ethernet Server Adapter
04:00.3 Ethernet controller: Intel Corporation 82580 Gigabit Network Connection (rev 01)
        Subsystem: Hewlett-Packard Company NC365T 4-port Ethernet Server Adapter
0a:00.0 Ethernet controller: Intel Corporation 82580 Gigabit Network Connection (rev 01)
        Subsystem: Hewlett-Packard Company NC365T 4-port Ethernet Server Adapter
0a:00.1 Ethernet controller: Intel Corporation 82580 Gigabit Network Connection (rev 01)
        Subsystem: Hewlett-Packard Company NC365T 4-port Ethernet Server Adapter
0a:00.2 Ethernet controller: Intel Corporation 82580 Gigabit Network Connection (rev 01)
        Subsystem: Hewlett-Packard Company NC365T 4-port Ethernet Server Adapter
0a:00.3 Ethernet controller: Intel Corporation 82580 Gigabit Network Connection (rev 01)
        Subsystem: Hewlett-Packard Company NC365T 4-port Ethernet Server Adapter
[root@pratap ~]#

[root@pratap ~]# dmidecode -t slot
# dmidecode 2.12
SMBIOS 2.8 present.

Handle 0x0901, DMI type 9, 17 bytes
System Slot Information
        Designation: PCI-E Slot 1
        Type: x16 PCI Express 3
        Current Usage: In Use
        Length: Long
        Characteristics:
                3.3 V is provided
                PME signal is supported
Bus Address: 0000:04:00.0

Handle 0x0902, DMI type 9, 17 bytes
System Slot Information
        Designation: PCI-E Slot 2
        Type: x8 PCI Express 3
        Current Usage: Available
        Length: Long
        Characteristics:
                3.3 V is provided
                PME signal is supported
        Bus Address: 0000:07:00.0

Handle 0x0903, DMI type 9, 17 bytes
System Slot Information
        Designation: PCI-E Slot 3
        Type: x4 PCI Express 2 x8
        Current Usage: In Use
        Length: Short
        ID: 3
        Characteristics:
                3.3 V is provided
                PME signal is supported
        Bus Address: 0000:0a:00.0

Handle 0x0904, DMI type 9, 17 bytes
System Slot Information
        Designation: PCI-E Slot 4
        Type: x16 PCI Express 3
        Current Usage: Available
        Length: Long
        Characteristics:
                3.3 V is provided
                PME signal is supported
        Bus Address: 0000:21:00.0

Handle 0x0905, DMI type 9, 17 bytes
System Slot Information
        Designation: PCI-E Slot 5
        Type: x8 PCI Express 3
        Current Usage: In Use
        Length: Long
        Characteristics:
                3.3 V is provided
                PME signal is supported
        Bus Address: 0000:24:00.0

Handle 0x0906, DMI type 9, 17 bytes
System Slot Information
        Designation: PCI-E Slot 6
        Type: x8 PCI Express 3
        Current Usage: In Use
        Length: Long
        Characteristics:
                3.3 V is provided
                PME signal is supported
        Bus Address: 0000:27:00.0

[root@pratap ~