Quantcast
Channel: Configuration Manager 2012 - Application Management forum
Viewing all articles
Browse latest Browse all 4762

Repair Local Group Policy

$
0
0


Hi

I'm trying to repair local group policy on a number of remote PCs (win 10) by deleting the file held in %windir%\system32\GroupPolicy\machine\registry.pol

I've created a package and deployed it many times now with the same result: The file is never deleted.  The package does run as I can log various steps through the process.

I've used psexec to run this manually as system and it works every time.

I have added debugging lines in my code file and it appears that the deployment can't see the grouppolicy folder. After a little investigation it is a hidden folder so I tried adding 

attrib -h %windir%\system32\GroupPolicy. (Also tried c:\windows\system32...)

Del /q %windir%\system32\GroupPolicy/machine\registry.pol

It just doesn't work. If I add Dir c:\windows\system32\grouppolicy > c:\test.txt

The output is a blank system32 listing as if it can't find the folder 

If I run the cmd file as admin it works fine.

I've tried using RD /Q /S %windir%\system32\GroupPolicy. instead with no luck.

Any help would be most appreciated as this is driving me nuts.


Viewing all articles
Browse latest Browse all 4762

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>