1.list the power on VMs:
esxcli vm process list --重要的是找到World ID
若用esxcli vm process list | grep <guest vm name>則只會列出名稱與config file位置
2.turn off the VM:
esxcli vm process kill --type=xxxx --world-id=yyyyy
例如:esxcli vm process kill --type=soft --world-id=60418
for -type=xxxx use: soft, hard or force
for world-id=yyyy(VM ID) use the World ID listed in the command above
(eg. World ID 39731 for the example VM "Cold")
Some information about the three possible shutdown methods:
soft = prefer this if you want to shut down "softly"
hard = equal to an immediate shutdown
force = hard kill of the VM
3.trun on the VM:
list the VM:
vim-cmd vmsvc/getallvms
power on the VM:
vim-cmd vmsvc/power.on <vmid>
Check the power state of the VM
vim-cmd vmsvc/power.getstate <vmid>
check VM status:
esxcli vm process list
4.reboot the VM:
vim-cmd vmsvc/power.restart (reboot)<vm-id>
5.shutdown the VM:
vim-cmd vmsvc/power.shutdown <vm-id>
2019年4月8日 星期一
2019年4月5日 星期五
vmware esxi6.5u1 update 6.5u2?
先下載update6.5u2及之後的Patches
update-from-esxi6.5-6.5_update02.zip
ESXi650-201903001.zip
1.請開啟瀏覽器後輸入 http://ESXi Server IP or FQDN/ui 登入VMware ESXi 6.5主控台
登入帳號:root
登入密碼:系統安裝時,所設定輸入密碼。
2.先準備上載更新檔案
點選:Navigator 導覽器➤Storage 儲存區➤Datastore browser 資料存放瀏覽器
(1).點選:Create directory 建立目錄
(2).命名目錄名稱,例如:Patches
(3).點選:Upload 上傳
(4).選擇已下載更新檔案:update-from-esxi6.5-6.5_update02.zip 上傳ESXi6.5 U2更新檔案
3.選擇:動作➤進入維護模式 Enter Maintenance Mode
4.確認維護模式變更,請點選:是
5.VMware ESXi 6.5 Host主控台可以看到系統已進入維護模式 Enter Maintenance Mode
6.選擇:動作➤服務➤啟用Secure Shell (SSH)服務
VMware ESXi 6.5 Host主控台可以看到系統已進入維護模式 Enter Maintenance Mode
※透過 PuTTY登入ESXi Host端 (需先啟用SSH)服務),執行進入「維護模式」指令:
#vim-cmd /hostsvc/maintenance_mode_enter
7.執行PuTTY登入ESXi 6.5 Host 主機(使用root帳號)
輸入更新指令與存放更新檔案儲存區位置,輸入完成請按下Enter進行系統更新:先更新到6.5U2(在跟目錄下以下指令)
esxcli software vib install -d /vmfs/volumes/vmstorage/Patches/update-from-esxi6.5-6.5_update02.zip
稍後一段時間,即可完成如下圖 ESXi 6.5 Update 2 Patches系統更新完成版本訊息
8.更新完成後,請將ESXi 6.5 Host 退出「維護模式」及「重新開機」。
也可執行PuTTY登入ESXi Host端,執行指令退出「維護模式、重新開機」:
# vim-cmd /hostsvc/maintenance_mode_exit
# reboot
9.再更新6.5U2之後的Patches,步驟與上面相同,只是指令為(在跟目錄下以下指令)
esxcli software vib install -d /vmfs/volumes/vmstorage/Patches/ESXi650-201903001.zip
參考:http://maxlabvm.blogspot.com/2018/05/how-to-install-latest-esxi-65-update-2.html
update-from-esxi6.5-6.5_update02.zip
ESXi650-201903001.zip
1.請開啟瀏覽器後輸入 http://ESXi Server IP or FQDN/ui 登入VMware ESXi 6.5主控台
登入帳號:root
登入密碼:系統安裝時,所設定輸入密碼。
2.先準備上載更新檔案
點選:Navigator 導覽器➤Storage 儲存區➤Datastore browser 資料存放瀏覽器
(1).點選:Create directory 建立目錄
(2).命名目錄名稱,例如:Patches
(3).點選:Upload 上傳
(4).選擇已下載更新檔案:update-from-esxi6.5-6.5_update02.zip 上傳ESXi6.5 U2更新檔案
3.選擇:動作➤進入維護模式 Enter Maintenance Mode
4.確認維護模式變更,請點選:是
5.VMware ESXi 6.5 Host主控台可以看到系統已進入維護模式 Enter Maintenance Mode
6.選擇:動作➤服務➤啟用Secure Shell (SSH)服務
VMware ESXi 6.5 Host主控台可以看到系統已進入維護模式 Enter Maintenance Mode
※透過 PuTTY登入ESXi Host端 (需先啟用SSH)服務),執行進入「維護模式」指令:
#vim-cmd /hostsvc/maintenance_mode_enter
7.執行PuTTY登入ESXi 6.5 Host 主機(使用root帳號)
輸入更新指令與存放更新檔案儲存區位置,輸入完成請按下Enter進行系統更新:先更新到6.5U2(在跟目錄下以下指令)
esxcli software vib install -d /vmfs/volumes/vmstorage/Patches/update-from-esxi6.5-6.5_update02.zip
稍後一段時間,即可完成如下圖 ESXi 6.5 Update 2 Patches系統更新完成版本訊息
8.更新完成後,請將ESXi 6.5 Host 退出「維護模式」及「重新開機」。
也可執行PuTTY登入ESXi Host端,執行指令退出「維護模式、重新開機」:
# vim-cmd /hostsvc/maintenance_mode_exit
# reboot
9.再更新6.5U2之後的Patches,步驟與上面相同,只是指令為(在跟目錄下以下指令)
esxcli software vib install -d /vmfs/volumes/vmstorage/Patches/ESXi650-201903001.zip
參考:http://maxlabvm.blogspot.com/2018/05/how-to-install-latest-esxi-65-update-2.html
2019年3月28日 星期四
esxi 無法將 VM 匯出 ovf?
匯出ovf時出現失敗--網路錯誤或失敗--錯誤憑證,後來找到http://itworkertony.blogspot.com/2018/10/esxi-vm-ovf.html
原來是瀏覽器的問題,用chrome會出問題,換firefox就沒問題了。
原來是瀏覽器的問題,用chrome會出問題,換firefox就沒問題了。
2018年10月5日 星期五
2017年8月20日 星期日
vmware workstation 12.5.7 install vsphere6.5、vcsa6.5 and VMware vSphere Replication 6.5.1 心得....
vsphere 6.5後已經沒有client,只有web,6.5注重DNS,故要安裝AD,之後安裝VMware-VMRC-10.0.1-5898794.msi,再裝esxi6.5,只要下一步即可解決,IP設一設就好。
在安裝vcsa6.5,因為只有ISO檔案,必須開啟ISO在vcsa目錄下VMware-vCenter-Server-Appliance-6.5.0.10000-5973321_OVF10.ova取出即可deploy,這是workstation作法,正式使用時直接掛載ISO執行\vcsa-ui-installer\w32\install.exe,deploy後在目錄下開啟*.vmx將以下文字加入。
guestinfo.cis.deployment.node.type = "embedded"
guestinfo.cis.appliance.net.addr.family = "ipv4"
guestinfo.cis.appliance.net.mode = "static"
guestinfo.cis.appliance.net.pnid = "192.168.1.250"
guestinfo.cis.appliance.net.addr = "192.168.1.250"
guestinfo.cis.appliance.net.prefix = "24"
guestinfo.cis.appliance.net.gateway = "192.168.1.254"
guestinfo.cis.appliance.net.dns.servers = "192.168.1.1"
guestinfo.cis.appliance.root.passwd = "Txxxxxxx@"
guestinfo.cis.appliance.ssh.enabled = "True"
guestinfo.cis.deployment.autoconfig = "True"
guestinfo.cis.appliance.ntp.servers = "192.168.1.1"
guestinfo.cis.vmdir.password = "Txxxxxxx@"
guestinfo.cis.vmdir.site-name = "vc"
guestinfo.cis.vmdir.domain-name = "sct.com"
guestinfo.cis.ceip_enabled = "False"
在安裝vcsa6.5,因為只有ISO檔案,必須開啟ISO在vcsa目錄下VMware-vCenter-Server-Appliance-6.5.0.10000-5973321_OVF10.ova取出即可deploy,這是workstation作法,正式使用時直接掛載ISO執行\vcsa-ui-installer\w32\install.exe,deploy後在目錄下開啟*.vmx將以下文字加入。
guestinfo.cis.deployment.node.type = "embedded"
guestinfo.cis.appliance.net.addr.family = "ipv4"
guestinfo.cis.appliance.net.mode = "static"
guestinfo.cis.appliance.net.pnid = "192.168.1.250"
guestinfo.cis.appliance.net.addr = "192.168.1.250"
guestinfo.cis.appliance.net.prefix = "24"
guestinfo.cis.appliance.net.gateway = "192.168.1.254"
guestinfo.cis.appliance.net.dns.servers = "192.168.1.1"
guestinfo.cis.appliance.root.passwd = "Txxxxxxx@"
guestinfo.cis.appliance.ssh.enabled = "True"
guestinfo.cis.deployment.autoconfig = "True"
guestinfo.cis.appliance.ntp.servers = "192.168.1.1"
guestinfo.cis.vmdir.password = "Txxxxxxx@"
guestinfo.cis.vmdir.site-name = "vc"
guestinfo.cis.vmdir.domain-name = "sct.com"
guestinfo.cis.ceip_enabled = "False"
存檔後開機,vcsa會比較久,之後開啟瀏覽器打https://vcsa IP:5480繼續安裝,之後開啟https://vcsa IP 左下角出現 下載增強型驗證外掛程式 安裝
VMware-EnhancedAuthenticationPlugin-6.5.0.exe,將esxi加入,若要安裝VMware vSphere Replication 6.5.1一定要先安裝DNS主機,否則在deploy時出現 傳送失敗:OVF描述元不可用。
以下是安裝vcsa6 一些問題,6.5就比較沒問題
在vcsa6光碟片執行vcsa-setup.html
會告知安裝用戶端整合外掛程式
在光碟片目錄vcsa中安裝VMware-ClientIntegrationPlugin-6.0.0-4911605.exe
安裝過程如果有error,請將防毒軟體關閉,安裝後再啟用防毒軟體
在vcsa6光碟片找不到ova等
在VMware-VCSA-all-6.0.0-5326177.iso中的vcsa目錄的vmware-vcsavmware-vcsa檔案解壓成vmware-vcsa.ova
即可在workstation deploy vcsa
deploy後開啟***.vmx
將以下資料複製上
安裝VMware vSphere Replication出現
Server returned 'request expired' less than 0 seconds after request was issued, but it shouldn't have expired for at least 600 seconds.
表示esxi、vcsa、vmware replication 時間不對
esxi時間-->隨主機一起啟動和停止,NTP開啟
vcsa時間-->etc/utc,時間同步-->主機
vmware replication 時間-->asia/taipei
VMware-EnhancedAuthenticationPlugin-6.5.0.exe,將esxi加入,若要安裝VMware vSphere Replication 6.5.1一定要先安裝DNS主機,否則在deploy時出現 傳送失敗:OVF描述元不可用。
以下是安裝vcsa6 一些問題,6.5就比較沒問題
在vcsa6光碟片執行vcsa-setup.html
會告知安裝用戶端整合外掛程式
在光碟片目錄vcsa中安裝VMware-ClientIntegrationPlugin-6.0.0-4911605.exe
安裝過程如果有error,請將防毒軟體關閉,安裝後再啟用防毒軟體
在vcsa6光碟片找不到ova等
在VMware-VCSA-all-6.0.0-5326177.iso中的vcsa目錄的vmware-vcsavmware-vcsa檔案解壓成vmware-vcsa.ova
即可在workstation deploy vcsa
deploy後開啟***.vmx
將以下資料複製上
安裝VMware vSphere Replication出現
Server returned 'request expired' less than 0 seconds after request was issued, but it shouldn't have expired for at least 600 seconds.
表示esxi、vcsa、vmware replication 時間不對
esxi時間-->隨主機一起啟動和停止,NTP開啟
vcsa時間-->etc/utc,時間同步-->主機
vmware replication 時間-->asia/taipei
2017年8月8日 星期二
VSPHERE WEB CLIENT 顯示特定語言
vSphere web client 瀏覽器內定為中文,若要改為英文必須改成為:
https://vcenter IP/vsphere-client/?locale=en_US
中文為https://vcenter IP/vsphere-client/?locale=zh_TW
2017年7月5日 星期三
centos 7 install vmware tools?
安裝完centos 7 之後,要安裝vmware tools,到某個地方(gcc)就會一直迴圈,上網找時發現有些元件未安裝,所以必須先安裝
2017年6月8日 星期四
整併磁碟時發生錯誤: msg.snapshot.error-FAILED。 scsi0:0 已超過整併重試次數上限。
請將發生此Guest OS關機,點選此Guest OS按右鍵選編輯設定,點選選項--一般--組態參數,
按新增列,在左側窗格中添加以下參數
snapshot.asyncConsolidate.forceSync
在右側窗格中添加以下值
TRUE
確定儲存
然後開機再做整併
按新增列,在左側窗格中添加以下參數
snapshot.asyncConsolidate.forceSync
在右側窗格中添加以下值
TRUE
確定儲存
然後開機再做整併
2016年4月20日 星期三
將VMware vSphere Web Client改成中文操作介面
VMware vSphere Web Client預設為英文操作介面,若想試試中文操作介面可改成如下url
https://<hostname or ip>:9443/vsphere-client/?locale=zh_TW
VMware vSphere Client
改英文 "C:\Program Files (x86)\VMware\Infrastructure\Virtual Infrastructure Client\Launcher\VpxClient.exe" -locale en_US
https://<hostname or ip>:9443/vsphere-client/?locale=zh_TW
VMware vSphere Client
改英文 "C:\Program Files (x86)\VMware\Infrastructure\Virtual Infrastructure Client\Launcher\VpxClient.exe" -locale en_US
2016年3月15日 星期二
Windows 2012R2 安裝 .net Framework 3.5 ?
安裝完 Windows 2012R2 之後,他會預設幫你裝上 Framework 4.0 但會沒裝 3.5 ,這會導致執行 asp.net 專案(IIS)或要安裝 Vmware Center 時缺少該環境而安裝失敗,底下就簡單的來說如何安裝 .net Framework 3.5 參閱:http://blog.xuite.net/tolarku/blog/312682066
Vmware 如何在第3層安裝64位元OS?
為了模擬公司虛擬架構,在公司1台Server安裝免費ESXi,然後在安裝ESXi 2台,在這2台下安裝VMware vCenter Server Appliance,可是開啟VCSA就說錯誤,想到說CPU要選 Inter VT-x/AMD-V指令虛擬化,點選後開機還是無法處理。
上網找了,終於可以了,步驟如下:
上網找了,終於可以了,步驟如下:
2015年8月14日 星期五
VMware 4.1: Hardware Status tab: An error occurred, please try again in another vSphere session?
最近開起VMware 4.1點選Hardware Status出現 An error occurred, please try again in another vSphere session?
2015年4月28日 星期二
如何刪除vmware esx 主機授權金鑰?
如何刪除vmware esx 主機授權金鑰?
必須打開ssh,用putty root帳號連入
vi /etc/vmware/vmware.lic
將裡面序號刪除存檔即可,主機不必從重開機。
必須打開ssh,用putty root帳號連入
vi /etc/vmware/vmware.lic
將裡面序號刪除存檔即可,主機不必從重開機。
2015年2月23日 星期一
如何建立含最新更新的 ESXi ISO 映像檔
參考
http://www.weithenn.org/2015/02/create-esxi-iso-all-patchs.html
簡單說明:
1.安裝VMware vSphere PowerCLI 5.8 Release 1。
2.使用「以系統管理員身分執行」的方式開啟 VMware vSphere PowerCLI。
3.因為「預設」情況下 PowerShell 並不允許執行 Scripts,執行Set-ExecutionPolicy RemoteSigned之後重新啟動 VMware vSphere PowerCLI。
4.將最新的安全性更新「ESXi550-201502001.zip (Build Number 2456374)」下載後存放至「C:\tmp」資料夾當中。
5.cd \tmp,執行 Add-EsxSoftwareDepot ESXi550-201502001.zip。
http://www.weithenn.org/2015/02/create-esxi-iso-all-patchs.html
簡單說明:
1.安裝VMware vSphere PowerCLI 5.8 Release 1。
2.使用「以系統管理員身分執行」的方式開啟 VMware vSphere PowerCLI。
3.因為「預設」情況下 PowerShell 並不允許執行 Scripts,執行Set-ExecutionPolicy RemoteSigned之後重新啟動 VMware vSphere PowerCLI。
4.將最新的安全性更新「ESXi550-201502001.zip (Build Number 2456374)」下載後存放至「C:\tmp」資料夾當中。
5.cd \tmp,執行 Add-EsxSoftwareDepot ESXi550-201502001.zip。
6.執行 Get-EsxImageProfile | ft -AutoSize,確認稍後要建立 ESXi ISO 映像檔的名稱。此實作環境映像檔名稱為「ESXi-5.5.0-20150204001-standard」。
7.鍵入指令 Export-EsxImageProfile -ImageProfile ESXi-5.5.0-20150204001-standard -ExportToISO -FilePath ESXi-5.5.0-2456374.iso,便會建立名稱為「ESXi-5.5.0-2456374.iso」的 ESXi ISO 安裝映像檔。
2015年1月19日 星期一
安裝vcenter server appliance出現網卡為0.0.0.0時,如何處理?
第1次安裝vcenter server appliance,deploy OVF Template完成,出現0.0.0.0:5480,不知到如何設定網卡
2015年1月12日 星期一
Vmware Tools install Nested ESXi datastore
為了test ESXi 5.5,所以在esxi 5.5 install esxi5.5,但是如何在 Nested ESXi datastore install VMware Tools。
2014年12月26日 星期五
VMcenter 5.5 使用英文?
之前抱怨VMcenter沒有繁體中文,導致英文看不懂,可是5.5後開始有繁體中文,卻用不習慣,要如何改回英文呢?
在VMcenter捷徑按右鍵,選內容,在目標"C:\Program Files (x86)\VMware\Infrastructure\Virtual Infrastructure Client\Launcher\VpxClient.exe"後面加上 -locale en_US即
"C:\Program Files (x86)\VMware\Infrastructure\Virtual Infrastructure Client\Launcher\VpxClient.exe" -locale en_US
執行它就是英文了。
在VMcenter捷徑按右鍵,選內容,在目標"C:\Program Files (x86)\VMware\Infrastructure\Virtual Infrastructure Client\Launcher\VpxClient.exe"後面加上 -locale en_US即
"C:\Program Files (x86)\VMware\Infrastructure\Virtual Infrastructure Client\Launcher\VpxClient.exe" -locale en_US
執行它就是英文了。
2014年12月18日 星期四
將Esxi Patch to ISO?
ESXi
有很多Patch
,安裝後還需要上Patch,很麻煩,乾脆把Patch做成ISO。
首先下載安裝VMware-PowerCLI-5.8.0-2057893,執行時出現錯誤,執行Set-ExecutionPolicy
RemoteSigned,內定Y就好,重新執行VMware
vSphere PowerCLI。
先將patch下載ESXi550-201412001.zip
執行add-esxsoftwaredepot
C:\EZCloud\ESXi550-201412001.zip
執行get-esximageprofile
| select name
將ESXi-xxxxx-standard
複製起來
執行export-esximageprofile
-imageprofile ESXi-5.5.0-20141204001-standard -exporttoiso -filepath
c:\EZCloud\esxi5.5.201412.iso
ESXi-5.5.0-20141204001-standard—複製的東西
c:\EZCloud\esxi5.5.201412.iso--完成後放置的位置及名稱
2014年10月22日 星期三
guest vm強制關機的方法?
原出處:
http://www.ntueees.tp.edu.tw/wordpress/?p=1353
因將guest power off,但只跑到95%就不動了
只好下指令關機
進入esxi用putty
esxcli vm process list
list出目前esxi所有資訊,最主要看guest os World ID
esxcli vm process kill --type=soft --world-id=WorldNumber
esxcli vm process kill --type=[soft,hard,force] --world-id=WorldNumber
刪除guest os 服務
然後進入vmcenter檻是否關機,之後再開機,選正常開機即可。
http://www.ntueees.tp.edu.tw/wordpress/?p=1353
因將guest power off,但只跑到95%就不動了
只好下指令關機
進入esxi用putty
esxcli vm process list
list出目前esxi所有資訊,最主要看guest os World ID
esxcli vm process kill --type=soft --world-id=WorldNumber
esxcli vm process kill --type=[soft,hard,force] --world-id=WorldNumber
刪除guest os 服務
然後進入vmcenter檻是否關機,之後再開機,選正常開機即可。
訂閱:
文章 (Atom)