Operating System - HP-UX
1834544 Members
3049 Online
110069 Solutions
New Discussion

Can i use diskinfo to query the size of a tape loaded?

 
thijs lankhorst_1
Frequent Advisor

Can i use diskinfo to query the size of a tape loaded?

Hi, was wondering if anybody can tell me if we can use the following cmd to query the size of a tape that is loaded in the tape drive (/dev/rmt/0m)?
diskinfo -v /dev/rmt/0m
Or does this only give me info on the tapedrive in question?

6 REPLIES 6
Naveej.K.A
Honored Contributor

Re: Can i use diskinfo to query the size of a tape loaded?

hi,

hope

mt -f /dev/rmt/0m status

is the command you are looking for.

or you could do a

mt status

and it will query the default tape which is /dev/rmt/0m

hope this helps

with best wishes
Naveej
practice makes a man perfect!!!
thijs lankhorst_1
Frequent Advisor

Re: Can i use diskinfo to query the size of a tape loaded?

Thanks, can you explaint he output of this cmd in a bit more detail?

mt -f /dev/rmt/0m status
Drive: HP C5683A
Format: DDS-2 format
Status: [41112400] BOT online compression immediate-report-mode
File: 0
Block: 0

Namely the Status part: Does this show the size of the tape inh the tape drive?
thijs lankhorst_1
Frequent Advisor

Re: Can i use diskinfo to query the size of a tape loaded?

Naveej

Have you got a similar cmd for HPUX version 10.20 aswell, as it wont work on an older version. MT man pages wont give me a substitute.

Thanks thijs
Abdul Rahiman
Esteemed Contributor

Re: Can i use diskinfo to query the size of a tape loaded?

Are you looking to find out the size of an empty tape or the size of data on a used tape ?

No unix, no fun
thijs lankhorst_1
Frequent Advisor

Re: Can i use diskinfo to query the size of a tape loaded?

The size of a used tape.

We normally run a little script that looks at the data on the system minus the data that is excluded and this gives us the amount of compressed data that needs to be backed up. We use both 4 and 8gig tapes and if the data wont fit on a tape we need to ask the user what tape they use and this is a bit of a longwinded process so it would be handy to find out 1) what tape they use by issuing a cmd remotely (ie the size of the tape. 2) see how much data is on the tape that has been used and is still in the tapedrive. (know that this can be done by looking at the header info ie: fbackup -f (device) -V /file ) but somebody used a diskinfo on the device but I did not understand the output of this. I
thought that this might tell us info on the tape and was wondering if this is the case.
thijs lankhorst_1
Frequent Advisor

Re: Can i use diskinfo to query the size of a tape loaded?

Sorry abdul, both on an empty and on a used tape.