I thought my session on troubleshooting with Group Policy and Resultant Set of Policy (RSoP) went rather well. I got some great questions and some nice feedback. The session was recorded and you can watch it on the TechEd North America site, even if you didn't attend. Click here for the session page and video.
Manage and Report Active Directory, Exchange and Microsoft 365 with
ManageEngine ADManager Plus - Download Free Trial
Exclusive offer on ADManager Plus for US and UK regions. Claim now!
ManageEngine ADManager Plus - Download Free Trial
Exclusive offer on ADManager Plus for US and UK regions. Claim now!
As promised, the demos and a PDF of the slide deck can be also be downloaded in a zip file:Troubleshooting-with-RSOP. The PowerShell demo scripts are text files. They are meant to be run one line at a time as example commands. These aren't really scripts.
If you have any questions, let me know.
Very interesting. I always wondered about managing GPOs from Posh but never got to it.
Anyway, I installed RSAT and enabled the tools in control panel > programs > windows features but I still can’t find the module folder “grouppolicy” anywhere. Did I miss something ?
In a PowerShell session, import the module like I did in my demo:
Import-Module GroupPolicy
Then you’ll have access to all the cmdlets. Run:
Get-Command -module GroupPolicy
to see the module contents.
Thanks Jeffrey, but what I meant is that there’s nothing to import. When I type Import-Module GroupPolicy it returns : The specified module ‘GroupPolicy’ was not loaded because no va
lid module file was found in any module directory.
There’s no module directory named GroupPolicy. I thought this folder came along with RSAT, right ?
I see now. That is odd. This is on Windows 7 right? It sounds like you did everything correctly. When you run Get-Module -list I’m assuming you also don’t see the GroupPolicy module. This is a system module so you should see the folder: C:\Windows\system32\WindowsPowerShell\v1.0\Modules\GroupPolicy
If not, then I might suspect a permission or UAC problem.
Thanks ! I’ve found the grouppolicy folder under C:\Windows\system32\WindowsPowerShell\v1.0\Modules\GroupPolicy. I wasn’t aware of this folder. I use a custom modulefolder using $ENV:PSModulePath = “O:\Scripts\PoSh\Modules” in my profile file. I copied the folder there and now it’s all working ! Thanks again.
You shouldn’t have needed to do that, unless you modified the original %PSMODULEPATH% and removed C:\Windows\system32\WindowsPowerShell\v1.0\Modules\. which would mean you wouldn’t see any system modules like AppLocker, BitsTransfer, or TroubleshootingPack. But if you get what you need I’ll let it go.
yeah I only modified the %PSModulePath%. It’s still strange that it doesn’t check the system modules folder when I type Import-Module. But it doesn’t matter that much.
The HTML report of RSOP is very useful btw !
Whenever I’m troubleshooting clients I load global variables for their computername, loginname etc. into the session. I’ve made a little script of the HTML RSOP report and now I have the RSOP of the client in no time. Brilliant 🙂