SUMMARY: Determining tape used/remaining

From: Jeff Higgins <HIGGINS_at_aces.k12.ct.us>
Date: Mon, 16 Sep 1996 12:58:11 -0500 (EST)

Warm thanks to all who answered my question:

>Is there any way to find out how many blocks are used and remaining on my
>backup cassettes? We have a 1000/200 with a TLZ07 tape drive (4mm cassettes)

There apparently is no direct way to analyze this, but two people suggested:

#tapex -m

which reports out the number files, number or records per file, and size of
records, which is at least a start. I couldn't test this, not having tapex
installed nor a chance to locate and install it.

Juergen Bock <FDV20_24_at_dbf-s1.dbf.ddb.de> has a clever idea:

>one thing should work on all (unix) systems and for all drives:
>Place your tape at the end of your last file written to tape. Then use:
dd if=/dev/zero of=/dev/Yourtape bs=8192
>After the operation is completed, dd will tell you how many blocks it
>has written. Since your blocksize is 8192 you simply have to compute
>8192 * amount_of_blocks_written and you have the free space on you
>tape. Of course you can choose a different blocksize.
>The operation may take some time but it is reliable.

I tried this with two interesting results: 1) I made a typo in the "of" spec,
and filled my filesystem =:-O 2) I cleaned up my filesystem :) and sent it
off to the tape, where it looped for hours and ate CPU time. When I ^C'd, it
reported:
                         2572783+0 records in
                         2572227+0 records out

I think Mr. Bock is on to something, but I must need to refine my
implementation!


Thanks to:

Juergen Bock <FDV20_24_at_dbf-s1.dbf.ddb.de>
Dave Sill <de5_at_sws5.ctd.ornl.gov>
Lucio Chiappetti <lucio_at_ifctr.mi.cnr.it>
John Schaeffer <jsch_at_conncoll.edu>
Paul A Sand <pas_at_unh.edu>
Received on Mon Sep 16 1996 - 19:56:31 NZST

This archive was generated by hypermail 2.4.0 : Wed Nov 08 2023 - 11:53:47 NZDT