Red Gate forums :: View topic - Network Copy Location keeps trying to copy to the old path
Return to www.red-gate.com RSS Feed Available

Search  | Usergroups |  Profile |  Messages |  Log in  Register 
Go to product documentation
SQL Backup 7
SQL Backup 7 forum

Network Copy Location keeps trying to copy to the old path

Search in SQL Backup 7 forum
Post new topic   Reply to topic
Jump to:  
Author Message
aultmike



Joined: 08 Jan 2010
Posts: 26
Location: Canton, OH

PostPosted: Tue Jul 16, 2013 6:41 pm    Post subject: Network Copy Location keeps trying to copy to the old path Reply with quote

We were using the Network Copy Location feature to copy backed up databases and transaction logs from our sql server to a NAS. The NAS died the other day and I changed the Folder in which I wanted these backups copied to. I have verified in the job settings in the SQL Backup program and I even verified that the path had been changed in the underlying sql job in sql server. However I'm still getting error emails that its failing to copy to the now nonexistant NAS. That was yesterday. Today when I checked it seems like it is starting to copy to the new location.

Any idea why it seems like it took 24hrs to make this change? Is there a service I should restart to make the change instantaneous? What will that do to database and transaction log backups in progress? Is there a separate service that handles the copying of files off of the server?

Thanks
Mike
Back to top
View user's profile Send private message
petey



Joined: 24 Apr 2005
Posts: 2301

PostPosted: Wed Jul 17, 2013 3:14 am    Post subject: Reply with quote

When a transaction log is marked to be copied, it is placed in a queue, and the copying performed by a separate process, but still running within the SQL Backup Agent service. The details of the target location is stored at that point in time.

When you changed the target location, it does not update the details of the files already in the queue that are still waiting to be copied. That is why SQL Backup attempts to copy the files to the previous target location. After 24 hours, SQL Backup gives up trying to copy the files.

To address this, you will need to update the target location details manually. You can find details of the files in the backupfiles_copylist table, in the SQL Backup local database (a SQL Server Compact database). You can use the sqbdata extended stored procedure to view the contents e.g.

Code:
EXEC master..sqbdata 'SELECT * FROM backupfiles_copylist'

Those entries with a status of 'P' (Pending) means they have not been copied yet, and copyto indicates the target location. Assuming that your previous location was 'g:\backups\copies\' and you now want to copy to 'h:\sqlbackup\copies\', you can use the REPLACE function via sqbdata to perform the change e.g.

Code:
sqbdata 'UPDATE backupfiles_copylist SET copyto = REPLACE(copyto, ''g:\backups\copies\'', ''h:\sqlbackup\copies\'') WHERE status = ''P'''

_________________
Peter Yeoh
SQL Backup Consultant Developer
Associate, Yohz Software
Beyond compression - SQL Backup goodies under the hood, updated for version 7
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Reply to topic All times are GMT + 1 Hour
Page 1 of 1

 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group