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 TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Automate Catalog Backup 1

Status
Not open for further replies.

AlexChao

Technical User
May 16, 2003
44
SG

I have a W2K3 NetBackup 5.1 MP1 backup server.

Previously, we enabled a catalog backup to be performed after each backup job. We found that the catalog backups in between backup jobs were affecting the backup window, so we choosed to perform the catalog backup twice manually in the morning during the office hours.

Like to check if there are scripts that could automatically trigger the catalog backup to run twice in the morning, each to a different cartridge?

 
do you have vault. if so, you can schedule it there.
 
You can set NetBackup up to backup the catalog after each scheduled session of backups.
 
Hi Stumpr, thanks for the link.

I suppose the way to achieve batch file triggered catalog backup is to include this one single line in the batch file:

bpsyncinfo -server MASTER -id1 A10001 -d1 hcart -id2 A10002 -d2 hcart

We use StorageTek 9840 tape drives (half-inch) so the media type/density must be 'hcart'.

Wonder if running the batch file just once would enable catalog backup to the two different cartridges (A10001 and A10002) defined concurrently, or, must I run the batch file twice at a specific interval?


 
To configure the catalog backup:
bpsyncinfo -server MASTER -id1 A10001 -d1 hcart -id2 A10002 -d2 hcart

The command above is used to define what tapes to use. It is not the command for running the catalog backup. The command populates the info that you normally see in the GUI for defining media to be used. The first time the catalog backup is run it will use the first tape defined. The second time a catalog backup is run it will use the second tape defined. The third time a catalog backup is used it will overwrite the first tape used and so on....Unless you are removing the tapes to send to an offsite location (highly recommended) the command will only need to be run once. Make sure that the media you select does not have a data header on it. Use vmquery -m <mediaID> and check the line called status, 0x0=data tape whil 0x1 = catalog tape. The tape also must be in the Netbackup volume pool.

Media type could possibly be hcart, hcart2, hcart3. It depends on how many 1/2 inch cartridge types you have in your environment and how you have them defined. But it will definitely be one of the three.

Now here is how to actually run a catalog backup:
To start the catalog backup from the command line, use the command:
#/usr/openv/netbackup/bin/admincmd/bpsyncinfo -M <master_server> -doBackup

The above procedure is similar for Windows NT/WIN2K except for the paths and the backslashes (\) to replace the fowardslashes.




Bob Stump
Just because the Veritas documentation states a certain thing does not make it a fact
 
Hi Stumpr,

bpsyncinfo -M <master_server> -doBackup

Works for our Windows NetBackup server !!

I created two daily batch jobs with the above command in the .bat file and scheduled them 30 minutes apart. Today is the second day and it runs fine.

Also, each run uses one of the two cartridges that we defined for catalog backup use.

Lastly, how to check and ensure that the catalog backup covers everything shown in "bpsyncinfo -U" ? I mean...just like the catalog backup we triggered manually from the NetBackup GUI ?



 

I suggest running bprecover with the -l option

bprecover -l -m <mediaID> -d hcart

Database Backup Information from 000201

Created: 06/03/05 05:57:20
Server: underdog
Block size: 32768

Path
----
IMAGE1 underdog:/usr/openv/netbackup/db
IMAGE2 underdog:/usr/openv/volmgr/database
IMAGE3 underdog:/usr/openv/var


Bob Stump
Just because the Veritas documentation states a certain thing does not make it a fact
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top