6

We have a Windows 2008 R2 file server sharing home folders for about 600 users. These folders are mapped to a shared drive for each user when they log in on their own workstations, and that mapped drive is in turn set as the default location in the Documents library in windows on everyone's profile, including the default profile on each of our machines. Log in to a new machine for the first time, and your Documents library will point at the file server. For laptop users, we also use the Offline Files feature, so that this follows them even when they're away from work.

My problem is that, looking at these folders on the server, they all show up in Explorer as "My Documents", instead of the actual folder name (set to match the username). How can I prevent Windows Explorer from doing this?

10

There's a much easier method, non-destructive, which targets the actual Desktop.ini entry responsible for this behaviour. Go to:

Group Policy -> User Configuration -> Preferences -> Windows Settings -> Ini Files

Create a new Ini File entry, with the following settings:

Action: Delete

File Path: %homeshare%\desktop.ini

Section Name: .ShellClassInfo

Property Name: LocalizedResourceName

MAKE SURE you enable Run in logged-on user's context under the Common tab.

This will remove the offending line from the user's desktop.ini folder, fixing the folder display name behaviour, and leaving everything else intact, including any other user-set folder view customisations, etc. No mess, no fuss.

  • Trying this now, but it will be some time before enough users execute the policy that I'll be able to see this working. Once I've seen the fix in action, I'll mark this accepted. – Joel Coel Oct 22 '15 at 13:42
  • Better than the inept and annoying methods listed by Microsoft, thanks. Accidentally wiped out a user directory once attempting to follow one of their recommended ways. – Fiasco Labs May 5 '16 at 5:23
6

This is Explorer interpreting the desktop.ini files located in each folder. It's maddening and unhelpful, and Microsoft recognizes that but gives no useful advice. The old "This behavior is by design" excuse for the loss...

I've taken to restructuring my shared directory hierarchies, on new installs, to be user-centric rather than directory-type-centric. Rather than having a hierarchy of "Documents" directories and "Profiles" directories (Desktop" directories, etc), I've taken to making a subdirectory for each user, and subdirectories below that for their various directories, like:

[ UserData ]
    |  
    |- [ Bob ]
    |     |
    |     | - [ AppData ]
    |     | - [ Desktop ]
    |     | - [ Documents ]
    |     | - [ Downloads ]
    |     | - [ Profile ]
    |     | - [ Profile.V2 ]
   ...   ...

I am really liking this method better tan the old way. I particularly like my provisioning script can set one ACL, at the "Bob" directory, versus one at each directory when they were stored in their own hierarchy. It also makes seeing an individual's total space usage much easier because I only need to du one directory.

My folder redirection policies need to change a little, as do the user profile paths (ending in %username%\Profile rather than just %username%), but it's a minor change. I've only been doing this for a few months but, so far, it has worked well.

  • Thanks for the response! I may go down this road eventually, but at the moment the Documents folder is the only folder redirected, meaning this solution would add an extra level of folders to look at. – Joel Coel Jan 10 '14 at 4:53
6

(From Spiceworks)

  1. Navigate to share eg \\Server\Users
  2. Right click on column SIZE
  3. Click on More at the bottom
  4. tick Filename

You then get an extra column showing the real filename. You could make this the default for folders by doing this.

  1. Press ALT
  2. choose Tools->Folder Options->View
  3. Click Apply to Folders
4

Deny yourself (or your security group) read access to the desktop.ini - Next time you refresh the folder, it will show the actual folder names, not "My Documents"

  • 1
    I can confirm that denying your self read access to the desktop.ini does indeed work. – Ryan Oct 20 '16 at 12:34
3

Just delete desktop.ini from all user folders (subdirectories of the share). I tested this, and it instantly displayed the proper name.

desktop.ini is hidden by default which makes it a little more tricky, but I can't see anything the users would miss with it gone; There is all of three lines of information in there.

Edit: To quickly blow away all desktop.ini files from the entire shared folder structure use the following command: (WARNING: This WILL remove user customizations for their folders, icons, layout settings? etc.)

      C:\Users\> del desktop.ini /s /a:h
  • Assuming users map to path\to\share\username, try: del path\to\share\*\desktop.ini /a:h Less destructive. This will get the desktop.ini out of each user's shared folder, but it doesn't recurse into subfolders. – Xalorous Oct 4 '16 at 15:19
-2

Add the column 'Filename' in explorer and you see the usernames

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.