Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

Maintenance plans Expand / Collapse
Author
Message
Posted Sunday, June 16, 2013 11:16 PM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Friday, September 12, 2014 7:46 AM
Points: 190, Visits: 474
Hi all,

Five days back i created a maintenance plan to delete backup files older than 2 days and the plan is running every day. Today i saw the disk filling up . So i went to maintenance plan history and saw the history. In history it is showing the task is executed successfully. I went to jobs and saw the history there . The jobs are running fine.
I went to the location where where backups are taken. In this location all the backups are existing from the day i created the maintenance plan. I am unable figure it out..
Post #1463993
Posted Monday, June 17, 2013 2:29 AM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Friday, September 12, 2014 7:46 AM
Points: 190, Visits: 474
Any ideas....
Post #1464026
Posted Monday, June 17, 2013 2:32 AM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Tuesday, July 1, 2014 3:20 AM
Points: 196, Visits: 650
Perhaps you've checked the box "Create a sub-directory for each database" but in the cleanup task you didn't tick "Include first-level subfolders"?


Dird // Junior DBA
11g OCA
10.5 newbie
Post #1464027
Posted Monday, June 17, 2013 3:57 AM
SSC Rookie

SSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC Rookie

Group: General Forum Members
Last Login: Friday, July 11, 2014 10:10 AM
Points: 34, Visits: 148
Also if it's successfully running in BIDS but not in Jobs, you might want to check that the SQL Agent user has access rights to the folder you are deleting from.
Post #1464051
Posted Monday, June 17, 2013 4:38 AM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Tuesday, July 1, 2014 3:20 AM
Points: 196, Visits: 650
g_demetriou (6/17/2013)
you might want to check that the SQL Agent user has access rights to the folder you are deleting from.


Doesn't the "write" privilege on a folder affect both writing (creating backups) and deleting?



Dird // Junior DBA
11g OCA
10.5 newbie
Post #1464066
Posted Monday, June 17, 2013 4:44 AM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Friday, September 12, 2014 7:46 AM
Points: 190, Visits: 474
backup maintenance plan is executing without any failure and created sub folders for every database.
i checked include first level folders in clean up task. task is executing but older backups are not getting deleted.
Post #1464070
Posted Monday, June 17, 2013 5:15 AM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Tuesday, July 1, 2014 3:20 AM
Points: 196, Visits: 650
How many backup files do you have per database? You're not appending to the same file are you?
Is your File Extention "bak" instead of ".bak"? We use "bak" and the deletion works fine.



Dird // Junior DBA
11g OCA
10.5 newbie
Post #1464089
Posted Monday, June 17, 2013 7:36 AM
SSC Rookie

SSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC Rookie

Group: General Forum Members
Last Login: Friday, July 11, 2014 10:10 AM
Points: 34, Visits: 148
Dird (6/17/2013)
g_demetriou (6/17/2013)
you might want to check that the SQL Agent user has access rights to the folder you are deleting from.


Doesn't the "write" privilege on a folder affect both writing (creating backups) and deleting?


Normally, if the same user is being used for both backup and maintenance task. Also it's still possible to have advanced NTFS permissions to deny delete.

Might be worth ruling out by running in BIDS with a user who has delete permissions on the folder. Also could try running the xp_delete_file t-sql in management studio. Also as you mentioned, check the correct file extension has been used.
Post #1464141
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse