PowerCLI

 View Only
  • 1.  Import module guide needed

    Posted Sep 09, 2020 02:43 PM

    Hi Team,

    How to import module as per described in the below link to get work with Get-CPUOvercommit & Get-MemoryOvercommit powercli command.

    Please guide me

    PowerCLI Module to Check CPU, Memory and Storage OverCommitment - VMware PowerCLI Blog

    I getting error as per below:

    Add-PSSnapin : No snap-ins have been registered for windows powershell version 5.

    At C:\Windows\system32\WindowsPowerShell\v1.0\Modules\vsphereOvercommit.psm1:47 char:13

    + Add-PSSnapin VMware.VimAutomation.Core }

    +```````````````````````````````````````````````````````````

    +Category Info : InvalidArgument: (Vmware.vimautomation.core:string) [Add-PSSnapin], PSArgumentException

    +FullyQualifiedErrorId: AddPSSnapInRead, Microsoft.Powershell.commandAddPSSnapinCommand



  • 2.  RE: Import module guide needed
    Best Answer

    Posted Sep 09, 2020 03:00 PM

    I'm afraid we are way past PSSnapin with PowerCLI.

    PowerCLI is since quite some time available as a collection of modules.

    And these modules are available in the PowerShell Gallery.

    See Welcome PowerCLI to the PowerShell Gallery – Install Process Updates for instructions