Tape Libraries and Drives
cancel
Showing results for 
Search instead for 
Did you mean: 

how to use streamer

SOLVED
Go to solution
rustam_2
Super Advisor

how to use streamer

Hi all,
We bought new streamer HP Storage Works Ultrium 9200 with 4 cassettes. Before i saved my backups on my disk arrays. And i dont know how to use streamer and record my database backups to my cassettes.
What kind of drivers i should install to my HP-UX 11.3?
Are there softs or utilities which manage streamer and all process?

regards,
Rustam
26 REPLIES
Sudhakar Subramaniam
Trusted Contributor

Re: how to use streamer

rustam_2
Super Advisor

Re: how to use streamer

Hi Sudhakar,
I read some article from link you showed me. But i even havent installed yet and cant run streamer. Does this streamer supports RMAN utility from Oracle DB?

Regards,
Rustam
Torsten.
Acclaimed Contributor

Re: how to use streamer

So you have an ultrium 920 tape drive?

You need to configure the "stape" driver into the kernel, then you can see the device as "CLAIMED" and you can use it (e.g. with tar/pax or a backup utility).

Hope this helps!
Regards
Torsten.

__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.

__________________________________________________
No support by private messages. Please ask the forum!

If you feel this was helpful please click the KUDOS! thumb below!   
rustam_2
Super Advisor

Re: how to use streamer

>>>So you have an ultrium 920 tape drive?

yes, i do.


>>>You need to configure the "stape" driver into the kernel, then you can see the device as "CLAIMED" and you can use it (e.g. with tar/pax or a backup utility).

I sign in to kweb, then went to kernel configuration. Found stape. Should i just do 'load configuration'? i brought screen from that page.

Regards,
Rustam
Torsten.
Acclaimed Contributor

Re: how to use streamer

Looks like the driver is already configured. Is the tape drive now CLAIMED in ioscan?

Now you can use it.

Hope this helps!
Regards
Torsten.

__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.

__________________________________________________
No support by private messages. Please ask the forum!

If you feel this was helpful please click the KUDOS! thumb below!   
rustam_2
Super Advisor

Re: how to use streamer

I checked through the command ioscan -f ( result in attached file). In column 'Class' i couldnt find 'type' and in column 'Driver' couldnt find 'stape'. So it means streamer doesnt installed properly? Though there is one strange value

unknown -1 0/0/2/0.0.1 UNCLAIMED UNKNOWN OO Device Driver

what is it?
Torsten.
Acclaimed Contributor

Re: how to use streamer

I don't know what server you have, but the UNKNOWN device is probably for USB mass storage (vMedia/USB DVD), so you need to include this driver to get it CLAIMED.

This is not related to the tape.

Hope this helps!
Regards
Torsten.

__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.

__________________________________________________
No support by private messages. Please ask the forum!

If you feel this was helpful please click the KUDOS! thumb below!   
rustam_2
Super Advisor

Re: how to use streamer

Hi Torsten,

My server is ia64 hp server rx6600. Yeah, you are right that on this server i have DVD Rom.
rustam_2
Super Advisor

Re: how to use streamer

Hi all,

I read HP manual 'hp ultrium drives
technical reference manual generation 2 SCSI and FC drives'. There are these steps:
1. Determining the SCSI ID
% /sbin/ioscan -f
but i couldnt find my tape in outlook. I thought maybe coz of long list i confused and didnt see tape. Then run
% /sbin/ioscan -f | grep "Ultrium"
anywhere didnt find driver for tape.
start step 2
2. If you cannot find the Ultrium drive, this may be because the kernel does not
contain the correct driver. Use the System Administration Manager (sam) to
add stape to the kernel:

To add stape to the kernel using sam:
1. % sam
2. Select the following:
Kernel Configuration
Drivers
3. Highlight the stape driver. If the driver has not been added to the kernel,
both Current State and Pending State will read â Outâ .
4. Select the following:
Actions
Add Driver to Kernel
The Pending State will now read â Inâ .
5. To add the new driver to the kernel, select:
Actions
Create a New Kernel
6. The stape driver will now be added to the kernel and then the system will
reboot.

In second item i dont see 'Driver' in Kernel Configuration. There are: Tunables, Moduls, Alarms and so on.. I went to Modules and found stape. Should i modify?
I didnt do other item from 2 until 6.
What should i do now? How can i load driver again?

Regards,
Rustam



Torsten.
Acclaimed Contributor
Solution

Re: how to use streamer

The ioscan you posted previously doesn't show the tape at all.


So you either have a problem with the drive itself (bad?) or the cables/terminators (bent pin?).

Check the hardware.

Hope this helps!
Regards
Torsten.

__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.

__________________________________________________
No support by private messages. Please ask the forum!

If you feel this was helpful please click the KUDOS! thumb below!   
rustam_2
Super Advisor

Re: how to use streamer

Hi Torsten,
You are right. Problem was with cable. Now ioscan -f shows me my tape
# ioscan -f | grep "Ultrium"
tape 0 0/2/1/0.0.0 stape CLAIMED DEVICE HP Ultrium 3-SCSI

So, is there book\manual how to use it? direct link to hp doc i mean.
I wanted to know how can i determine device file fr my tape? i check /dev and saw rmt and rtape, which one is mine?

I just rewind and check streamer and tape. I have card Ultrium 800 GB* data cartridges and found compatibility for them.
Tape drive model: Ultrium 920
read/write
(C7973A)
nl
write once/read
many (C7973W

Does it mean that i can write once to my cartridge? so i cant write some test files?

Regards,
Rustam

Torsten.
Acclaimed Contributor

Re: how to use streamer

Try

# ioscan -fnCtape

I don't think the media is a WORM, so you can write many times.


Consider to use tar, pax, cpio or something to backup your data (depends on what you want to backup).

Hope this helps!
Regards
Torsten.

__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.

__________________________________________________
No support by private messages. Please ask the forum!

If you feel this was helpful please click the KUDOS! thumb below!   
rustam_2
Super Advisor

Re: how to use streamer

Thanks Torsten, from both servers i got these results:

# ioscan -fnCtape
Class I H/W Path Driver S/W State H/W Type Description
=====================================================================
tape 0 0/2/1/0.0.0 stape CLAIMED DEVICE HP Ultrium 3-SCSI
/dev/rmt/0m /dev/rmt/c0t0d0BEST
/dev/rmt/0mb /dev/rmt/c0t0d0BESTb
/dev/rmt/0mn /dev/rmt/c0t0d0BESTn
/dev/rmt/0mnb /dev/rmt/c0t0d0BESTnb


there are 4 types 'devise file' such as 0m, 0mb, 0mn, 0mnb. Honestly i dont know differ between them. On manual is rmt/0mnb
2. Back up /stand/vmunix to tape:
% tar cvf /dev/rmt/0m ./stand/vmunix


>>I don't think the media is a WORM, so you >>can write many times.

how can i determine does mine WORM or doesnt? i have 10 Data cartridge - 'HP LTO3 Ultrium RW' * Assuming 2:1 Compression.
Does RW mean i can write and read many times?


>>Consider to use tar, pax, cpio or >>something to backup your data (depends on >>what you want to backup).

On my servers run Oracle Database and backups are created with Datapump Utility, not with RMAN. So i have dump files of my database, size app 30Gb (each file). During a day i have to write these dump files (3 dump files from 3 instance) to cartridge and all archive logs from one instance. So which way is secure, faster and easier to these tasks?
By the way, i have never worked with tapes\data cartridges, can i create several directories with data (automatically) or manually?

I also have HP LTO Ultrium Universal Cleaning Cartridge, havent known yet for what i can use it.


Regards,
Rustam


Torsten.
Acclaimed Contributor

Re: how to use streamer

Refer to your oracle documentation on how to backup date.


>> Does RW mean i can write and read many times?

Yes.


Regarding cleaning: Insert the cleaning tape if the "clean" LED is on.

Hope this helps!
Regards
Torsten.

__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.

__________________________________________________
No support by private messages. Please ask the forum!

If you feel this was helpful please click the KUDOS! thumb below!   
rustam_2
Super Advisor

Re: how to use streamer

Hi Torsten,

>>Refer to your oracle documentation on how >>to backup date.

I found out that tar and cpio will be ok for my data pumps.

>>Regarding cleaning: Insert the cleaning >>tape if the "clean" LED is on.

Ok, i got it. Thanks.


Look, i follow official documents and make some test backup and extract to/from cartridge.

1. i copy to /tmp test file and then write it to my data cartridge.

# tar cvf /dev/rmt/0mn /tmp/p8202632_10205_WINNT.zip
a /tmp/p8202632_10205_WINNT.zip 2119612 blocks

# mt status
Drive: HP Ultrium 3-SCSI
Format:
Status: [81114400] EOF online compression immediate-report-mode
File: 1
Block: -1
# cd /tmp
2. delete my test file p8202632_10205_WINNT.zip from /tmp. Then would copy from data cartridge to /tmp. But got error, why?
# tar xvf /dev/rmt/0mn
Tar: blocksize = 0; broken pipe?

what was wrong? How can i write and read from data cartridge then? Only way to write big file (which has 10-20-30Gb) to cartridge is to spread big file to multipal files?

Regards,
Rustam
Torsten.
Acclaimed Contributor

Re: how to use streamer

You used the norewind special file (0mn), so you need to rewind the tape or eject and load it again.
IMHO it should work then.

Hope this helps!
Regards
Torsten.

__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.

__________________________________________________
No support by private messages. Please ask the forum!

If you feel this was helpful please click the KUDOS! thumb below!   
Dennis Handly
Acclaimed Contributor

Re: how to use streamer

># mt status
>Status: [81114400] EOF online compression
>Then would copy from data cartridge to /tmp. ...
>what was wrong?

As mentioned by "mt status", you are at EOF and you need to rewind the tape so you see "BOT":
mt rew

>Only way to write big file (which has 10-20-30Gb) to cartridge is to spread big file to multiple files?

No, you can use pax(1) instead of tar.
rustam_2
Super Advisor

Re: how to use streamer

Torsten,
Thank you a lot. Finally i could write and then read my test file to\from cartridge.


But I still dont know, what differ between these files: /dev/rmt/0m /dev/rmt/0mb /dev/rmt/0mn /dev/rmt/0mnb. Couldnt find in official doc. I guess each of them have specific feature during write\read. So i dont know which is to good to use.

Thanks Dennis,
This evening i will read and then try to practice with pax utility.

Regards,
Rustam
Torsten.
Acclaimed Contributor

Re: how to use streamer

many related threads are there, for example:

http://h30499.www3.hp.com/t5/System-Administration/0m-vs-0mb/m-p/3098949#M146522


Hope this helps!
Regards
Torsten.

__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.

__________________________________________________
No support by private messages. Please ask the forum!

If you feel this was helpful please click the KUDOS! thumb below!   
Dennis Handly
Acclaimed Contributor

Re: how to use streamer

>I will read and then try to practice with pax utility.

You may need to install PAX-ENH on your 11.31 system.
If > 8 Gb, read about "-x pax" format.
If you want to read (or write) this on 11.23, you'll need to install PAX-ENH there too.
rustam_2
Super Advisor

Re: how to use streamer

Hi Torsten,

I read several topics about kind of tape h\w path.
So here 2 kind of them
No rewind ones:
/dev/rmt/0m
/dev/rmt/0mb(best)

and rewind ones:
/dev/rmt/0mn
/dev/rmt/0mnb(best)

and i didnt find more information but read that there are include hardware compress:
/dev/rmt/c0t0d0BEST
/dev/rmt/c0t0d0BESTb
/dev/rmt/c0t0d0BESTn
/dev/rmt/c0t0d0BESTnb

But what gives me if i use rewind one or norewind ones? I think to use h\w compress is best way, isnt?


1. I write 3 files to my tape
$mt status
Drive: HP Ultrium 3-SCSI
Format:
Status: [81114400] EOF online compression immediate-report-mode
File: 3
Block: -1

2. and went to begin of cartridge
$ mt -f /dev/rmt/0mn rewind

3. check the status and files in cartridge
$ mt status
Drive: HP Ultrium 3-SCSI
Format:
Status: [41114400] BOT online compression immediate-report-mode
File: 0
Block: 0

I think Files in status command means number of files in my cartridge. What does mean block ('-1' or '0')? How can i read files' name iand extract one them? Then went to end 3 file and continue write 4th file?

+ i didnt find docs about BOT and EOF status in mt status command.

Regards,
Rustam
Dennis Handly
Acclaimed Contributor

Re: how to use streamer

>But what gives me if I use rewind one or norewind ones?

If you don't use norewind, after you close the FD, the tape is rewound. That means you can't use "mt fsf 3" to position the tape.
WARNINGS: Only raw, no-rewind Berkeley-type devices should be specified.

>1. I write 3 files to my tape

How are you doing this?

>I think Files in status command means number of files in my cartridge.

It means filemarks.

>What does mean block ('-1' or '0')?

How many tape records from the last filemark.

>How can read files' name and extract one them?

You don't want to go there. If you try to append to your tape without a commercial or special purpose backup program, you risk overwriting everything.

If you have written a pax/tar/cpio archive, you can list and extract files.

>I didn't find docs about BOT and EOF status in mt status command.

Have you ever threaded reel to reel mag tape? :-)
mt(1) just assumes you know about status.
It does point to mt(7):
http://h20000.www2.hp.com/bc/docs/support/SupportManual/c02264803/c02264803.pdf

See comments about "struct mtget".
rustam_2
Super Advisor

Re: how to use streamer

Hi Dennis,
>> If you don't use norewind, after you close the FD, the tape is rewound. That means you can't use "mt fsf 3" to >>position the tape.
I got it now. I think it is not to important for me, will I use norewind or rewind option. I decided to use /dev/rmt/0mn, dont know will I have problems in the future coz of this or wont.

>>WARNINGS: Only raw, no-rewind Berkeley-type devices should be specified.
I dont know what did you mean.

>1. I write 3 files to my tape
>>How are you doing this?
tar cvf /dev/rmt/0mn

>>You don't want to go there. If you try to append to your tape without a commercial or special purpose backup >>program, you risk overwriting everything.
>>If you have written a pax/tar/cpio archive, you can list and extract files.

I dont use any freeware soft or commercial. I am gonna use just tar command to write\read files to\from tape.
I read several docs and decided to do following steps.
1.I will use device file /dev/rmt/0mn
2.Write files to tape with this command: tar cvf /dev/rmt/0mn can I write several files in one time?
3.For instance, I have 5 files in my tape.
4.I rewind cartridge to go begin of cartridge: mt â f /dev/rmt/0mn rewind
5.List files in tape step by step. I need to run 5 times to see all my 5 files.
tar -tvf /dev/rmt/0mn
6.Forward space count ï¬ les I run mt -f /dev/rmt/0mn fsf N (N=1,2,3..)
7.But I couldnt run Backward space count ï¬ les. tar -tvf /dev/rmt/0mn doesnt give me any error. But I was still in end of cartridge, why? I run 1-2 times tar -tvf /dev/rmt/0mn and thought that im in middle of cartridge. But when I run command tar -tvf /dev/rmt/0mn got error Tar: blocksize = 0; broken pipe?
8.I extract file from tape like this
tar -tvf /dev/rmt/0mn (which extracts all files)
tar -tvf /dev/rmt/0mn /path/my_file which extracts my_file
I want to know, how can I change restore path? For instance, I write file from /tmp/my_file and always restores to /tmp. How can I restore to another directory? Is there another command?

are these steps ok if I will make manual and give to use for implementing production environment?
Dennis Handly
Acclaimed Contributor

Re: how to use streamer

>>WARNINGS: Only raw, no-rewind Berkeley-type devices should be specified.

>I don't know what did you mean.

It means you must have a norewind device to use mt's positioning commands.

>tar cvf /dev/rmt/0mn

This only adds ONE tarfile to the tape.

>2. Write files to tape with this command: tar cvf /dev/rmt/0mn can I write several files in one time?

Yes, you can give tar lots of directories/files and it will write one tarfile to the tape.

>3. I have 5 files in my tape.

Again how did you do that? One tar or 5?

>5. List files in tape step by step. I need to run 5 times to see all my 5 files.

You are going to have no end of problems keeping track of N tars on the same tape and if you make a mistake, you have lost all of them.

This is what I recommend you not do.

>how can I change restore path? Is there another command?

You either tar it off with a relative path or you don't use tar to restore. You can use pax's -s option or gnu tar.

>are these steps ok if I will make manual and give to use for implementing production environment?

How are you going to handle tape positioning and not have an operator error and lose everything on your tape?