by Mitch Tulloch
Windows

Go shallow on your directory structure for file servers

August 15, 2008, 10:37 AM — 


When you design the local directory structure on your file servers, it’s a good idea to go shallow i.e. don’t create a deep directory structure like:

E:\Contoso File Servers\Server12\Data Folders for Employees in Downtown Vancouver Office\Sales and Marketing Department\Sales and Marketing Users

and then share the Sales and Marketing Users folder. The reason this is a bad idea is that one of your users might create a deep folder structure of their own within the shared folder, perhaps something like this:

Tony Allen\Sales Forecasts for Project Fabrikam\Projections\2008\September\First Draft

and then Tony might add a document like this to his First Draft folder:

Fabrikam Project Sales Projection for September 2008 Draft Version 1.1.docx

What’s wrong with this scenario? Well, from Tony’s perspective, the full path to his document would be:

\\Server12\Sales and Marketing Users\Tony Allen\Sales Forecasts for Project Fabrikam\Projections\2008\September\First Draft\ Fabrikam Project Sales Projection for September 2008 Draft Version 1.1.docx

From Tony’s perspective, the full path to his document is 200 characters long, and this is within the 255 character limit supported for paths in Windows Explorer. But what if Tony left the company and you as administrator needed to move his files to a different on the file server? The problem now is that from the perspective of the file system on the file server, the full path to Tony’s document is this:

E:\Contoso File Servers\Server12\Data Folders for Employees in Downtown Vancouver Office\Sales and Marketing Department\Sales and Marketing Users\Tony Allen\Sales Forecasts for Project Fabrikam\Projections\2008\September\First Draft\ Fabrikam Project Sales Projection for September 2008 Draft Version 1.1.docx

This path is 309 characters long, which exceeds the supported path length for Windows Explorer, and this means that if you try and copy or move the file, you’ll get a Windows Explorer error saying that the path length is too long. There are ways of working around this problem—Robocopy for example supports over-long file paths—but they add some frustration to your job as administrator. And there’s no way to prevent users from exceeding the path length limit on the local file system when accessing it remotely through a share, and neither is there a way of extending the maximum path length supported by Explorer as this is hard-coded.

So to make your life a bit easier, avoid sharing deep folders on your file servers in the first place.

I like it!
Free books

Build your tech library with our book giveaways.

Windows PowerShell 2.0 Unleashed
By Tyson Kopczynski, Pete Handley, Marco Shaw; Published by Sams

Windows PowerShell Unleashed will not only give you deep mastery over PowerShell but also a greater understanding of the features being introduced in PowerShell 2.0–and show you how to use it to solve your challenges in your production environment. Enter now!

 

Ubuntu Server Administration
By Michael Jang; Published by McGraw-Hill Osborne Media

Realize a dynamic, stable, and secure Ubuntu Server environment with expert guidance, tips, and techniques from a Linux professional. Ubuntu Server Administration covers every facet of system management -- from users and file systems to performance tuning and troubleshooting. Enter now!

Featured Sponsor

AISO founders envisioned a Web hosting company that was environmentally friendly. While the company employed energy-efficient innovations like solar panels, its infrastructure produced unacceptable power and cooling requirements. Find out how AISO leveraged AMD technology to overcome their challenge in this case study white paper.

In this whitepaper, Scalar explores the opportunity to change the landscape with respect to mission critical databases built around Oracle. Leveraging technologies such as Linux, high-end commodity processing power and Oracle RAC technology to architect, design, build and maintain database infrastructure that delivers maximum availability, reliability and performance at a fraction of traditional cost.

On a typical day, weather.com, the Web site for The Weather Channel in Atlanta, serves up between 15 million and 20 million page views. But in September 2004, when back-to-back hurricanes ransacked Florida, the peak traffic on one day more than tripled: over 70 million page views by more than 7 million unique visitors. Read the full success story now.

More Resources