Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

DLT Roll to last session automatically!

Status
Not open for further replies.

jackps

Technical User
Jul 7, 2003
66
HK
Dear all
Just want to ask if there is any command that will fast forward to the last end session of a dlt tape?
Every day i got to type this command "tctl -f /dev/rmt1.1 fsf 18" where 18 is the number of session i want to fast forward and it is different on differ day, i want to see if this can be automated!

It will be great if a simple example script!

Thx alot

Jack
 
this question sound like one someone else asked just a few days ago. when i figure out something for that guy, you two can get together.

IBM Certified -- AIX 4.3 Obfuscation
 
Dear Yegolev
Could you please let me know when you had figure it out?

Thx alot for the help!!

jack
 
i am not able to find a DLT or help from man page, so here is the theory. you can execute 'tctl fsf 1' to move ahead one mark. if there is no next file mark, does this return something larger than zero? if so then it will be a simple conditional test.

you can test this by executing the command until it reaches the end, say you have moved to mark 18 and there are no more marks, then you run the command again. after that, execute 'print $?' to see the return code from the command. if it is not zero then it can be easily coded.

IBM Certified -- AIX 4.3 Obfuscation
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top