Link to home
Start Free TrialLog in
Avatar of GoodEnoughThen
GoodEnoughThenFlag for United States of America

asked on

robocopy results are different than Windows results

I used Robocopy from a Windows 2008 server to copy some files to an externally attached USB harddrive (because I am  under the impression Robocopy can handle file paths longer than 256 characters.

Note: In my script, I excluded Thumbs.db from being copied with a switch:
/XF Thumbs.db.

Here is my robocopy syntax (in robo_EtoS.cmd):

robocopy "E:\File01Recovered\Files" "S:\Files" *.* /E /NS /XF Thumbs.db /R:0 /W:0

When done copying, robocopy showed that it skipped some data: Bytes: 130.236 g

Curious, what does the "g" stand for in the above field? Is that Giga-bytes or some other designator?

User generated image
When I compared the Source (E) and Destination (S) drives using Windows Explorer, the results looked different. The actual data robo-copied over to the Destination appears to be  only 1GB or so less than what Windows indicates is in the Source, as these two screenshot indicate...

Source on E:
User generated image
Destination on S
User generated image
Also note, according to Windows Explorer, that Source on E contains 609,796 files and Destination on S contains 594,647 files. The difference between the two is 15,149 files, which could be explained away by the likelihood that those 15K+ files are all the Thumbs.db's intentionally skipped over by exclusion in my robocopy script.

Any idea why the discrepancy between what robocopy and what Windows shows as data copied from Source to Destination? Could this have anything to do with long file paths - or am I simply misreading what the "g" stands for in Bytes?
Thank you. -GET
CMD-of-robo-results.jpg
CMD-of-robo-results-2.jpg
SOLUTION
Avatar of Michael Pfister
Michael Pfister
Flag of Germany image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of GoodEnoughThen

ASKER

Sorry, I should have noted that this was a first time robocopy so there could not have been any existing files in the target location.
Copy of thing

your *.* is implied so there is not need
Here is a suggestion:
Robocopy "Source" "Dest" /E /XF Thumbs.db /R:0 /W:0 /B /Log:<path text.log> /Tee /NP

You maybe just copying viewable files and not hidden or system files.
You can try adding
Here is another:
Robocopy "Source" "Dest" /E /XF Thumbs.db   /IA:RASHCNETO /R:0 /W:0 /B /Log:<path text.log> /Tee /NP

Try it and see what results you get.
So, robocopy "Source" "Dest" /E does NOT by default copy Hidden or System files, is that correct?

My guess is because the Destination (E:\) is a data drive only, and not a file system drive like on the C: drive, that that the only protected operating system files left would be the Thumbs.db's and desktop.ini's.

I guess what's still odd to me is what robocoy outputs: Skipped Bytes: 130.236 g missing. If those files are only thumbs.dbs and desktop.ini's then the 130.236 GB's seems way too high.
I just confirmed that robocopy lists existing files under "Skipped".
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
No,I did not use the /IA switch.

So... I'm guessing that robocopy results, without using /IA switch, would then include Thumbs.db and desktop.ini files under "Skipped" files  (as well as already existing files).

That would explain the 15,149 files skipped, but not the discrepancy in the actual displayed size of what was skipped: 130.236 g.

Unless, of course, all those variably sized Thumb.db files in the 83,624 folders were quite large. Remember the "regular" data is only 370 GB, so to have 130.236 files of skipped files, Thumbs.db's or other protetcted system files, seems unusually high.
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial