Why can't I Install the Zerto Powershell commandlets

I’m not sure what I’m doing wrong. On my WIndows server, I have the Zerto commandlets installed and working however I want to upgrade them to the latest version to match the environment. This page is where I can download them:

Firstly, how can I check the version of the current modules?

I thought to use get-module -ListAvailable -Name ‘zerto’ however nothing is returned.

I opened a PowerShell CLI as Administrator and ran the command Install-Module -Name Zerto.Zvm.Commandlets and got the following:

PS C:\Windows\system32>  Install-Module -Name Zerto.Zvm.Commandlets

Untrusted repository
You are installing the modules from an untrusted repository. If you trust this repository, change its InstallationPolicy value by running the Set-PSRepository cmdlet. Are you sure you want to install the modules from 'PSGallery'?
[Y] Yes  [A] Yes to All  [N] No  [L] No to All  [S] Suspend  [?] Help (default is "N"): a
PS C:\Windows\system32> $PSVersionTable

Name                           Value
----                           -----
PSVersion                      5.1.14393.6343
PSEdition                      Desktop
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0...}
BuildVersion                   10.0.14393.6343
CLRVersion                     4.0.30319.42000
WSManStackVersion              3.0
PSRemotingProtocolVersion      2.3
SerializationVersion           1.1.0.1

Looks like it installed however I cannot tell.

Additional info:

PS C:\Windows\system32> $env:PSModulePath -split ';'
C:\Users\jmilano\Documents\WindowsPowerShell\Modules
C:\Program Files\WindowsPowerShell\Modules
C:\Windows\system32\WindowsPowerShell\v1.0\Modules
C:\Program Files\Microsoft Monitoring Agent\Agent\PowerShell\
C:\Program Files\Microsoft Monitoring Agent\Agent\AzureAutomation\7.3.1840.0
PS C:\Windows\system32>

Searching each folder I found the following:
C:\Program Files\WindowsPowerShell\Modules\Zerto.Zvm.Commandlets\1.953.2

So the files look like they are there- just not showing up when trying to list all modules.

Get-Module -ListAvailable -Name Zerto.Zvm.Commandlets

Yeah, returns blank. Even this returns blank:

Get-Module -ListAvailable -Name *Zerto*

I cannot reproduce this behaviour. It works for me when I use the correct name or a pattern with asterisks. :man_shrugging:t3:

If you look at the details of the module, it requires powershell 6.1 or up. You can also see this by trying to import the module

Import-Module Zerto.Zvm.Commandlets

Import-Module : The version of Windows PowerShell on this computer is '5.1.14393.6343'. The module 'C:\Program
Files\WindowsPowerShell\Modules\Zerto.Zvm.Commandlets\1.953.2\Zerto.Zvm.Commandlets.psd1' requires a minimum Windows
PowerShell version of '6.1' to run. Verify that you have the minimum required version of Windows PowerShell installed,
and then try again.

If you go backwards through the versions on the powershell gallery, you’ll find the newest version that worked with 5.1 is 1.0.0. Therefore, you should either install powershell core 6.1 or newer, or install the specific version for 5.1.

Install-Module -Name Zerto.Zvm.Commandlets -RequiredVersion 1.0.0

Then you’ll see the module listed. Looks like this version had very, very few downloads. You may want to go with the newer version on powershell core, as the newer versions have many more downloads.

1 Like

Oooops, because I tried it with the current version I didn’t even noticed that. :pray:t3:

@krzydoug good catch. :+1:t3:

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.