Jump to content

Windows 7 is deleting users home directories


Recommended Posts

Posted
Quotas definately impact this in some way, since setting quotas on the teachers home folders i've not had any problems with them getting deleted. Students have never been a problem and they have always had quotas.

 

 

I've just checked and are there are no quota's set for either the Teachers or Students. I might try setting quota's on both to see what happens.

 

Also, I have two 2003 Domain Controllers and one 2008 Domain Controller. It could be that when the students use the 2008 DC as their logon server, the GPO settings could be slightly different to what they pick up from the 2003 DC.

Posted

15 users a day?! How many lessons ruined is that?

 

I'd call microsoft and ask for help. At £199 it should be an easy sell to management.

Posted (edited)

I can't believe that I *just* found this website! So, we are having the same issue - lots of home folders being deleted, quite randomly, by Windows 7. I have an active Tech Support case open with Microsoft and my Account Rep just moved it to a Premier Support Case because the lower-level techs haven't found a solution. The case has been open for nearly 4 weeks, so I believe it is either a bug in Windows 7 or some application is deleting the home folders. The deletion happens on login.

 

A few things have helped, like turning off IPv6.

 

I also created a workaround, which was a PowerShell script to prevent users from deleting their own folder by resetting their NTFS security ACL. That did work, but I later removed the workaround so that we could continue to try to pin down the problem - I didn't want a band-aid solution, particularly one that requires a custom script.

 

Additionally: we ARE using offline files (and I want to use that feature). We DO NOT have quotas.

 

I also manage this daily through a PowerShell script which compares home folders to AD student accounts. I run it every couple of hours and it tells me if folders were deleted, so I can restore them and move on. With Volume Shadow Copies turned on, it's easy to restore the files ... but we are also a small district.

 

I am running into this between 2-5 times per day at this point. It was 10-20x/day at he beginning, so some of the measures I've taken (mostly, turning off IPv6) have helped.

 

I also resolved the "My Documents" issue via a PowerShell script - by changing the security on desktop.ini so that Administrators don't have read-access to that file. At least then I can see the whole list of user folders by name from the server share. Another admin I know has a logout script which deletes the desktop.ini file at logout.

 

Wow, I am so happy to have found this forum with other school tech people! We have a great email list in New Hampshire, but it's comforting to see others in other parts of the world who are having the same issues.

Edited by altonPM
add info
Posted

Hi AltonPM,

 

Welcome aboard. Sound like you've got quite slick at reverting the unwanted changes that some here are experiencing. If anyone else wants to raise a ticket, they may find it helpful to reference yours so that MS might get an appreciation of the scale of the problem in schools.

 

I'm just about to begin developing a Windows 7 based system, and would quite like this problem to get fixed before I encounter it first hand! Please let us know what MS manage to do for you.

 

P.

Posted
Hi AltonPM,

 

Welcome aboard. Sound like you've got quite slick at reverting the unwanted changes that some here are experiencing. If anyone else wants to raise a ticket, they may find it helpful to reference yours so that MS might get an appreciation of the scale of the problem in schools.

 

I'm just about to begin developing a Windows 7 based system, and would quite like this problem to get fixed before I encounter it first hand! Please let us know what MS manage to do for you.

 

P.

 

It's all about sharing!

 

My Microsoft Support Incident number is 110092159909810 - in case this is helpful to anyone in the future. They elevated the case a day ago, so I am waiting anxiously to speak to "the experts". :D

 

-Pam

 

I'm also posting here my PowerShell script which compares AD accounts in a specific OU to Home Folders - obviously, this script needs to be customized for other environments. I run PowerShell on a Win 7 workstation - and I've enabled the PowerShell Active Directory module first via RSAT (see How to Install the Active Directory Module for Windows PowerShell )

 

Import-Module ActiveDirectory

# 1. get users from AD Students container, loop through them

$theUsers = Get-ADUser -Filter {(Enabled -eq "True")} -SearchBase "OU=StudentAccounts,OU=Students,OU=Accounts,DC=alton,DC=school,DC=com"

write-host $theUsers.count enabled users found

$folders = Get-ChildItem S:\

 

# 2. for each user, does the home folder exist?

foreach ($user in $theUsers)

{

#write-host $user.Name , $user.sAMAccountName

$userHome = $user.sAMAccountName

#does the home folder exist?

$userFolderExists = Test-Path S:\$userHome

if ($userFolderExists -eq "True") {

#skip

} else {

write-host No home folder for user $userHome , $user.Name -fore darkblue

}

 

}

  • Thanks 2
  • 2 weeks later...
Posted

We are also having the same issue, with student home directories being deleted, staff are fine. We are running esxi 3.5 and thought it could have been something to do with the iscsi connector.

 

Have you heard anything more from Microsoft alton?

Posted
What I did to fix the issue was to install FSRM and make a file screen for the share where their home directory is mapped disallowing any ini files. That did the trick for me.
Posted

bestbett, what is FSRM? You are thinking that the ini files cause the folders to be deleted? If so, those .ini files are pesky! (because they also cause the issue where we can't see the folder names because they are all seen as "My Documents")

 

I finally had my MS case escalated to a Premier case and we are taking profile logs for tech support. No new news from my side, but they are definitely working on it.

Posted
What I did to fix the issue was to install FSRM and make a file screen for the share where their home directory is mapped disallowing any ini files. That did the trick for me.

Be careful with that, that's the solution I originally used but it adds around 10/15 seconds to initial logon time on Windows 7 at the "Redirecting user folders" part.

Posted
For me, it wasn't deleting the folders, it was ranaming them all My Documents. The desktop.ini file that gets added during the synchronize session of login.. ranmes the folder. So by disallowing he desktop.ini file it in turn stops the folder rename.
Posted
Just wanted to add that tech support asked me to turn off offline files at one point and that did not seem to be causing the issue.

 

Thanks for your updates on progress with this. Courtesy of a few little glitches here and there, and some of that nasty old incompatible educational software, I wasn't entirely happy with Win7 and I've been cautiously waiting the SP1 before putting it into production. But I will be using all the ingredients mentioned on this thread.. folder redirection, folder quotas, offline files, IPv6 disabled same as I do server-side now etc., so I'm also interested in the outcome.

 

Anyway, this update is interesting. I don't see why desktop.ini files would have anything to do with this, but offline files did seem like a vaguely credible contender for the deletion i.e. I could imagine that getting very confused and emptying the folder.

 

--

 

Re. desktop.ini. I make a home drive mapped as H: e.g.

 

..\share\FredB

 

But I redirect docs to a sub-folder

 

..\share\FredB\Documents

 

Thus I don't care what desktop.ini tells Explorer to display. Note: I also hide that H: drive - two ways to get to roughly the same place is too challenging for some folk, so they just get My Docs plus those usual shared-with-other-folk drive mappings. Would have done without H: drive altogether, but some other things didn't work with a UNC.

  • 2 weeks later...
Posted

I have an update! So, Microsoft asked me to turn on some profile and folder redirection tracing (I got to write the scripts myself - see this thread on TechNet for details: Can PowerShell restore previous versions of files/folders via Volume Shadow Services (VSS)?). From there, they were able to determine that the home folder is being deleted because, somewhere, it is seeing the server's FQDN as a different path, and deleting it.

 

In the 2nd line below, it is not seeing the server name (\\depot) and the FQDN (\\depot.alton.school.com) as the same path, and is deleting the folder because of this discrepancy. We've just done a full search of the group policies and haven't seen the FQDN of the server anywhere (it's always mapped as %HOMESHARE%, so we're trying to find out why this discrepancy is occurring.

 

 

[1]0394.0454::11/16/2010-23:03:16.950 [kfapi] kfapi::CFolderRedirector::Redirect Got redirection source path = \\depot.alton.school.com\students\10577

[0]0394.0454::11/16/2010-23:03:17.556 [kfapi] kfapi::CFolderRedirector::PerformRedirection Entering, fid = {FDD39AD0-238F-46AF-ADB4-6C85480369C7}, source = \\depot.alton.school.com\students\10577, target = \\depot\students\10577

[0]0394.0454::11/16/2010-23:03:24.788 [kfapi] kfapi::CFolderRedirector::PerformRedirection Known folder path updated

[1]0394.0454::11/16/2010-23:03:24.827 [kfapi] kfapi::CFolderRedirector::PerformRedirection Delete source folders

  • Thanks 3
Posted

We sorted this out a while back

 

We have a mantory profile for everyone expect admins

 

The mantory profile ntuser has the regeistry set for each of the special folder has shown below to the following place

 

o:\Documents

o:\Pictures

o:\Music

o:\Videos

o:\Favouites

 

And of course all out user have a mapped 'o' network drive and also has no redirection group policys set has the profile has set the correct location already!

  • Thanks 1
Posted
In the 2nd line below, it is not seeing the server name (\\depot) and the FQDN (\\depot.alton.school.com) as the same path, and is deleting the folder because of this discrepancy. We've just done a full search of the group policies and haven't seen the FQDN of the server anywhere (it's always mapped as %HOMESHARE%, so we're trying to find out why this discrepancy is occurring.

 

Thanks for the update altonPM. We've not had this deleting issue yet but am all to wary of doing something that triggers it. I havn't used the %HOMESHARE% variable in our profiles paths which may be why.

  • 2 months later...
Posted

I believe she did:

Can PowerShell restore previous versions of files/folders via Volume Shadow Services (VSS)?

 

And just in case that thread ever vanishes here is her solution:

Hi Daniel -

 

Yes, we do have a fix that worked for us. What follows is the registry key and an explanation of it! For some reason, Windows 7 is comparing the FQDN path with the short path (even though the FQDN path is NOT set anywhere in our policies or AD properties any longer - we checked extensively; although it was set at one time because I tried it as a potential fix to the problem below). It sees them as two different folders and then deletes one of them!

 

Give it a try, and best of luck! We are still having issues with some netbooks (only one model) not being able to access students' home folders using the short name path, and that part of the case has been escalated to a Networking Team in MS Tech Support - they are still analyzing network logs. But, at least the folders aren't being deleted any longer.

 

-Pam

 

HKLM\Software\Policies\Microsoft\Windows\Explorer\CheckSameSourceAndTargetForFRAndDFS = 1

 

In conversation with my colleague, we came across a policy for Windows Explorer that addresses this very issue:

 

Machine Policies \Windows Components\Windows Explorer

“Verify old and new Folder Redirection targets point to the same share before redirecting”

 

Policy Info:

This policy setting allows you to prevent data loss when you change the target location for Folder Redirection, and the new and old targets point to the same network share, but have different network paths.

 

If you enable this policy setting, Folder Redirection creates a temporary file in the old location in order to verify that new and old locations point to the same network share. If both new and old locations point to the same share, the target path is updated and files are not copied or deleted. The temporary file is deleted.

 

If you disable or do not configure this policy setting, Folder Redirection does not create a temporary file and functions as if both new and old locations point to different shares when their network paths are different.

 

Note: If the paths point to different network shares, this policy setting is not required. If the paths point to the same network share, any data contained in the redirected folders is deleted if this policy setting is not enabled.

Posted

Thanks psydii for cross-posting that, I'm sorry I forgot to post it here!

 

We are still working with Microsoft on part of this issue. Although we resolved the folder deletion, now we have a situation where students don't have permissions to access their own home folder / mapped drive by short name only (i.e., they can get to it by FQDN!) and only on some machines (mostly netbooks). It's not a server permissions problem or a Group Policy issue, and MS has a Networking Team analyzing data for me on that part of it.

 

-Pam

  • Thanks 1
Posted

The symptoms you are getting are similar to mine when I had offline files active on student machines. If a logged on user (Fred) puts say \\server1 into offline mode, only Fred can put the server back into online mode. Any other user logged on to that machine will get an access denied error, but can access the server using the full DNS name (server1.blah.local) or IP instead. That is, unless that user also then puts the full DNS name into offline mode as well.

It's basically because the new user that is logged on doesn't have access to the first user (Fred)'s work area, so it can't do a sync check and put the share back online.

 

The only way I could solve this was to totally disable offline files via services.msc (or a group policy) and format the offline files (CSC) database by creating a DWORD entry called "FormatDatabase" and setting the entry to "1" in

 

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\CSC\Parameters

 

and rebooting.

 

I did find a thread about this on technet which was replied to by a Microsoft poster who said this was by design.

Vista Offline Files Redirection Failed When local Cache put in Offline Mode

  • Thanks 1
Posted
I need help with a very strange problem! We have replaced 7 of our Admin machines over to new HP's running windows 7.

 

First one was drive mapping conflicting during the log on script because the H drive was used by a memory card reader. remapping the memory card reader and drive mapping worked fine.

 

Second one was home directories just displaying as "documents" in \\*file server*\*share*\ rather than the login name before, however if you opened the documents folder, it is showing as \\*file server*\*share*\*user* and same within command prompt. Not sure if this just how windows 7 works but obviously we would like to see the login in the share and not just "Documents" for everyone.

 

In regards to your second problem ... deleting the desktop.ini file from the user area automatically makes the name correct again. if the stuff in the microsoft article doesnt appeal to you... you can setup a batch file that you setup to run every night through scheduled task to delete any of the desktop.ini files. You can find batch file code for that here.

  • 2 weeks later...
Posted

We had a similar problem where documents were apparently disapearing.

We found the cause was Windows Offline files misbehaving. We deleted th cache, turn it off, and we've experienced no further issues.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...