Operating System - HP-UX
1833873 Members
2392 Online
110063 Solutions
New Discussion

check if tape drive dirty ?

 
SOLVED
Go to solution
INCS Dept.
Frequent Advisor

check if tape drive dirty ?

Is there a command that makes it possible for me to check if the tape drive is dirty ? We are using DLT, DDS and ULtrium tape drives. No autochangers or libraries.

We are using a mix of omniback, cpio and fbackup. I know that omniback is a able to check if the tape drive is dirty, but do not know how this is done.

Any help will be appreciated.

INCS Dept.
9 REPLIES 9
Pete Randall
Outstanding Contributor

Re: check if tape drive dirty ?

Not even Omniback is actually capable of "checking the drive". Omniback comes with a preconfigured default uses parameter for the various types of drives. Once the drive has been used more than this number, OB tells you to clean it.

I know of no such command, regardless of backup methodology.


Pete

Pete
A. Clay Stephenson
Acclaimed Contributor
Solution

Re: check if tape drive dirty ?

Actually there is a programmatic way to determine this. The key is to do an ioctl() on the device in question. Man 7 mt and examine /usr/include/sys/mtio.h - this does assume you know C. There is an internal alert and medium log (internal to the drive itself) that this ioctl can query.

You MIGHT get lucky and be able to use mt -f /dev/rmt/0mnb status. Man mt for details. I don't have a dirty tape drive at the moment to test this but I suspect that the status message or one of the digits will change.
If it ain't broke, I can fix that.
Pete Randall
Outstanding Contributor

Re: check if tape drive dirty ?

Very interesting, Clay. Now if I can just figure out how to make a drive dirty, I can test it!


Pete

Pete

Re: check if tape drive dirty ?

What Pete says is pretty much correct for older tape drives (like older DDS), but newer drives normally support TapeAlert and thats how omniback figures out that a tape drive is dirty... you can download a utility to get tapealert info from here:

http://h20015.www2.hp.com/en/softwareDownloadIndex.jhtml?lc=en&softitem=co566en&sw_lang=en

Although I've never used it myself...

HTH

Duncan

I am an HPE Employee
Accept or Kudo
Cheryl Griffin
Honored Contributor

Re: check if tape drive dirty ?

I thought TapeTools did that as well but have not used these yet, so I am not speaking from experience with the product. http://h18006.www1.hp.com/products/storageworks/ltt/index.html
"Downtime is a Crime."
Eugeny Brychkov
Honored Contributor

Re: check if tape drive dirty ?

I agree with Cheryl. Generating support ticket for drive and looking into it will give you an idea of error rate and drive's health (at least, more info can be decoded/conclusion can be made only by an expert)
Eugeny
John Meissner
Esteemed Contributor

Re: check if tape drive dirty ?

and also this is a lot less complicated.....

when in doubt... run a cleaning tape through it

All paths lead to destiny
RolandH
Honored Contributor

Re: check if tape drive dirty ?

If you have installed Support Tools Manager than you can for DDS for DLT and other you must try.

1. login as root and start cstm
# cstm

2. at the cstm prompt enter map
cstm> map

# You will get somthing like this

Dev Last Last Op
Num Path Product Active Tool Status
=== ==================== ========================= =========== =============
1 system system () Information Successful
2 0 Bus Adapter (803)
3 0/0 PCI Bus Adapter (782)
4 0/0/0/0 Core PCI 100BT Interface
5 0/0/1/0 PCI SCSI Interface (10000
6 0/0/1/0.1.0 SCSI Tape (HPC1537A) Information Successful
7 0/0/1/1 PCI SCSI Interface (10000
8 0/0/1/1.2.0 SCSI Disk (HP36.4GMAN3367 Information Successful
9 0/0/2/0 PCI SCSI Interface (10000
10 0/0/2/0.2.0 SCSI Disk (HP36.4GMAN3367
11 0/0/2/1 PCI SCSI Interface (10000
12 0/0/2/1.2.0 SCSI Disk (HPDVD-ROM)
13 0/0/4/1 RS-232 Interface (103c104
14 0/1 PCI Bus Adapter (782)
15 0/2 PCI Bus Adapter (782)
16 0/3 PCI Bus Adapter (782)
17 0/4 PCI Bus Adapter (782)
18 0/5 PCI Bus Adapter (782)
19 0/8 PCI Bus Adapter (782)
20 0/8/0/0 PCI SCSI Interface (10000
21 0/8/0/0.0.0 SCSI Disk (HP73.4GST37340 Information Successful
22 0/8/0/0.1.0 SCSI Disk (HP73.4GST37340
23 0/8/0/0.2.0 SCSI Disk (HP73.4GST37340
.....

# You can see the number of the DevNum of the tape is 6

cstm> sel dev 6
cstm> info
cstm> il
Hardware path: 0/0/1/0.1.0


Device Qualifier: HPC1537A
Product ID: C1537A Hardware Path: 0/0/1/0.1.0
Device Type: SCSI Tape Logical Unit Number: 0
Vendor: HP Product Rev Level: L111
Firmware Revision: 4.123 Tape Load Count: 1
Correctable Errors: 0 Uncorrectable Errors: 0
Mfg Date Code: 9 Servo Revision: 14.2
Compression Status: Enabled Compression Ratio:
[instant] 3 : 1
[average] 1 : 1
Capacity [M Byte]: 3393220608
Drive Status: Good

# At last you can see the drive status

Normaly the DevNum not changed since you install new hardware so you can do direct from the root prompt.

# echo "sel dev x ;info; wait; il" |cstm ||grep -i "Drive Status:"

x = DevNum of your dds tape

Check out if it works for DLT, too

Regards
Roland

Sometimes you lose and sometimes the others win
Fred Martin_1
Valued Contributor

Re: check if tape drive dirty ?

DLT drives have a light, don't they? As for the other tapes, HP techs have told me that since you can't over-clean a DDS or DAT drive, you should clean it regularly whether it needs it or not - the cleaning cartridges are cheap insurance. In our case the DAT and DDS tape drives run about 20 hours a week, and we clean them weekly. We clean the DLT when the light comes on.
fmartin@applicatorssales.com