August 20, 2008 at 8:29 am
Hi,
I'm trying to setup backups to a network device (sp_addumpdevice) or UNC, whichever, on a nightly basis for multiple databases but also have those backups be deleted weekly.
Any idea of how do to this? I've been doing research and can't find a definitive way
August 20, 2008 at 8:32 am
i'd set up a maintenance plan instead and have it clean up after 7 days. you can also configure it to do a lot of the preventative maintenance that should be done anyway.
August 20, 2008 at 8:34 am
I couldnt' get my maintenance plan to let me backup to a network drive
August 20, 2008 at 8:43 am
what version of SQL are you running? just for kicks, i verified that i could do it in sql05 sp2...
when creating the backup task in your maintenance plan, where it asks you for the file location, don't hit the button that brings up a file location dialog... just type the unc into the text box.
August 20, 2008 at 9:18 am
sql 2000, sp4 ....
August 20, 2008 at 9:23 am
you should still be able to do it. a couple of things to look at:
1. does the user that you're running the backup as (if you're running as a job, check both the job owner and sql agent service account) have access to the unc path?
2. does it work if you map the drive first and then back up to the mapped drive?
3. if you click start|run and type the unc and hit enter, does it take you to the correct folder?
are you getting any error messages? if so, what are they?
edit: try running the backup in a query window... if it works there, then it's likely a security issue. are you running the sql agent service as a domain account or localsystem?
August 20, 2008 at 1:30 pm
Lenny (8/20/2008)
2. does it work if you map the drive first and then back up to the mapped drive?
You cannot backup to a mapped drive. You must specifiy a UNC path (at least for S2K), and as Lenny alluded to, your account running SQL or SQL Agent must have rights to the remote share.
-- You can't be late until you show up.
August 20, 2008 at 1:32 pm
yea this was one of those dumb moments..I forgot that yesterday the Maintenance plan didn't work before I changed the account to be a domain account..it works now..thanks all
August 20, 2008 at 1:34 pm
actually, what i was hoping to find out is whether or not it worked. if it did, that takes the troubleshooting down a whole different path.
it's SUPPOSED to work to a unc, but it's not, but if it works to a mapped drive (even though it's not supposed to) would mean something else entirely.
August 20, 2008 at 1:35 pm
awesome... never mind about my last post then... 😉
Viewing 10 posts - 1 through 9 (of 9 total)
You must be logged in to reply to this topic. Login to reply