Skip to content

ps script fails on Windows 7 #49

Description

@sergeileshchinsky

Any way to make it work on Windows 7 ?

Running into:

c:\Program` Files\Zabbix Agent>powershell -NoProfile -ExecutionPolicy Bypass -File "C:\Program Files\Zabbix Agent\scripts
\zabbix_vbr_job.ps1" DiscoveryRepo
DiscoveryRepo
The term 'Get-CimInstance' is not recognized as the name of a cmdlet, function, script file, or operable program. Check
the spelling of the name, or if a path was included, verify that the path is correct and try again.
At C:\Program Files\Zabbix Agent\scripts\zabbix_vbr_job.ps1:315 char:27

  •     $query = Get-CimInstance <<<<  -Class Repository -ComputerName $env:COMPUTERNAME -Namespace ROOT\VeeamBS | Se
    

lect-Object @{ N = "REPONAME"; E = { $_.NAME } }
+ CategoryInfo : ObjectNotFound: (Get-CimInstance:String) [], CommandNotFoundException
+ FullyQualifiedErrorId : CommandNotFoundException

The term 'ConvertTo-Json' is not recognized as the name of a cmdlet, function, script file, or operable program. Check
the spelling of the name, or if a path was included, verify that the path is correct and try again.
At C:\Program Files\Zabbix Agent\scripts\zabbix_vbr_job.ps1:278 char:38

  •     @{ 'data' = $out } | ConvertTo-Json <<<<  -Compress
    
    • CategoryInfo : ObjectNotFound: (ConvertTo-Json:String) [], CommandNotFoundException
    • FullyQualifiedErrorId : CommandNotFoundException

get-modules for powershell returns empty list
can I just add required modules?

Thanks

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions