?
Solved

housekeeping of the MSDB

Posted on 2012-04-10
6
Medium Priority
?
697 Views
Last Modified: 2012-08-17
Dear all,

AS the MSDB keep all the:

1)Backup and restore history,
2)SQL server agent job history.
3)Maintenance plan history.

and if we do not purge that regularily, the backup task will run longer and longer.

Any script to run on how many days of all of the above kept so that we know how many days only history we should keep?

DBA100.
0
Comment
Question by:marrowyung
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 
LVL 21

Assisted Solution

by:Jason Yousef, MS
Jason Yousef, MS earned 500 total points
ID: 37829754
0
 
LVL 28

Assisted Solution

by:Ryan McCauley
Ryan McCauley earned 500 total points
ID: 37830077
We do this cleanup as a step in our Maintenance plans, not as a separate job, but there's no reason you couldn't. Also, the amount of data generated is relatively small - while I'm not saying it's a good idea to never maintain it, it's small compared to the logging data generated elsewhere on your server, and I've never seen a case (even on servers that aren't maintained at all) of a large MSDB or out of control agent logs slowing down job execution.

Maybe I'm sheltered, but I wouldn't put too much stress on this - adding a "Maintenance Plan Cleanup" task, as mentioned above, should accomplish what you're looking for, even if you keep a few months worth of logs.
0
 
LVL 75

Assisted Solution

by:Anthony Perkins
Anthony Perkins earned 500 total points
ID: 37830649
1)  sp_delete_backuphistory
0
U.S. Department of Agriculture and Acronis Access

With the new era of mobile computing, smartphones and tablets, wireless communications and cloud services, the USDA sought to take advantage of a mobilized workforce and the blurring lines between personal and corporate computing resources.

 
LVL 43

Accepted Solution

by:
Eugene Z earned 500 total points
ID: 37830786
0
 
LVL 1

Author Comment

by:marrowyung
ID: 37850659
let me check and get back to you all soon.
0
 
LVL 1

Author Closing Comment

by:marrowyung
ID: 38307279
we don't consider this option right now ! it should be the housekeeping job for the rest of the DB instead of the MSDB one.
0

Featured Post

Free Backup Tool for VMware and Hyper-V

Restore full virtual machine or individual guest files from 19 common file systems directly from the backup file. Schedule VM backups with PowerShell scripts. Set desired time, lean back and let the script to notify you via email upon completion.  

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this article I will describe the Detach & Attach method as one possible migration process and I will add the extra tasks needed for an upgrade when and where is applied so it will cover all.
In this article I will describe the Backup & Restore method as one possible migration process and I will add the extra tasks needed for an upgrade when and where is applied so it will cover all.
This is my first video review of Microsoft Bookings, I will be doing a part two with a bit more information, but wanted to get this out to you folks.
This tutorial will teach you the special effect of super speed similar to the fictional character Wally West aka "The Flash" After Shake : http://www.videocopilot.net/presets/after_shake/ All lightning effects with instructions : http://www.mediaf…

765 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question