How to get the media id by filename
Created: 13 Aug 2012 | Updated: 07 Nov 2012 | 13 comments
This issue has been solved. See solution.
Hi all,
If I achive or backup a file, how to know the ID of the media which storage the file?
In STORNEXT, the command fsfileinfo can do this function. I don't know how to do in NBU.
Discussion Filed Under:
Comments 13 Comments • Jump to latest comment
Example:
bpimagelist -backupid womble_1344924835 -L
If you want to know the media id that holds a specific 'file' use the Backup, Archive & Restore section and restore the file, that will tell you which tape it's going to use.
You can then cancel the restore.
hi mph999:
Thank u.
Now I know I can get media id by backupid.
But the question is how to get backupid according filename.
Hi,
Sorry - I misread your question.
You would have to use cat_convert command on the backup id .f file in the catalog to check it has the file you want, then, get the media id like I showed.
You could do variations like using bplist command, but this wouldn't be too easy.
I don't know of a way of getting the media id directly APART from the BAR GUI, like ravaroo explained - you select the file in the Back/ Archive/ Restore GUI, start the restore, and see which tape it picks.
http://www.symantec.com/docs/DOC5146
Interestingly, I can see your requirement, but that is a question very very few people ask.
Martin
hi revaroo,
Thank you for your suggestion.
But I am sure I get what u meant.
Did you mean that if I want to know the mediaid according by specific filename I should use the Backup, Archive & Restore section?
What's Backup, Archive & Restore section?
Regards
Jun
Yes it's one way of doing it. Backup Archive & Restore is normally at the top of the GUI which you use for doing GUI manual backups, restores and archives. My suggestion was to start a restore of the 'file' you want to know what tape it's on. Cancel the restore as soon as you see the mount request for the media id (the tape)
I know you want the media id for a particular file, but you could try bpimagelist -preview with other paramaters to narrow down the search. This will give you the media ids for the criteria specified.
Patrick Whelan
Senior NetBackup Specialist
Useful option, didn't remember that.
But, this only gives the media for a given backupid unfortunately, effectivly, the easy way to do what I did above ...
Martin
hi revaroo,
Thank you for your explain.
I think this function is a normal function. When the tape is out-line and I want to retrieve the file to the disk, I need know in which tape the file is. Then I find the tape by the media id and put the tape in.
Regards.
Hi Patrick,
Thank u.
I will try your advice. But now I meet another problem.
I restarted the machine but failed.
It's the first time I reboot this machine. The installation was done by the other people.
I posted this problem. The site is https://www-secure.symantec.com/connect/forums/how-start-nbu-server-machine
Regards.
You don't need to know the tape number in order to do a restore.
Use the BAR section of the GUI, select the Client name that you need a file restore for, along with the policy type that was used for the backup. Expand directory tree until you find the filename that you need to restore.
If you want to be sure that the media is in the robot, you can click on Media Preview button to see all Media id's that were used in the backup set.
See NBU Backup, Archive, and Restore Getting Started Guide for more info.
PS: Please do not compare NetBackup with StorNext. They are totally different and have nothing in common.
Supporting Storage Foundation and VCS on Unix and Windows as well as NetBackup on Unix and Windows
Handy NBU Links
Hi Marianne,
Thank you for your clear explain.
I will try your suggestion after I start the machine.
regards.
Thumbs up to Marianne, I'd forgotten about the media preview button ...
Would you like to reply?
Login or Register to post your comment.