The goal here is to properly restore the images from a large group of archive tapes that have previous import activity.
We have a spreadsheet listing the backup id’s for archived projects that we wish to restore. The list also gives the media required to restore each of these backup id’s.
We will phase 1 import only those tapes on the list. All such tapes must be phase 1 imported prior to going to the phase 2 importing process. Those tapes are:
AP0030, AP0031, AP0033, AP0039, AP0040, AP0041, N00566, N00884, N00908, N01037, SDA001, SDA002, SDA003, SDA004, SDA005, SDA007, SDA008, SDA009, S00319, S00256, S00325,
After phase 1 importing is completed we could run the phase 2 import on all images previously imported in phase 1 but this method might create too much demand on the Netbackup production environment. Therefore, using the list provided by Vijay, we will perform phase 2 importing using the GUI. Alternately, we should be able to use the command line and a bidfile.
After phase 2 importing, the images are now a part of the Netbackup catalog and we can begin the restores. nbtap05 is being used as the landing zone for the restores. From nbntap05 Vijay can start the process of copying the restored data to the IP filer.
We will use the GUI to perform the restores. Following are the instructions to perform each restore.
Check with Vijay do we want to phase 1 import all other “SDA” tapes even if they are not on the list? At least we’ll know if their contents.
Explanation of Phase 1 and Phase 2 Importing:
The Phase 1 Process
This is performed first and must be done on all media concerned with the backups to be imported (particularly if the backups have spanned over several tapes). This phase recreates catalog entries for the backups by populating the media server’s Media Database (mediaDB) with the media IDs, and creating the header files of the backup images in the Image Database. After this phase is completed, the images may be browsed for selection for Phase 2 import.
The Phase 2 Process
This may be performed on all media involved in Phase 1, or if there is a selection of backup images desired for importing (after browsing), then the import may be done on the basis of backup IDs. This phase of the import creates the files file(s) of the backup images in the Image Database.
We will start by using the GUI to import the images from each tape that are available.
Once the backup IDs to import have been chosen, they can be listed in a file referred to as the “Bidfile” for use in Phase 2. If all the backup images (as given by Phase 1) are required for importing, there is no need for a Bidfile, and the Phase 2 will only require the command bpimport with no options.
Command for Phase 2With Bidfile (A filename provided that contains the image Id’s
/usr/openv/netbackup/bin/admincmd/bpimport -Bidfile -L Without Bidfile /usr/openv/netbackup/bin/admincmd/bpimport Our Situation Some of the tapes in the group we are processing have duplicated images and each image can only be imported once. When trying to phase 1 import an image that is already in the catalog you will receive a message similar to the following:
“WRN – Cannot import client braun, policy archive, and schedule FULL, copy 2: image exists and is not pre-import. Skipping this image.”
Whenever a backup image is skipped during phase 1 importing it is a bit concerning since we want to import all the necessary images.
Something seems to be wrong. We’d better check it out.
Because of the above warning message I thought a good analysis was in order. If the images on these tapes need to be imported into the catalog so that they can be restored, no image should be skipped.
Media SDA014 is used for the analysis.
What does the media database show? (Answer: Tape is blank)
Is the media in the Media database? We are going to check see if the media exists in the database and, if it does, see if there is any indication it has been imported. We are assuming the tape was originally imported phase 1 about a year ago and that the phase 1 import has long since expired. The tape when inventoried should show no images in the MM database or the EMM database.
We navigate to the Media Manager GUI to check the status of tape SDA014. It shows Media Status = active, Kilobytes = 0, Expiration date is blank, and Media Owner = NONE. Per NetBackup this tape is inventoried but is a blank tape.
The tape is blank in the media database but are there images on the tape? (Answer: There are 24 images on tape SDA014)
We read the tape and list it’s contents to see if the tape has images to import. This can be done by using the GUI by clicking Reports, Tape Reports, Tape Contents and specifying the Media ID. The report shows 49 files including a header file and 2 files for each of the 24 images.
Alternatedly the tape contents report can but run using the command line as follows:
./bpmedialist -q -mcontents -owner nbnbu01 -m SDA014 -l & (Physically Reads Media – Example shows how to send to Netbackup queue.)
There may be a syntax issue with the above. For now just use the GUI.
Phase 1 imported, ready for phase 2 import? (Answer: No. This tape is not ready for phase 2 import)
We use the Catalog GUI to list the backup images on SDA014 that are ready for phase 2 import. The GUI returns the following message.“INF – Found no images matching the selection criteria tha t were ready for phase 2 import.”
The command equivalent to the above is to run the below bpimport command to browse for backup images to be imported at Phase 2. This command is the same as attempting to display images ready for phase 2 import using the Catalog GUI. The output that was received from this command should match the GUI used in the previous step to list backup images ready for phase 2 import./usr/openv/netbackup/bin/admincmd/bpimport -PM -id SDA014 INF – unexpected return value from db_IMAGEreceive: allocation failed 10. Allocation failed 10 is due to a timeout reading the database. This usually happens when no images are found on the tape. So it is seems this command supports the output from the GUI that no images for phase 2 import were found.
Phase 2 Imported? (Answer: No. The media has not been phase 2 imported or else there would be images in the Netbackup catalog for this media.)
We use the GUI to run the Images on tape report. The report lists no media which confirms the tape has not been phase 2 imported.
We can run the following command to do the same. To check to see if there are any entries in the EMM database we can run the bpimmedia command.
./bpimmedia -l -tape -mediaid SDA014
Have any images already been imported through another media? (Answer: Yes. That is why we are getting the warning message.)
Here is the issue!!! 18 of the 24 images on tape have files located in “/usr/openv/netbackup/db/images///” and the files are dated approximately 1 year ago. Running the bpimagelist command shows that one of the images found on SDA014 has already been imported on media SDA005. So for the phase 1 importing of SDA media we can proceed with the understanding that the warning “… image exists and is not pre-import…” can be ignored for now.
ReferencesThe following link is an excellent susinct explanation of the phase 1 and phase 2 import processes. http://www.symantec.com/business/support/index?page=content&id=TECH94228