Friday, January 21, 2011

Group policy preferences for Windows 7 and Server 2008 sp2

It has been documented that the GPPs for Windows 7 will not work unless you are running Server 2008 RC2. I am running Server 2008 SP2. I have seen through my testing that this is probably the case.  It is very inconsistent.  I'm trying to schedule a task on a Win 7 client.  Only once did it ever show up in the Task Scheduler.  Then it failed for other reasons.  Every other attempt it has not shown up on the Task Scheduler.  When I run gpresult, is usually indicated that the GPO was sucessfully applied. But not always.  Sometimes I get a Failure (Error Code: 0x80041316).

Tuesday, January 18, 2011

Group policy results on client

gpresult /h gpreport.html

Rather useful if for some reason, it doesn't work from gpmc.msc.

Deleting profiles in Windows 7

I've been searching high and low for a script that does this.  This one did the trick nicely, with a little modification.

I added this mod instead of using "If flgAllowExecute then objFSO.DeleteFolder(objSubfolder.Path), DeleteReadOnly", as it returns a permission denied error.  From what I read, perhaps the file handles are not released when the file is deleted.

If flgAllowExecute then DeleteProfileFolder(objSubfolder.Path)

Sub DeleteProfileFolder(SomeFolderPath)
 Dim strFolder, objShell, objWMIService, objFolders, rtnFolder, rtnCode
 Const WindowStyle = 0
 Const WaitOnReturn = True
 strFolder = SomeFolderPath
 Set objShell = WScript.CreateObject("WScript.Shell")
 objShell.Run "CMD /c RMDIR /s /q " & strFolder, WindowStyle, WaitOnReturn
 Set objShell = Nothing
End Sub

It ain't pretty but it works.

Thursday, January 13, 2011

Sort email by conversation in Outlook

I really don't like Outlook.  Way too complicated, especially if you get a lot of email, of which most of it can be ignored.  This is a good tip for organizing your folders.

Thursday, January 6, 2011

Problems with sysprep & copyprofile - Windows 7x64

For some reason, Sysprep errors in the specialize pass when it tries to copy the profile.  Corrupts the entire load and have to reimage.  The following from seemed to fix it for a few people.

pjpvt said:

I found an answer in another forum that worked for me.  Here's the quote:
I don't know if anyone cares anymore, but I just had this exact problem. The issue turned out to be some bogus profile information in the registry at HKLM\Software\Microsoft\Windows NT\CurrentVersion\ProfileList . I had a couple of keys in there that didn't belong. I think someone had deleted a profile from the c:\users folder without removing the registry piece.

In any case, after I deleted the keys that didn't match what was in the c:\users folder, I no longer had the issue.