• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 620
  • Last Modified:

Cannot copy backup. The process cannot access the file because another process has locked a portion of the file.

I have a .BAK file that I like to copy to another server. The .BAK file is 26GB. When I copy it, I receive the following error and the file is not copied:

Cannot copy backup. The process cannot access the file because another process has locked a portion of the file.

Any suggestions on how to copy the file? I am using SQL Server 2005 and Windows 2003 Server.

Thanks
0
gtrapp
Asked:
gtrapp
1 Solution
 
Raja Jegan RSQL Server DBA & Architect, EE Solution GuideCommented:
If it is a backup set, check whether any backup or restore operations are going on from that backup set ( Backup set holds multiple backups).
Or else check for any other Windows process like De fragmentation running on the disk which might lock your backup file.
0
 
mds-cosCommented:
Sometimes Windows gets confused.  It happens much less frequently nowdays than it did back in 3.5 and 4.0 days....but still does on occasion.

After checking rrjegan17 suggestion, if you find there are not current processes running that are keeping the file locked, reboot the server and try your copy again.
0
 
gtrappAuthor Commented:
Its not a backup set. I selected to overwrite all existing backup sets.

I can not find a defrag process running on the server, although there is a nightly process on the server for defragging.

I will try rebooting the server.
0
Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

 
Raja Jegan RSQL Server DBA & Architect, EE Solution GuideCommented:
>> Its not a backup set. I selected to overwrite all existing backup sets.

If so, then check whether you have a backup job scheduled in your maintenance plan accessing this file..
0
 
gtrappAuthor Commented:
I ran the backup manually.
0
 
Raja Jegan RSQL Server DBA & Architect, EE Solution GuideCommented:
Ok.. Just kill explorer.exe and start a new explorer.exe from your Task manager instead of a system restart..
0
 
Máté FarkasDatabase Developer and AdministratorCommented:
First, you should use OpenedFilesView to find what is locking the backup file.
0
 
gtrappAuthor Commented:
I have already look there, nothing is locking the file.
0
 
gtrappAuthor Commented:
I have killed EXPLORER.EXE and started a new process. I am trying the copying again.
0
 
gtrappAuthor Commented:
I rebooted the server and that fixed the problem. I was able to copy the file. There were no process using the file.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Cloud Class® Course: C++ 11 Fundamentals

This course will introduce you to C++ 11 and teach you about syntax fundamentals.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now