Asset ID: |
1-71-1619127.1 |
Update Date: | 2017-09-26 |
Keywords: | |
Solution Type
Technical Instruction Sure
Solution
1619127.1
:
SL24 - How to Scan SCSI Tape devices using Linux OS
Related Items |
- Sun StorageTek SL24 Tape Autoloader
|
Related Categories |
- PLA-Support>Sun Systems>TAPE>Tape Hardware>SN-TP: OEM Drive and Library
|
Basic Linux Commands to scan SCSI tape devices.
In this Document
Created from <SR 3-8342266001>
Applies to:
Sun StorageTek SL24 Tape Autoloader - Version All Versions and later
Linux x86
Goal
Basic linux commands to scan for scsi tape devices.
Solution
[root@gsoadma ~]# cat /proc/scsi/scsi
Attached devices:
Host: scsi0 Channel: 00 Id: 00 Lun: 00
Vendor: HP Model: P410i Rev: 3.66
Type: RAID ANSI SCSI revision: 05
Host: scsi0 Channel: 00 Id: 00 Lun: 01
Vendor: HP Model: LOGICAL VOLUME Rev: 3.66
Type: Direct-Access ANSI SCSI revision: 05
Host: scsi0 Channel: 00 Id: 00 Lun: 02
Vendor: HP Model: LOGICAL VOLUME Rev: 3.66
Type: Direct-Access ANSI SCSI revision: 05
Host: scsi1 Channel: 00 Id: 04 Lun: 00
Vendor: HP Model: Ultrium 3-SCSI Rev: G63W
Type: Sequential-Access ANSI SCSI revision: 03
Host: scsi1 Channel: 00 Id: 04 Lun: 01
Vendor: HP Model: MSL G3 Series Rev: E.80
Type: Medium Changer ANSI SCSI revision: 05
[root@gsoadma ~]# sg_map -x
/dev/sg0 0 0 0 0 12
/dev/sg1 0 0 0 1 0 /dev/sda
/dev/sg2 0 0 0 2 0 /dev/sdb
/dev/sg3 1 0 4 0 1 /dev/nst0
/dev/sg4 1 0 4 1 8
[root@gsoadma ~]# lsmod | egrep -i "st|sg"
xt_state 1492 2
nf_conntrack 79453 2 nf_conntrack_ipv6,xt_state
osst 54494 0
st 38660 0
sg 30124 0
[root@gsoadma ~]# mtx inquiry
Product Type: Medium Changer
Vendor ID: 'HP '
Product ID: 'MSL G3 Series '
Revision: 'E.80'
Attached Changer API: No
[root@gsoadma ~]# mtx status
RequestSense (0x03) failed
mtx: Request Sense: Long Report=yes
mtx: Request Sense: Valid Residual=no
mtx: Request Sense: Error Code=70 (Current)
mtx: Request Sense: Sense Key=Unit Attention
mtx: Request Sense: FileMark=no
mtx: Request Sense: EOM=no
mtx: Request Sense: ILI=no
mtx: Request Sense: Additional Sense Code = 28
mtx: Request Sense: Additional Sense Qualifier = 00
mtx: Request Sense: BPV=no
mtx: Request Sense: Error in CDB=no
mtx: Request Sense: SKSV=no
Mode sense (0x1A) for Page 0x1D failed
Storage Changer /dev/changer:1 Drives, 24 Slots ( 0 Import/Export )
Data Transfer Element 0:Full (Storage Element 1 Loaded)
Storage Element 1:Empty
Storage Element 2:Full
Storage Element 3:Full
Storage Element 4:Full
Storage Element 5:Full
Storage Element 6:Full
Storage Element 7:Full
Storage Element 8:Full
Storage Element 9:Full
Storage Element 10:Full
Storage Element 11:Full
Storage Element 12:Full
Storage Element 13:Full
Storage Element 14:Full
Storage Element 15:Full
Storage Element 16:Full
Storage Element 17:Full
Storage Element 18:Full
Storage Element 19:Full
Storage Element 20:Full
Storage Element 21:Full
Storage Element 22:Full
Storage Element 23:Full
Storage Element 24:Full
[root@gsoadma tmp]# tar -czf /dev/nst0 /tmp/jaya
tar: Removing leading `/' from member names
[root@gsoadma tmp]# tar xzf /dev/nst0
gzip: stdin: unexpected end of file <<<<<<<<<<< discount this line due to tape is not "SCRATCH" from NBU
tar: Child returned status 1
tar: Error is not recoverable: exiting now
[root@gsoadma tmp]# mt -f /dev/st0 status
SCSI 2 tape drive:
File number=1, block number=-1, partition=0.
Tape block size 0 bytes. Density code 0x44 (LTO-3).
Soft error count since last status=0
General status bits on (9010000):
EOD ONLINE IM_REP_EN
[root@gsoadma tmp]# mt -f /dev/nst0 status
SCSI 2 tape drive:
File number=0, block number=0, partition=0.
Tape block size 0 bytes. Density code 0x44 (LTO-3).
Soft error count since last status=0
General status bits on (41010000):
BOT ONLINE IM_REP_EN
[root@gsoadma tmp]# cd /usr/openv/volmgr/bin
[root@gsoadma bin]# ./scan
************************************************************
*********************** SDT_TAPE ************************
*********************** SDT_CHANGER ************************
************************************************************
------------------------------------------------------------
Device Name : "/dev/sg4"
Passthru Name: "/dev/sg4"
Volume Header: ""
Port: -1; Bus: -1; Target: -1; LUN: -1
Inquiry : "HP MSL G3 Series E.80"
Vendor ID : "HP "
Product ID : "MSL G3 Series "
Product Rev: "E.80"
Serial Number: "1204BRZ00R"
WWN : ""
WWN Id Type : 0
Device Identifier: "HP MSL G3 Series 1204BRZ00R"
Device Type : SDT_CHANGER
NetBackup Robot Type: 8
Removable : Yes
Device Supports: SCSI-5
Number of Drives : 1
Number of Slots : 24
Number of Media Access Ports: 0
Drive 1 Serial Number : "HUE1222JW8"
Flags : 0x0
Reason: 0x0
------------------------------------------------------------
Device Name : "/dev/nst0"
Passthru Name: "/dev/sg3"
Volume Header: ""
Port: -1; Bus: -1; Target: -1; LUN: -1
Inquiry : "HP Ultrium 3-SCSI G63W"
Vendor ID : "HP "
Product ID : "Ultrium 3-SCSI "
Product Rev: "G63W"
Serial Number: "HUE1222JW8"
WWN : ""
WWN Id Type : 0
Device Identifier: ""
Device Type : SDT_TAPE
NetBackup Drive Type: 16
Removable : Yes
Device Supports: SCSI-3
Flags : 0x0
Reason: 0x0
Attachments
This solution has no attachment