Tuesday, 11 July 2017

Windows Explorer's GUI is really bad at long file names and folder structures - Don't trust it!

I am actually in a bit of shock at this one - I've hit the long file name problem in Windows a few times in the past, but it has never been that much of an issue.

A client came to me with a project to move a huge Dropbox repository (Millions of files, about 150,000 folders) to a new server. During this project and moving a few folders, I got the standard Windows long file name problem:


I've only ever come across this when I really thought I was at the limitations - however, I took a step back and tried to understand this.

My client used Dropbox - the location was originally "c:\users\username\dropbox\xxx\yyy\...[lots]...\zzz\file.doc" and the new location is "c:\temp\xxx\yyy\...[lots]...\zzz\file.doc"

Thanks then to a few people in Server Fault chat, it seems that the Windows GUI just lies and doesn't handle this at all well.

In fact, if I look at a folder that has ~750 folders and ~450 files, I see the following:



Moving the files with xcopy or robocopy works fine, or even using Terracopy.

In addition, some tools such as winmerge also fail at comparing looking at the large folder structure where as Beyond Compare was able to do it fine.

Luckily I decided to take extra care and manually verify these files - granted I have never dealt with so many large files on a single job before, but, I have always trusted the Windows property box and this has been a scary lesson for me.

No comments:

Post a Comment