As part of my deployment plan, I copy a single file from one folder to another on the same box (it happens to be the BuildMaster server). It works fine. Subsequent executions, however, fail because BuildMaster can't get a handle on the file.
Cannot copy C:\folder1\foo.msi: The process cannot access the file 'C:\folder1\foo.msi' because it is being used by another process.
This is how I copy it in my plan:
The only way to get it to work on subsequent executions is to restart the BuildMaster service (which releases the handle on the file).