[VMware] Online install VMware PowerCLi through PowerShell

<Require>
This environment use PowerShell 5.x version

How to check PowerShell version
PS:\> $PSVersionTable
Or
PS:\> Get-Host

step01.
PS:\> Save-Module -Name VMware.PowerCLI -Path

step02.
PS:\> Install-Module -Name VMware.PowerCLI

step03.
PS:\> Set-PowerCLIConfiguration -InvalidCertificateAction Ignore

step04.
PS:\> Get-Module -ListAvailable -Name VMware*

[Windows] How to count CIFS/SMB files in a folder or a directory ?

運用PowerShell來計算檔案及目錄數
**計算檔案數量**
Get-ChildItem \\CIFS-IP\Share-Volume -Recurse -File | Measure-Object | %{$_.Count}
**計算目錄數量**
Get-ChildItem  \\CIFS-IP\Share-Volume -Recurse -Directory | Measure-Object | %{$_.Count}
PS: 在 Restricted 可執行無需 bypass 或 unrestricted
運用命令提示列 (cmd.exe)
dir *.* /w /s
count-file2.jpg

[VMware] 執行VMware vSphere PowerCLI發生錯誤 ‘ 檔案無法載入,因為這個系統已停用指令碼執行 ‘

當在執行VMware vSphere PowerCLI 錯誤訊息 ‘ 檔案無法載入,因為這個系統已停用指令碼執行 ‘
因安全性原則無法執行載入..

workaround :

step1.以系統管理員身份執行 ‘ powershell ‘

step2.type as below command

$ Set-ExecutionPolicy RemoteSigned

or 

$ Set-ExecutionPolicy Bypass

or
$ Set-ExecutionPolicy Unrestricted // 沒有任何限制意謂著安全性....呃!小心服用

Reference:

1. http://asika.windspeaker.co/post/3500-powershell-remotesigned

2. https://dotblogs.com.tw/gelis/2010/10/23/18532

3. https://dotblogs.com.tw/sungnoone/2013/04/12/101523