June 17, 2008 at 9:54 am
I have a maintenance plan which does a full backup every day except Saturday and Sunday. Each backup has the name of the database and then the date of the backup appended to it every day. I have a maintenance cleanup task to search files in this folder with a .BAK extension and delete them if they are a week old. The maintenance plan is not deleting the backups at all. Is it because the date is appended to the backup? What do I need to do to delete the backup if it's older than a week?
Should I use backup set will expire within the full backup maintenance plan?
June 17, 2008 at 10:00 am
I forgot to add that I am using sql 2005.
June 17, 2008 at 10:33 am
Make sure that you have not include the “.” in the file extension.
Go thru this:
http://www.sqlservercentral.com/Forums/Topic361562-149-1.aspx
Manu
June 18, 2008 at 7:14 am
Can you use the Maintenance Cleanup Task?
June 18, 2008 at 7:19 am
Correct Erin, You Can use Cleanup task in SQL 2005. Make sure that .bak, .dif and .trn all should be seprate and schedule as the timeframe you required. 🙂
MCP, MCTS (GDBA/EDA)
June 18, 2008 at 2:36 pm
Wasn't there a problem with the Maint Plan Cleanup Task not working correctly ?? I think I heard that SP2 fixes that.
June 19, 2008 at 3:25 am
I have setup a new maintenance cleanup task in SP2 without any issues. The problem exists only while specifying the expiry of BackUp set while creating a new backup schedule job and not in the CleanUp task. Please check if the extension has been clearly specified alongwith the location/path of the backup files.
June 19, 2008 at 6:02 am
I removed the *.* Hopefully it will work now. If not I found a vb script that deletes old files. I also heard there was a problem with the maintenace plans. So, we'll see. THank you for your input.
Viewing 8 posts - 1 through 7 (of 7 total)
You must be logged in to reply to this topic. Login to reply