Help with virtual optical device

Hi

My P6 server is with dual vio servers. From the below output we could see that cd devices(cd0 and cd1) has been mapped to the vio client named prdsapfi1.

When we execute "lsdev -Cc cdrom" in prdsapfi1 there are 2 cd devices named cd0 and cd1 showing up in available state.

 
===========================================================================
prdsapfi1:/ # lsdev -Cc cdrom
cd0 Available  Virtual SCSI Optical Served by VIO Server
cd1 Available  Virtual SCSI Optical Served by VIO Server
===========================================================================

My question is how to find out if cd0 showing up in prdsapfi1 has been coming from vioprd01p or vioprd01i?

 
===========================================================================
$ hostname
vioprd01p
===========================================================================
$ lsvopt | grep -i prdsapfi1
prdsapfi1_cdrom    No Media                                     n/a
===========================================================================
$ oem_setup_env
===========================================================================
# lsdev -Cc cdrom
cd1 Defined 05-08-01-0,0 16 Bit LVD SCSI DVD-RAM Drive
===========================================================================
===========================================================================
$ hostname
vioprd01i
===========================================================================
$ lsvopt | grep -i prdsapfi1
prdsapfi1_cdrom    AIX61.iso                              3967
===========================================================================
$ oem_setup_env
===========================================================================
# lsdev -Cc cdrom
cd0 Available 0F-08-00     SATA DVD-ROM Drive
cd1 Defined   05-08-01-0,0 16 Bit LVD SCSI DVD-RAM Drive
===========================================================================

You need to find the parent device of the CD drive (vscsi0), then find vscsi0's slot number, then query your HMC to find that slot number. I use a "lshwres" command in this example. You could also look at your VIO servers' properties and figure it out as well. The example below shows that cd0 is being supported by the VIO server "vio0".

hostname:/:$ lsdev -Cc cdrom
cd0 Available  Virtual SCSI Optical Served by VIO Server
hostname:/:$ lsdev -l cd0 -F parent
vscsi0
hostname:/:$ lscfg -vl vscsi0
  vscsi0           U8205.E6B.11111111-V1-C9-T1  Virtual SCSI Client Adapter

        Hardware Location Code......U8205.E6B.11111111-V1-C9-T1

hostname:/:$ /usr/bin/ssh -q hscroot@hmcconsole lshwres -r virtualio -m managed_system_name --rsubtype scsi --level lpar --filter "lpar_names=hostname"
lpar_name=hostname,lpar_id=1,slot_num=10,state=1,is_required=0,adapter_type=client,remote_lpar_id=40,remote_lpar_name=vio1,remote_slot_num=11
lpar_name=hostname,lpar_id=1,slot_num=9,state=1,is_required=0,adapter_type=client,remote_lpar_id=39,remote_lpar_name=vio0,remote_slot_num=11
hostname:/:$
2 Likes