Folder Not Accessible after Cancellation of Robocopy

I was planning for our server migration. One job is migrating the files to the new server. I used robocopy to copy the files. Half way through the process, I found something wrong and cancelled the robocopy process. One problem after the cancellation of robocopy is that I can no longer access the remote folder. I tried to use the Windows explorer to take the ownership, but failed. It’s probably because I am not the admin of the remote server.

If you’re thinking about purchasing a new GPU, we’d greatly appreciate it if you used our Amazon Associate links. The price you pay will be exactly the same, but Amazon provides us with a small commission for each purchase. It’s a simple way to support our site and helps us keep creating useful content for you. Recommended GPUs: RTX 5090, RTX 5080, and RTX 5070. #ad

I vaguely remembered that I had this problem before, but I could not find my note. I thought I used cacls to fix the problem, but I was not sure. I checked my old script and found a solution. Here are the steps to fix the problem.

  1. Elevate a command prompt. If you are not familiar with it, just search Command Prompt in the search box. Once you see the Command Prompt program, right click on it and select Run as administrator.
  2. Enter the following command and press Enter:
    cacls \\remote_server\remote_share\remote_dir /e /T /g username:F

 

Be the first to comment

Leave a Reply