Windows 7 Thread, Windows 7 renamed our user network folders to my documents in Technical; Originally Posted by dombera
Hi! I`m having a problem with Windows 7 recently deployed in our network.
When user log ...
-
14th September 2010, 04:15 PM #16 
Originally Posted by
dombera
Hi! I`m having a problem with Windows 7 recently deployed in our network.
When user log into windows 7 machines their network home folder gets renamed to My Documents. But when I run dir command via command prompt it shows all folders with proper user names. Please see attached screen shots.
Is there anything I could do to prevent it from happening and get proper folder names back??
Thank you for help in advance.
Attachment 8044Attachment 8044 The real problem is when you redirect the user to their home folder Windows 7 by default turns on synchronization. This then rewrites the "desktop.ini" file in the home folder. To correct this we added a new Group Policy, attached is the settings.
nosync.jpg
-
-
IDG Tech News
-
16th September 2010, 10:33 AM #17
- Rep Power
- 0
Deleting the desktop.ini file
Ok, i have a setting in a gpo that runs a bat file that removes the file.
However, windows must create this file just after login, so the file comes back.
I have done the same on the logout script, but it means while the student is logged in, the folder is called my documents.
I have tried the settings in the gpo that has been mentioned for not creating them, but it does not work in out enviroment.
alan.
-
-
24th September 2010, 04:02 PM #18 I've written a PowerShell script which denies read access to the desktop.ini file to a specified group. Anyone in this group will then not have the documents renamed.
http://blog.salamandersoft.co.uk/ind...network-share/
-
2 Thanks to rpwillis:
dhoward_westexetc (17th December 2010), Rawdon (6th October 2010)
-
27th September 2010, 10:32 AM #19
- Rep Power
- 0
Gpo script to sort out desktop.ini
HI, thanks to everyone for all the info on this.
This is what i have done, i got some of the info from another forum so i cannot take the credit for this, Im just passing the info on.
To rectify the problem a script called Rights.cmd is run on login via a GPO that removes the rights of Administrators and Staff from reading the ini file and therefore you see the users home directory correctly.
Rights.cmd
%windir%\system32\icacls.exe %homedrive%\Desktop.ini /deny "Domain Admins":r
%windir%\system32\icacls.exe %homedrive%\Desktop.ini /deny Administrators:r
%windir%\system32\icacls.exe %homedrive%\Desktop.ini /deny Staff:r
-
Thanks to ajcc22 from:
altonPM (15th October 2010)
-
27th September 2010, 09:02 PM #20 I don't understand the issue with this at all.
Is everyone *not* redirecting the other 10 folders in Vista/7 that need doing to stop them pointing to the local machine? I have them all redirected to the users home folder as a subfolder so that it's not an issue.
Other things to look out for: You get *two* documents etc (one pointing to the local drive) in the users folder of you don't use move the contents or remove the 11 folders from the default/mandatory/netlogon profile that is used to create the users profile.
-
-
15th October 2010, 04:28 PM #21
- Rep Power
- 5
I also wrote a PowerShell script - I think it's a modification of the one that rpwillis posted as I remember the Salamander from another forum somewhere :-) I have put in red the parameters you would want to change for your environment. I am finding PowerShell to be a great tool!
(the smiley face is actually two colons followed by the word DENY)
$InitialFolder = "\\depot\studentstest$\"
#$Files = Get-ChildItem $InitialFolder -include desktop.ini -recurse -force
#$folders = Get-ChildItem W:\
$folders = Get-ChildItem | where-object {$_.psiscontainer};
foreach ($folder in $folders)
{
$Files = Get-ChildItem $folder -Filter desktop.ini -Force
Write-Host Processing $folder , $folder.count files found -foreground "BLACK"
Foreach ($File in $Files)
{
if ($File -ne $null)
{
$colRights = [System.Security.AccessControl.FileSystemRights]"Read"
$InheritanceFlag = [System.Security.AccessControl.InheritanceFlags]::None
$PropagationFlag = [System.Security.AccessControl.PropagationFlags]::None
$objType =[System.Security.AccessControl.AccessControlType]:
ENY
$objUser = New-Object System.Security.Principal.NTAccount("Administrators")
$objACE = New-Object System.Security.AccessControl.FileSystemAccessRule `
($objUser, $colRights, $InheritanceFlag, $PropagationFlag, $objType)
$objACL = Get-ACL $File
$objACL.AddAccessRule($objACE)
Set-ACL $file $objACL
}
}
}
-
-
18th October 2010, 10:12 AM #22
- Rep Power
- 0
I can't get this script to work but i don't think its going to help anyway.
I have managed to get the other script to work from here Richard Willis – SharePoint Learning Kit Coordinator, SalamanderSoft Owner » How To Stop Home Folders Being Renamed Documents in the Network Share
However the problem is that all our users have full control over their profile path.
so currently the desktop.ini has full control to the user and deny for security group "year 7" so i still see it as "my documents"
what would be good is if that script read the folder name (because its named after the username) and set deny read for that user.
-
-
18th October 2010, 10:34 AM #23
- Rep Power
- 0
I got that script to work now. I have to put in the group or user of the affected person. so if im a domain admin i have to deny myself to the desktop.ini so that i can see it. therefore i also then have to add teachers to the deny. its no good adding deny for the student as they are not the ones with the problem
-
-
7th December 2010, 02:56 PM #24
- Rep Power
- 8
Is there a fix for this yet?
Were still having the same problem
-
-
7th December 2010, 05:02 PM #25 
Originally Posted by
RobFuller
Explicitly Disabling this settings in
GP worked for me, can only be found on a 2008R2 machine though.
No its on my 2008 server and its not R2.
-
-
10th December 2010, 11:45 AM #26 
Originally Posted by
Jamesdavid3
Is there a fix for this yet?
Were still having the same problem
I just used FSRM to disable the desktop.ini file. Seems to have worked here and I've not seen any real negative effects.
-
-
10th December 2010, 11:48 AM #27
I just used FSRM to disable the desktop.ini file. Seems to have worked here and I've not seen any real negative effects.
Was the first fix I tried when I was testing 7 during the summer, whenever I did that it would cause logon to hang at "Redirecting folders" for an extra 10/15 seconds per logon.
-
SHARE:
Similar Threads
-
By thatley in forum Windows 7
Replies: 14
Last Post: 5th October 2011, 11:08 AM
-
By pritchardavid in forum Windows Server 2000/2003
Replies: 10
Last Post: 11th May 2010, 06:33 PM
-
By PiqueABoo in forum How do you do....it?
Replies: 0
Last Post: 29th August 2009, 12:39 PM
-
By OllieC in forum Windows
Replies: 7
Last Post: 4th August 2009, 04:15 PM
-
By misterchris in forum Windows
Replies: 2
Last Post: 24th May 2009, 02:53 PM
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules