[Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 455
  • Last Modified:

Directory Path Limit


I am aware that the directory path limit is 255 characters.  

First, why does Windows allow folders/files to be created which exceed the limit and then error out on attempts to copy or delete these?

Is there software or some method that supports copying / backing up thse files?

Is there a way to prevent users from creating folders/files that exceed the limit?

0
btree
Asked:
btree
  • 3
  • 2
1 Solution
 
MazaraatCommented:
Here is a little program to find long file/folder names and will allow you to rename them:
http://www.dcsoft.com/products/longff/longff.htm

0
 
btreeAuthor Commented:
Thanks.  I am aware of the program.  However, I want to be able to preserve the file and directory names if at all possible.
0
 
MazaraatCommented:
Can you copy them from the cmd shell using something like copy c:\longfil~.doc to e:\longfil~.doc ?
0
 
btreeAuthor Commented:
I can give that a try for testing purposes (I am not sure if you are wondering if that is technically possible and if it were then that would be the solution).  However, it is likely that I will need to re-copy the files periodically and there are a very large number of folder and files so the process has to be as automated as possible.  
0
 
MazaraatCommented:
I was thinking about your delimma and think I came up with a plausible work around for you.  Why not create shares furhter down in your directories?  Yes you will have more shares, but it would save you from the long directory path.

example

instead of using f:\...\..\.\\.\.\(255)filename.doc  create a shared down the chain where it makes sense and you can get away with creating as few extra shares as possible.

Or you can move your folders closer to the top by re-organizing them.

I had a similar problem with our document management server.  The quality management people created several thousand directories some of them exceeding the limit.  I had to go re organize them and flatten their directory structure out to correct the problem as a long term solution.


as to copying the folders and files I would recommend using robocopy from the resource kit:
download:
http://www.microsoft.com/downloads/details.aspx?FamilyID=9d467a69-57ff-4ae7-96ee-b18c4790cffd&DisplayLang=en
syntax:
http://www.ss64.com/nt/robocopy.html



0

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now