Need to copy over files with long path names SBS 2011


  • Hi

    We have a Server with SBS 2011 installed, I am in the process of copying a folder from one location to another but during the process some files were not copied over as the file path name was too long. There are a lot of files that were not copied over, without having to rename all these files which is a lengthy process is there a way that this folder can be copied over.

    I have had a look at Robocopy but need some guidance in using this please.

    If there is an alternative solution then please advise. Any help in this matter will be greatly appreciated.

    Thank You

    Thursday, November 29, 2012 11:36 AM


All replies

  • If the filesnames are too long then they're too long, and any file copy software will hit the same problem. The maximum name for a file + path is 254 characters - one of the main reasons why "Documents and Settings" was renamed to "Users" is later versions of Windows.

    Move all the ones that DID copy into a folder that has a shorter name and/or shallower tree depth, then use RoboCopy to copy the folder again, and it will only copy what's necessary to be copied.


    Thursday, November 29, 2012 2:03 PM
  • Hi,

    I agree with Jim, he has provided the right suggestions to the issue. As he mentioned, any file copy software will hit the same problem when we move the files with too long name. If you want to get the Robocopy guide, I suggest we could refer to the following article.


    Here is an article describes Robocopy GUI, please also refer to it, it may be useful to us.

    Best Regards,

    Andy Qi

    TechNet Subscriber Support

    If you are TechNet Subscription user and have any feedback on our support quality, please send your feedback here.

    Andy Qi
    TechNet Community Support

    Friday, November 30, 2012 6:56 AM
  • Hi,

     I have to say RoboCopy is an excellent tool to handle exactly this case. Actually people are using this tool to do server backup too.

    robocopy "\\server1\folder1" "D:\folder2" /e /z /dcopy:T /XO

    A simple command line came to rescue. I can then sit back and enjoy my coffee.

    Saturday, December 08, 2012 5:58 AM
  • the other way to get at the paths that are too long is to share a subfolder in the branch.


    becomes \\server\temp_share, shortening the 'apparent path'.

    Once you have all the files you then figure out how to avoid the problem in future.

    HINT: Telling users 'the human brain is incapable of handling this file structure, let alone asking a computer to handle it' works. The users are 'more lost' in such long and complex structures than the server is.

    Saturday, December 08, 2012 6:50 AM
  • The maximum name for a file + path is 254 characters

    No, it's not. NTFS can handle files with a name of 255 characters and a path of 32.768 characters. Microsoft made a mistake in Windows Explorer by limiting filename + path to 255 characters. Other programs, like FastCopy, have no problem with long file- and pathnames.

    So, if you rely on Windows Explorer, limit your path/filenames. Otherwise, use something like Windows commander or Qdir as a replacement.


    Monday, May 19, 2014 1:56 PM