Operating System - HP-UX
1748232 Members
3333 Online
108759 Solutions
New Discussion

Re: disk path status check

 
rajesh73
Super Advisor

disk path status check

We need to createthe scirpt for disk path status check

 

 

/usr/bin/sudo /usr/sbin/ioscan -m dsf

 

below command show lot of disk path details

 

/dev/rdisk/disk29        /dev/rdsk/c6t0d7

                         /dev/rdsk/c8t0d7

                         /dev/rdsk/c12t0d7

                         /dev/rdsk/c10t0d7

 

i need to check the lun path status .

 

/usr/sbin/scsimgr -p lun_map -D /dev/rdisk/disk29

lunpath:10:32/0/2/0/0/0/0/4/0/0/0.0x00060e8005bf3333.0x5007000000000000:fibre_channel:ACTIVE:ACTIVE

lunpath:19:32/0/2/0/0/0/0/4/0/0/0.0x00060e8005bffb01.0x5007000000000000:fibre_channel:ACTIVE:ACTIVE

lunpath:38:33/0/2/0/0/0/0/4/0/0/0.0x00060e8005bffb14.0x5007000000000000:fibre_channel:ACTIVE:ACTIVE

lunpath:37:33/0/2/0/0/0/0/4/0/0/0.0x00060e8005bffb11.0x5007000000000000:fibre_channel:ACTIVE:ACTIVE

 

from the below output if any lunpath show like that (fibre_channel:NOT ACTIVE), we need to filter the two lunpath with raw disk name

 

/usr/sbin/scsimgr -p lun_map -D /dev/rdisk/disk29

lunpath:10:32/0/2/0/0/0/0/4/0/0/0.0x00060e8005bf3333.0x5007000000000000:fibre_channel:ACTIVE:ACTIVE

lunpath:19:32/0/2/0/0/0/0/4/0/0/0.0x00060e8005bffb01.0x5007000000000000:fibre_channel:ACTIVE:ACTIVE

lunpath:38:33/0/2/0/0/0/0/4/0/0/0.0x00060e8005bffb14.0x5007000000000000:fibre_channel:NOT ACTIVE

lunpath:37:33/0/2/0/0/0/0/4/0/0/0.0x00060e8005bffb11.0x5007000000000000:fibre_channel:NOT ACTIVE

 

 

please provide script

 

 

4 REPLIES 4
Dennis Handly
Acclaimed Contributor

Re: disk path status check

>we need to filter the two lunpath with raw disk name

 

Please indicate the exact output you want, given your example.

rajesh73
Super Advisor

Re: disk path status check

 need to check the lun path status .

 

 

from the below output if any lunpath show like that (fibre_channel:NOT ACTIVE), we need that disk name separtely

 

/usr/sbin/scsimgr -p lun_map -D /dev/rdisk/disk29

lunpath:10:32/0/2/0/0/0/0/4/0/0/0.0x00060e8005bf3333.0x5007000000000000:fibre_channel:ACTIVE:ACTIVE

lunpath:19:32/0/2/0/0/0/0/4/0/0/0.0x00060e8005bffb01.0x5007000000000000:fibre_channel:ACTIVE:ACTIVE

lunpath:38:33/0/2/0/0/0/0/4/0/0/0.0x00060e8005bffb14.0x5007000000000000:fibre_channel:NOT ACTIVE

lunpath:37:33/0/2/0/0/0/0/4/0/0/0.0x00060e8005bffb11.0x5007000000000000:fibre_channel:NOT ACTIVE

 

Dennis Handly
Acclaimed Contributor

Re: disk path status check

>we need that disk name separately

 

What's a "disk name"?

Due to your lack of specifications of the OUTPUT, I assume you just want these whole lines?

lunpath:38:33/0/2/0/0/0/0/4/0/0/0.0x00060e8005bffb14.0x5007000000000000:fibre_channel:NOT ACTIVE

lunpath:37:33/0/2/0/0/0/0/4/0/0/0.0x00060e8005bffb11.0x5007000000000000:fibre_channel:NOT ACTIVE

 

So you can just do:

/usr/sbin/scsimgr -p lun_map -D /dev/rdisk/disk29 | grep "NOT ACTIVE"

 

 

 

Torsten.
Acclaimed Contributor

Re: disk path status check

IMHO the following commands may help you:

# ioscan -P health -C disk

# ioscan -P health -C lunpath


If you see "limited" or "offline" you have a problem.
"online" or "standby" is OK.

Hope this helps!
Regards
Torsten.

__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.

__________________________________________________
No support by private messages. Please ask the forum!

If you feel this was helpful please click the KUDOS! thumb below!