//
you're reading...
ConfigMgr Cmdlets, Configuration Manager

How to import the Configuration Manager PowerShell Cmdlets

Here’s a manual method on how to import the Configuration Manager module to PowerShell. I am running ConfigMgr v1906

  • First launch Windows PowerShell by right-clicking on it and select “Run as administrator”.
  • By default the location of the ConfigurationManager.psd1 is in ConfigMgr installation folder, e.g., C:\Program Files (x86)\Microsoft Configuration Manager\AdminConsole\bin\ (the drive letter may depend where you installed ConfigMgr). In PowerShell, do change of directory. CD ‘ C:\Program Files (x86)\Microsoft Configuration Manager\AdminConsole\bin
  • Type in, Import-Module .\ConfigurationManager.psd1
  • Let’s run the ConfigMgr cmdlets, by switching the path to the ConfigMgr site. In my case, the site code is  PS1 type: cd PS1
  • Now, let’s confirm that ConfigMgr module is working, type in the Get-CMSite cmdlet.

For more info, visit the Get started with Configuration Manager cmdlets page

Discussion

No comments yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: