Learn about the technologies behind the Internet with The TCP/IP Guide!
NOTE: Using robot software to mass-download the site degrades the server and is prohibited. See here for more.
Find The PC Guide helpful? Please consider a donation to The PC Guide Tip Jar. Visa/MC/Paypal accepted.
View over 750 of my fine art photos any time for free at DesktopScenes.com!

[ The PC Guide | Articles and Editorials | Xcopy Xposed ]

"But! But! You're Wrong! It Does Work, I Did It Myself!"

Yes, yes, this is what everyone says whenever anyone challenges the Xcopy myth. The reason is simple: the problems with Xcopy do not always occur, and when they do occur they are rarely obvious. People tend to assume that if they try something and it works for them--or appears to work--that it always works. Further, most often when a short file name alias is swapped, there is no visible effect on the system so there are no tangible symptoms. But once in a while, Xcopy will cause an alias distortion that will lead to system problems. Sometimes these can occur many weeks or months after the Xcopy was done.

Don't believe me? You can demonstrate it for yourself. Just follow these steps:

  1. Back up your system before beginning, if you are afraid of damaging anything with this procedure (unlikely.) At the very least, close all open programs.
  2. Open Windows Explorer
  3. Create a new folder within the root directory ("C:\") called "Test". Go into this folder.
  4. Create a new folder within "Test" called "Source". Go into this folder.
  5. Create a folder within "Source" called "Microsoft is #1".
  6. Create a folder within "Source" called "Microsoft is #2".
  7. Create a folder within "Source" called "Microsoft is #3".
  8. Open a DOS prompt box.
  9. Type "CD \Test\Source" and hit {Enter}.
  10. Type "DIR" and hit {Enter}. You will see the three folders you just created, and their short file name aliases. Note that the short file name for "Microsoft is #1" is "MICROS~1", the alias for "Microsoft is #2" is "MICROS~2", and the alias for "Microsoft is #3" is "MICROS~3". This is what you'd expect; so far, so good.
  11. Go back to Windows Explorer and delete "Microsoft is #2".
  12. Go back to the DOS box, and again type "DIR" and hit {Enter}. You will see that there are only the two folders left, but the aliases have not changed: the short file name for "Microsoft is #1" is "MICROS~1", and the alias for "Microsoft is #3" is "MICROS~3".
  13. Type "CD \Test" and hit {Enter}.
  14. Type "XCOPY /R /I /C /H /K /E /Y Source Dest" and hit {Enter}. This will copy the contents of the "Source" subfolder to a new subfolder called "Dest".
  15. Type "CD Dest" and hit {Enter}.
  16. Type "DIR" and {Enter}. Take a look a the short file name alias for "Microsoft is #3" and you will see that it is now "MICROS~2", not "MICROS~3" as it was before.

And by the way, it doesn't matter if you use "XCOPY" or "XCOPY32". The problem occurs regardless, since Xcopy just invokes Xcopy32 when run under Windows.

Next: And I Should Care?


Home  -  Search  -  Topics  -  Up

The PC Guide (http://www.PCGuide.com)
Site Version: 2.2.0 - Version Date: April 17, 2001
Copyright 1997-2004 Charles M. Kozierok. All Rights Reserved.

Not responsible for any loss resulting from the use of this site.
Please read the Site Guide before using this material.
Custom Search