Start a Conversation

Unsolved

This post is more than 5 years old

SV

20743

November 27th, 2012 10:00

Export regkeys to .reg file during logoff

Hi,

I'm trying to export two HKCU keys to an .reg file during logoff of a user but somehow this does not work using gpo. It's a vbs script which uses regedit /s /e to export the keys to the users profile which then is included in the metaprofile. I also tried to export the file to the homedrive of the user but this also fails.

When running gpresult I can see that the policy is processed but somehow the files ate not created. I added the script to the user part of the gpo with loopback processing enabled but no luck.

Does someone know another way of achieving this? Maybe by using the vWorkspace Management console?  (vWs 7.2 mr1)

regards

Sijtze van Dellen

228 Posts

November 27th, 2012 11:00

Hello Sijtze,

I have run into this problem once before, my script ran perfectly when I executed it manually but did not produce a result when executed through a GPO.

I would suggest you check the UAC settings on the system you are testing the policy. With UAC enabled any scripts that are run from a policy will execute, but under a different security context to the user. When UAC is enabled the logon/logoff scripts are executed by an Administrative user, the desktop then loads afterward as the user.

One suggestion to resolve the problem was to firstly apply this registry setting:

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System

EnableLinkedConnections =(dword)1

Google UAC and logon scripts and you will find further information and suggested workarounds.

I hope this helps

David

November 27th, 2012 11:00

Hi David,

I figured it out. It was my own fault. I exported the keys to the roaming folder uf the users profile but guess what. The roaming folder wasn't included in te metaprofile. So I made other metaprofile entry with a new folder and exported the files to that folder. Now it works perfect. We finally can save our personal printer settings :-)

Thanks for your help. I appreciate it.

regards

Sijtze

No Events found!

Top