How tdo clear up msdb

  • I used sqlmaint to scheduler backup jobs for Full database backup (ones per date), transaction backup (every 15 mintues) and differential backup (every 4 hours). I keeps 5 days dump file.

    I find out msdb is growth 2 MB per weekly.  I checked table backupmediafamily, It still have a lot of old dump information.  How can I celar those information from msdb?

    Thanks,

    KT

     

  • You can set the retention for the jobs in the history tables.

     

  •  

    Where you want to get rid of backup history not needed, the following is an alternate solution.

    USE msdb

    EXEC sp_delete_backuphistory '12/31/1999'

    This would delete the records older than the given date.

    Refer to BOL.

    However, Steve's approach is automated and would be preferred by me.

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply