?
Solved

discovering tape usage by shell script on unix's box

Posted on 2003-03-13
6
Medium Priority
?
363 Views
Last Modified: 2010-04-03
Anyone knows how to do a shell script to tell how much space is used on a tape?
I tried to do with gawk but without success!
0
Comment
Question by:alester
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 2
6 Comments
 
LVL 4

Expert Comment

by:pratigan
ID: 8128124
Hello Alester,
www.Linux-Backup.net has lots of tips, scripts and useful information.
0
 

Author Comment

by:alester
ID: 8137479
Can you be more specific?
0
 
LVL 4

Accepted Solution

by:
pratigan earned 100 total points
ID: 8138113
I'm not sure exactly what admin rights you have, but here is a script that gives you tape usage info.
The following commands are pumped into nsradmin to obtain the raw tape drive usage data:

 show name; NSR operation; statistics
 print nsr device



The following nsradmin session shows the output of these commands:

$ /usr/sbin/nsradmin
Networker administration program.
Use the "help" command for help, "visual" for full-screen mode.
nsradmin> show name; NSR operation; statistics
nsradmin> print nsr device
name: /dev/rmt/0cbn;
NSR operation: Write;
  statistics: elapsed = 2460, errors = 0, last rate = 923,
  max clients = 4, file marks = 6, rewinds = 0,
  files skipped = 24, records skipped = 0,
  current file = 19, current record = 223,
  seek files = 2, seek records = 0,
  estimated kb = 0, amount kb = 23808,
  file amount kb = 23808, sessions = 4;
nsradmin>

Also, here is another link with a vast list of scripts to use.  There is one that will create a log report showing usage, etc.
0
Secure Your WordPress Site: 5 Essential Approaches

WordPress is the web's most popular CMS, but its dominance also makes it a target for attackers. Our eBook will show you how to:

Prevent costly exploits of core and plugin vulnerabilities
Repel automated attacks
Lock down your dashboard, secure your code, and protect your users

 
LVL 4

Expert Comment

by:pratigan
ID: 8138118
0
 

Author Comment

by:alester
ID: 8138671
Just for the shelldorado link You have answer the question. terrific! thank you!
0
 
LVL 4

Expert Comment

by:pratigan
ID: 8138702
your Welcome !!
0

Featured Post

Veeam Disaster Recovery in Microsoft Azure

Veeam PN for Microsoft Azure is a FREE solution designed to simplify and automate the setup of a DR site in Microsoft Azure using lightweight software-defined networking. It reduces the complexity of VPN deployments and is designed for businesses of ALL sizes.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Lets start to have a small explanation what is VAAI(vStorage API for Array Integration ) and what are the benefits using it. VAAI is an API framework in VMware that enable some Storage tasks. It first presented in ESXi 4.1, but only after 5.x sup…
This article aims to explain the working of CircularLogArchiver. This tool was designed to solve the buildup of log file in cases where systems do not support circular logging or where circular logging is not enabled
This video teaches viewers how to encrypt an external drive that requires a password to read and edit the drive. All tasks are done in Disk Utility. Plug in the external drive you wish to encrypt: Make sure all previous data on the drive has been …
This tutorial will walk an individual through the process of installing the necessary services and then configuring a Windows Server 2012 system as an iSCSI target. To install the necessary roles, go to Server Manager, and select Add Roles and Featu…
Suggested Courses

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question