Comments
Sort by recent activity
Thanks. In this application the db to which I want to ship the logs is a testing and development db that really only needs to be kept up to date nightly. It seems like it would work quite nicely to just queue up the logs and then run a job to integrate them into the target db once a day.
In any event, that article covers all the bases quite completely, thanks. / comments
Thanks. In this application the db to which I want to ship the logs is a testing and development db that really only needs to be kept up to date nightly. It seems like it would work quite nicely to...
:oops:
I found a log I could look at. It demonstrates that one should always check the easy stuff first. The db's in question have been growing and the destination volume for me test restores didn't have enough room to take the restores anymore.
Pesky Thurman Unit.... / comments
:oops:
I found a log I could look at. It demonstrates that one should always check the easy stuff first. The db's in question have been growing and the destination volume for me test restores didn...
... EXEC master..sqlbackup '-sql "RESTORE DATABASE pubs_copy FROM DISK = [e:\backups\*.sqb] SOURCE = [pubs] LATEST_ALL"'
Perfect. That's exactly what I needed.
Now, let me complicate things a bit. I do a similar thing to restore backups to a test server once a week to run DBCC CHECKDB on them and get another level of certainty as to the goodness of the backups. In that case the .sqb file is on an archive volume located on a NAS in another physical location on a fiber connection. Right now, I manually copy the .sqb to the test server to do the restore as I can't see the archive location for restore purposes; I can't see a way to make it appear 'local' to the restore command.
I could do something tricky with PowerShell to get the file to a location where I could see it, but if there's a better way I'd be happy to hear about it! / comments
...EXEC master..sqlbackup '-sql "RESTORE DATABASE pubs_copy FROM DISK = [e:\backups\*.sqb] SOURCE = [pubs] LATEST_ALL"'
Perfect. That's exactly what I needed.
Now, let me complica...
So if the EXEC statement looks like:
EXECUTE master..sqlbackup '-SQL "BACKUP DATABASE [RTPOne] TO DISK = ''S:\Backup\RTP-Data\<AUTO>.sqb'' WITH ERASEFILES = 7,
ERASEFILES_REMOTE = 15,
FILEOPTIONS = 4,
MAILTO = ''isadmin@jacksonhole.com'',
DISKRETRYINTERVAL = 30,
DISKRETRYCOUNT = 10,
COMPRESSION = 4,
COPYTO = ''\\n-cali\sqlbackups\RTPSQL\DataFileBackups\RTPONE'',
THREADCOUNT = 15,
VERIFY"', @exitcode OUT, @sqlerrorcode OUT
then all I need is more COPYTO's and the same ERASEFILES REMOTE will apply? / comments
So if the EXEC statement looks like:
EXECUTE master..sqlbackup '-SQL "BACKUP DATABASE [RTPOne] TO DISK = ''S:\Backup\RTP-Data\<AUTO>.sqb'' WITH ERASEFILES = 7,
ERASEFILES_REMOTE = 15,
FILEOPTIONS =...