Why does gpresult /h fail with an “Invalid Pointer” error on Windows Server 2022?

0
0
Asked By MellowCedar42 On

I'm running a standalone, non-domain Windows Server 2022 virtual machine. The commands `gpresult /r` and `rsop.msc` work normally, but `gpresult /h gpreport.html` fails with an "Invalid Pointer" error. I've tried running the command as Administrator and also tested absolute output paths, including a temporary folder and the user's desktop. Could permissions or a policy setting be causing this?

3 Answers

Answered By SilverKite19 On

It may be worth checking for system or WMI corruption with tools such as `sfc /scannow`, `DISM /Online /Cleanup-Image /RestoreHealth`, or `winmgmt /verifyrepository`. However, since reporting and RSOP still work, the issue may be caused by a security policy rather than damaged system components.

MellowCedar42 -

I also reset and checked WMI, but that didn’t resolve it.

Answered By QuietHarbor7 On

Try specifying an absolute output path, such as `gpresult /h C:Tempgpreport.html`, and make sure the destination folder already exists and is writable. The default path may be causing a write-access problem.

MellowCedar42 -

I tested quoted absolute paths in both a temporary folder and the desktop, but the same error occurred.

Answered By BrightMango63 On

The cause was a Global Object Access Auditing policy. Disabling auditing for both the file system and registry allowed `gpresult /h` to generate the HTML report normally. This policy worked on Server 2019 but caused the Invalid Pointer error on Server 2022.

Related Questions

LEAVE A REPLY

Please enter your comment!
Please enter your name here

This site uses Akismet to reduce spam. Learn how your comment data is processed.