Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Is there a way to list the DB2 backups? All I can find is db2 list history backup all for <dbname> but I think you need to check through all of those to see if they've since been deleted. This seems like a simple question but I'm coming up blank.

Edit: I am using DB2 9.7 on AIX with TSM

share|improve this question
It is always a good practice to specify which platform your question pertains to. This may not only help get good answers more quickly, but help others search for answers for their situation. So often people forget that there are 3 different platform groups, with different implementations. – WarrenT Mar 13 '13 at 10:58

Yes, that is how you would query for all the backups that were taken by your database.

If you don't set AUTO_DEL_REC_OBJ = ON for your database configuration (as well as NUM_DB_BACKUPS and REC_HIS_RETENTN) then, yes, it will show backups that were deleted from disk.

You can also use the prune command to clean out backup entries (ans their linked backup files if AUTO_DEL_REC_OBJ is set to ON).

db2 prune history <timestamp> [with force option] and delete

you can also prune archived logs as well.

db2 prune logfile prior to <logfile name>
share|improve this answer

using this SQL you could query in an easy manner the history file

SELECT start_time, entry_status, operation, operationtype, backup_id,  
       devicetype, OBJECTTYPE 
 WHERE operation in ('B','R') 

if you're using tsm you could use

db2adutl query db DBNAME
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.