February 1, 2011 at 2:23 pm
I am getting backups of my databases fine, but I can't seem to set a rentention for maybe the laste 7 days? I don't need months of bak files. Also, can I set this to backup to a mapped drive? or even set to backup to two locations?
February 1, 2011 at 3:07 pm
The retention period is not used for file based backups. It was originally included to allow backups on devices (e.g. tape, optical, etc...) to be marked when the device itself could be overwritten.
To manage your backup files, you need to implement the maintanance cleanup task or build your own file delete utility.
You cannot backup to a mapped drive - since SQL Server is a service running on that system and doesn't know anything about mapped drives. You can, however, backup to UNC share as long as the service account running SQL Server has the appropriate rights to the share (read/write/etc...).
And yes, you can backup to multiple locations using the MIRROR option to the backup command. I would not recommend using this if you are planning on backing up across the network. This could end up causing your backups to fail - in both locations, since a failure on one fails the job and not just that copy.
For example, if you backup to a UNC path and a local drive. And, the UNC path has a network glitch that causes the backup to fail - the backup fails and not just the copy/mirror to the UNC path.
Jeffrey Williams
“We are all faced with a series of great opportunities brilliantly disguised as impossible situations.”
― Charles R. Swindoll
How to post questions to get better answers faster
Managing Transaction Logs
Viewing 2 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply