VMware Cloud Community
yuki-hi
Contributor
Contributor
Jump to solution

VMware PowerCLI 12.1のオフライン環境におけるインストールエラーについて

オフライン環境にてvSphere PowerCLI12.1のインストールを実施しようとしています。

しかし、以下のエラーが発生し、power cliモジュールのインポートを実行することができません。

 

OS:Windows Server 2019

PowerCLI Ver:12.1

格納先:C:\Program Files\WindowsPowerShell\Modules

ExecutionPolicy:RemoteSigned

 

エラー内容:

 Get-Module -Name VMware.PowerCLI -ListAvailable | Import-Module
Import-Module : モジュール ディレクトリに有効なモジュール ファイルが見つからなかったため、指定されたモジュール 'VMware.VimAutomation.Sdk' (バージョン: '12.1.0.16997004') は読み込まれませんでした。
発生場所 行:1 文字:51
+ Get-Module -Name VMware.PowerCLI -ListAvailable | Import-Module
+                                                   ~~~~~~~~~~~~~
    + CategoryInfo          : ResourceUnavailable: (VMware.VimAutomation.Sdk:String) [Import-Module], FileNotFoundException
    + FullyQualifiedErrorId : Modules_ModuleWithVersionNotFound,Microsoft.PowerShell.Commands.ImportModuleCommand

 

本件について解決方法および適切なインストール方法についてご教示いただけますと幸いです。

宜しくお願い致します。

 

 

Tags (1)
Reply
0 Kudos
1 Solution

Accepted Solutions
LucD
Leadership
Leadership
Jump to solution

Did you follow the instructions in PowerCLI Offline Installation Walkthrough?

Some things to watch out for:

  • did you install in a folder that is listed in $env:PSModulePath?
  • did you save the module on a platform that runs the same PowerShell version as the platform where you installed?
  • did you use the ZIP file? Did you unlock the file after download?


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference

View solution in original post

Reply
0 Kudos
2 Replies
LucD
Leadership
Leadership
Jump to solution

Did you follow the instructions in PowerCLI Offline Installation Walkthrough?

Some things to watch out for:

  • did you install in a folder that is listed in $env:PSModulePath?
  • did you save the module on a platform that runs the same PowerShell version as the platform where you installed?
  • did you use the ZIP file? Did you unlock the file after download?


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference

Reply
0 Kudos
yuki-hi
Contributor
Contributor
Jump to solution

Thank you for helping.

I check this instructions.

After that, I confirm my server settings.

As a result, I was able to solve this problem.

The cause was the folder hierarchies.

I put these file as below.

ーーーーーーーーーーーーーーーーーーーーー

$home\Documents\WindowsPowerShell\Modules
|ーPowerCLI
    |-Modules
ーーーーーーーーーーーーーーーーーーーーー

I modified these files as follows.

ーーーーーーーーーーーーーーーーーーーーー

$home\Documents\WindowsPowerShell\Modules
|ーModules
ーーーーーーーーーーーーーーーーーーーーー

 

That makes, I could run this module!

Thanks for your help!

I really appreciate it.