File or Folder recovery when you get path length errors copying.

by John C. Wray III Wednesday, October 15, 2014 7:12 AM

Folder Recovery when you run into a path length error.

When recovering files and folders normally you can just use the windows previous versions and copy out of a previous version. If the source you are copying from has so many folders that the path length ends up exceeding 255 characters you will get an error message during the copy and it will abort. Robocopy is not affected by that restriction and can be used to recover in this scenario.

Here are steps you would perform to recover from a previous snapshot.

  1.   Create a flexclone of the volume mounting a snapshot you know has the data missing
  2.   Create a temp share to use as a source for your robocopy
  3.  Run a robocopy to the original destination
  4.   Verify the folder and file count look correct
  5. Remove the temp share
  6. Remove the flexclone

This doc uses the NetApp OnCommand System Manager (3.1) to accomplish this. This can also be done from the CLI.

Mounting the Flexclone

Open System Manager, double click on the controller that owns the volume you want to recover data from/to. Expand Storage, then Volumes. You should see your volume listed.


Click on the Volume so it is highlighted, up top click on Clone, then Create, then Volume.

Change the name to something that makes sense to you. I use clone_volume, it is easy to remember. Check Thin Provision and find the correct snapshot and click so it is highlighted.


After a minute or two you should see your clone listed.

Next we are going to create a CIFS share to use as a source for robocopy.

Under storage click on Shares, then Create.

In the next window click on Browse.


Expand out the tree until you find your clone then the original folder. Click Ok

I call the share something simple and then click create.

 

AT this point you can browse out to your newly created share and look at the data.

 

Next we are ready to robocopy the data back.

I used this to copy from my source Temp to the original destination and create a log file I can use to verify what was copied or see if there were any errors.

robocopy “\\fs01\Temp” “\\fs01\BUShared\College of Professional Studies”  /MT:32 /zb /mir /COPY:DATSO /ndl /nfl /w:0 /r:0 /log+:robocopy.txt /xf pagefile.sys


Your logfile should look similar to this at the start.

Once the script finishes you will need to have someone verify what was recovered.

 

 

 

 

Tags:

Microsoft

Comments are closed