Operating System - HP-UX
1826420 Members
3165 Online
109692 Solutions
New Discussion

Re: best way to duplicate a tape

 
Patti Johnson
Respected Contributor

best way to duplicate a tape

Hi,

I need to create two copies of a backup tape ( created using fbackup). This will be a cold backup performed when the application is down but I only have time to create one tape. I would like to duplicate the tape after it is created.
My server is an N4000 running HP-UX 11.0 with only have one tape drive.
I also have a test server with one tape drive (dlt8000, same as production).
Can I remote mount the tape from test to prod and do a tape to tape copy.

Any suggestions would be appreciated. I need to avoid an extended backup window.

Thanks,
Patti
14 REPLIES 14
Ranjith_5
Honored Contributor

Re: best way to duplicate a tape

Hi Johnson,

Not an immediate solution for your problem.

But you need to have a reassessment on the backup & data storage stratgy for at your place. Use Omniback / Netbackup which has got inbuilt media duplication option.

Alternate solutions for duplication could be something which is described in the url below.
http://www.storageheaven.com/products/duplication_datatape.asp

as far as cold backup is concerned, if you have a business copy on your storage. This will reduce your backup window up to 10 times. have a look at

http://h18006.www1.hp.com/products/storage/software/bizcopyeva/


Regards,
Syam
Mel Burslan
Honored Contributor

Re: best way to duplicate a tape

Unfortunately, tape drives can not be remote mounted using any OS provided utility as far as I know. And with a single tape drive on a given system, you can not accomplish what you are trying to do, i.e., duplication of a tape in a way of copy tape to disk and copy the image back to tape manner.

Depending on your backup software, you can back up your data to disk (I am sure whatever backup solution you are using, gives you an option to backup to disk) and then after your application data comes back alive and running, you can backup the disk backup image onto how ever many copies of tapes you want then delete it.

Quite inconvenient in my opinion as the restore will need two steps as well in the reverse direction, should you choose to restore one or few files.

If you are using dataprotector (formerly omniback), there was a utility to duplicate a tape drive called omnimcopy but this utility definitely needs two tape drives, and associated device licensing.

I know none of these are the answer you are looking for but these are the best that I can think of right now and hope it helps you to certain extent.
________________________________
UNIX because I majored in cryptology...
Patti Johnson
Respected Contributor

Re: best way to duplicate a tape

Not the answer I was hoping for.
My server has both a DVD and Tape drive, would it be possible to attach a tape drive where the DVD is now attached, then have two tape drives on one server.
If I had two tape drives could I copy a tape to a tape?

Here is what I have. No problem disconnecting the DVD on a test server and borrowing the production tape drive.

0/0/2/1.2.0 disk HP DVD-ROM 304
0/2/0/0.1.0 tape QUANTUM DLT7000

Patti
Ivan Ferreira
Honored Contributor

Re: best way to duplicate a tape

I think that you can use dd in combination with rsh/ssh to copy the tape to the remote system:

ssh remotehost dd if=/dev/rmt/0m | dd of=/dev/rmt/0m
Por que hacerlo dificil si es posible hacerlo facil? - Why do it the hard way, when you can do it the easy way?
Robert-Jan Goossens_1
Honored Contributor

Re: best way to duplicate a tape

Patti,

why not create two ignite tapes ?

Regards,
Robert-Jan
Bill Hassell
Honored Contributor

Re: best way to duplicate a tape

Even with two tape drives, duplication is not easily done in HP-UX. The reason is that the default read/write tasks are not record oriented, that is, each file (ordinary file or a tape device file) is seen as a string of characters. The length of a tape record must be specifically retrieved by the tape duplication program. fbackup (as well as other tape backup programs) use different record sizes and need a special program that can accurately duplicate the original format. You'll need to locate a Unix-specific program to do this.


Bill Hassell, sysadmin
Mel Burslan
Honored Contributor

Re: best way to duplicate a tape

technically you can copy the tape but there is no guaratee that the duplicate copy will work on the backup solution in the future.

And yes if you can unplugh your dvdrom (assuming external) and plug the tape drive in its place (again assuming they both have the same kind of SCSI interface, SE, FW or whatever) then use omnimcopy or equivalent andduplicate this tape. Again, if I were you I would not use a rudimentary solution like dd to duplicate the tape. Anectodal experience from some users may say it is working but as it is unsupported on most every backup solution, you are on your own if you run into any problems.

HTH
________________________________
UNIX because I majored in cryptology...
Andy Torres
Trusted Contributor

Re: best way to duplicate a tape

I have no way to test this, but I'll give it a shot with a remote dd copy.

dd if=[localtapedrive] | remsh [remoteserver] dd of=[remotetapedrive] bs=12000

You may also consider adding some disk and making a snap of your database files and back them up from snap at your leisure. Of course, nothing beats an enterprise-class backup utility like NetBackup or Data protector, given the cash.
TwoProc
Honored Contributor

Re: best way to duplicate a tape

Patti, the problem is that (from what I remember) fbackup doesn't store data in a "single" file, it's a bunch of files on that tape. So, I don't believe that a single "dd" wouldn't do it, and I don't know if a bunch of them one after another to/from the no-rewind devices would do it either, as I don't know if you'd get the marks between files correct or not(if that's what it uses).

If you could get both tape drives on the same system you could run both sets of backups in parallel.

A better strategy (short of DataProtector,Tivoli, etc) would be to use "ignite" for the root volumes(run it twice to make two copies if desired), and maybe tar or cpio for the other volumes. At that point on some servers I go ahead and "dd" the root volume drive (not the mirror) to tape also.
Then, you can "dd" the "dd" of the root drive, and also for the tar or cpio backups after the system is back up. You can then use ssh or remsh to copy the tape over to the other server's tape drive for these tapes through a pipe.

If tar and/or cpio are too slow for the non-root volumes backups you could still run fbackup for these in parallel to get your two copies - but that would require moving the tape drive to the first server (like you suggested as an option). Be aware that depending on the tape drive type, it may not be so great to put two tape drives on the same scsi chain (bus) for a lot of reasons.

If it's speed you're after, consider shutting down the system - breaking mirrors with "lvsplit", and restarting the database/applications. Then, take your sweet time doing your backups on your newly mounted split volume (from before the database was brought back up). Afterwards, unmount the split volumes from the server, and perform an "lvmerge" to bring the mirrored copies back in sync (database and apps are still up and running). Now, you're back up, and backup time is just a few minutes (should only be the time needed for a shutdown, an lvsplit and then a startup).

The ignite part of your backup for the root drives can certainly be run while your application/database is up, so that doesn't even add any down time to your backup window.

Of course, all of the above information is dependent on the fact that the drives for your applications/database are in a separate volume group and not in vg00. If they are all contained in vg00, this is still do-able, it's just a bit more work to make sure the ignite backup doesn't cover the non-root volumes, and then you know to be EXTRA CAREFUL with managing the lvsplits and merges (supposed to do that anyways, right).
We are the people our parents warned us about --Jimmy Buffett
Patti Johnson
Respected Contributor

Re: best way to duplicate a tape

You've given me another idea.
The reason for the cold backup was to get binaries for the DB and application. Since these haven't changed in monthes I could use last weeks cold backup - and a current hot backup of the db. I can duplicate that from disk copy.

Currently sitting in the path of hurricane Wilma, so we are sending copies of our backups to HP DR center and our out-of-state office.

I have two ignite tapes that were created after the last system change, so that's not an issue. Just need to get the latest copy of the data as well.

Thanks for all the help.
Patti
Fabio Ettore
Honored Contributor

Re: best way to duplicate a tape

Hi Patti and everybody,

just for a general info about copy of tapes:

in Data Protector there is a feature that permits the copy between media:

http://ovweb.external.hp.com/ovnsmdps/pdf/b6960-90106.pdf

Chapter 7
section Copying Media.

It is very interesting since in DP 5.5 it is possible to copy media even of a different technology (for example copy a DLT tape to a LTO tape).


Just for information that can be useful.


Best regards,
Fabio
WISH? IMPROVEMENT!
TwoProc
Honored Contributor

Re: best way to duplicate a tape

I like your last idea much better. Keep in mind that you can use the "dd" of the whole root disk as another backup method. I still do this from waaaay back when the place I worked didn't have the mirror software.

Ex:
dd if=/dev/rdsk/c0t6d0 of=/dev/rmt/0m bs=128k

Should take 1/2 hour to 2 hours (depending on the size of your disk).

Repeat for second copy.
We are the people our parents warned us about --Jimmy Buffett
A. Clay Stephenson
Acclaimed Contributor

Re: best way to duplicate a tape

Let me give you a Plan B since you mentioned Oracle. Shutdown the database and do an vxfs snapof= mount to create a snapshot of each filesystem. You can then restart the database and use fbackup to make a backup of the snapshot filesystems. Because vxfs snapshots do not copy all the data, the time required to do the snapshot is seconds so that your database downtime is measured in at most a few minutes. You can make multiple fbackups of the snapshots; if you have multiple tape drives then you can make multiple backups of the same snapshots simultaneously. Making copies of fbackup media is extremely difficult because of the variable blocking. Dd will not do the job. The snapshot method gives you the "warm, fuzzy" of a cold backup with almost all the uptime of a hotbackup.
If it ain't broke, I can fix that.
Patti Johnson
Respected Contributor

Re: best way to duplicate a tape

Unfortunately no mirroring software, only one tape drive. But I'm comfortable restoring from the hot backup if necessary.

Thanks for all the input.

Patti