From Pickwiki
Jump to navigationJump to search

Loading Old (Advanced Pick) Tapes on AIX 6.1 (Summary/Writeup from a U2 Users post by Kevin King)

Backstory: Our customer retired an Advanced Pick (AP) system sometime in the early 2000’s. There is a variety of tapes from this era that hold backups. We have been tasked with restoring as much of this data as we can for reporting.

What a challenge! After several hours of experimentation and failure it was discovered that the AP tapes have a variable block size which is incompatible with the standard drive settings for AIX. To correct this, and to enable a variable block size on tape read, the following commands were issued:

# export ODMDIR=/etc/objrepos
# chdev -l rmt1 -a block_size=0

With this setting, the following command was able to read the entire tape:

# export TAPE=/dev/rmt1.1
# tcopy /dev/rmt1.1

(Note that the tape drive for AIX is rmt1.1, not just rmt1. AIX separates physical drives into various logic units (rmt1.1, rmt1.2, etc) with different performance and characteristics for each. The rmt1.1 unit is a “non-rewind” unit, which means that when you use it, the tape doesn’t automatically rewind when you’re done. By contrast, using rmt1 (without the .1) says that after every operation, the tape will rewind and start over.)

Getting the account to be restored was an additional challenge. To do this, I logged into the data account and issued this command @ TCL:

:SETTAPE 1 /dev/rmt1.1 /dev/rmt1.2 16384

This says to configure device #1 with a no-rewind tape at /dev/rmt1.1 and a rewind device at /dev/rmt1.2 with a block size of 16384. (The header of the tape had a 4000 [hex]) on it which said that the tape was created with a block size of 16384.)

What’s unusual is that while this SETTAPE command has to be done inside of Unidata, the ACCT_RESTORE command is done at the # prompt. So from the BRAKE-DATA account, I shelled out using “!sh”, supered up with “sudo sh”, and did the following:

At the # prompt, I first created and navigated to a /ud/RESTORE directory, and issued this command:


This generated end of file errors repeatedly. At first, I was entering “F” here (followed by “C”) to have it interpret the EOF mark as the end of tape, but this seemed to cause the tape to rewind each time. So I tried pressing <cr> instead (a couple of times) and it began loading the accounts from the tape.

It’s loading all the accounts, even though I only want one of them, but this is better than not loading anything at all.