FW: How to determine what bus/Interrupt points to what device

From: Adams Kevin J (kevin.adams@PHS.COM)
Date: Mon Jan 06 2003 - 19:19:36 EST


In case anyone cares:

I figured out how to narrow this down to an adapter and a number of possible
devices.

Take the bus number (see original post below) "1000 00C2" and run:

# odmget -q value=0x100000c2 CuAt

CuAt:
        name = "pci2"
        attribute = "bus_id"
        value = "0x100000c2"
        type = "R"
        generic = ""
        rep = "n"
        nls_index = 0

Convert the interrupt level from hex to decimal: "0000 0034" = 52 and run:

# lsresource -al pci2 |grep -E "bus_intr_lvl.*52"
I scsi1 bus_intr_lvl 52 (A1)

Then get the adapter location code:

# lsdev -C|grep ^scsi1
scsi1 Available 30-68 Wide SCSI I/O Controller

Then get the devices based on the adapter's location code:

# lsdev -C|grep 30-68
scsi1 Available 30-68 Wide SCSI I/O Controller
hdisk0 Available 30-68-00-8,0 16 Bit SCSI Disk Drive
hdisk1 Available 30-68-00-9,0 16 Bit SCSI Disk Drive
hdisk2 Available 30-68-00-10,0 16 Bit SCSI Disk Drive
hdisk3 Available 30-68-00-11,0 16 Bit SCSI Disk Drive
hdisk4 Available 30-68-00-12,0 16 Bit SCSI Disk Drive
hdisk5 Available 30-68-00-13,0 16 Bit SCSI Disk Drive
ses0 Available 30-68-00-15,0 SCSI Enclosure Services Device

A quick program to do this:

# cat lsbusint
#!/bin/ksh
bus=$(odmget -q value=0x$1 CuAt|grep name|awk '{print $3}')
bus=$(echo $bus|tr '"' ' ')
int=$(echo 16i $2 p | dc)
adp=$(lsresource -al $bus|grep "bus_intr_lvl.*$int"|awk '{print $2}')
loc=$(lsdev -C|grep ^$adp|awk '{print $3}')
lsdev -C|grep $loc

Run as follows:

# lsbusint 100000c2 34
scsi1 Available 30-68 Wide SCSI I/O Controller
hdisk0 Available 30-68-00-8,0 16 Bit SCSI Disk Drive
hdisk1 Available 30-68-00-9,0 16 Bit SCSI Disk Drive
hdisk2 Available 30-68-00-10,0 16 Bit SCSI Disk Drive
hdisk3 Available 30-68-00-11,0 16 Bit SCSI Disk Drive
hdisk4 Available 30-68-00-12,0 16 Bit SCSI Disk Drive
hdisk5 Available 30-68-00-13,0 16 Bit SCSI Disk Drive
ses0 Available 30-68-00-15,0 SCSI Enclosure Services Device

I hope that made sense.

Kevin Adams
> -----Original Message-----
> From: Adams Kevin J
> Sent: Monday, January 06, 2003 12:50 PM
> To: aix-l@Princeton.EDU
> Subject: How to determine what bus/Interrupt points to what device
>
> Dear list:
>
> I'm getting INTRPPC_ERR errpt like the following, along with high winds
> and power fluctuations.
>
> How can I determine what device the detail data is pointing too. We had a
> backup job cancel with tape drive issues and I'm trying to see if that
> points to a tape drive.
>
> I know that lsattr -El ent2 would give me the intterupt for an ethernet
> adapter, but how can I get that for a tape drive or other device?
>
> Is there any way to map the detail data to a device?
>
> Thanks,
> Kevin Adams
>
>
> LABEL: INTRPPC_ERR
> IDENTIFIER: DADF69E4
>
> Date/Time: Mon Jan 6 09:11:05
> Sequence Number: 5468
> Machine Id: 000923724C00
> Node Id: raven
> Class: H
> Type: UNKN
> Resource Name: SYSINTR
> Resource Class: NONE
> Resource Type: NONE
> Location: NONE
>
> Description
> UNDETERMINED ERROR
>
> Probable Causes
> SYSTEM I/O BUS
> SOFTWARE PROGRAM
> ADAPTER
> DEVICE
>
> Recommended Actions
> PERFORM PROBLEM DETERMINATION PROCEDURES
>
> Detail Data
> BUS NUMBER
> 1000 00C2
> INTERRUPT LEVEL
> 0000 0034
>

This electronic message transmission, including any attachments, contains information from PacifiCare Health Systems Inc. which may be confidential or privileged. The information is intended to be for the use of the individual or entity named above. If you are not the intended recipient, be aware that any disclosure, copying, distribution or use of the contents of this information is prohibited.

If you have received this electronic transmission in error, please notify the sender immediately by a "reply to sender only" message and destroy all electronic and hard copies of the communication, including attachments.



This archive was generated by hypermail 2.1.7 : Wed Apr 09 2008 - 22:16:27 EDT