VMWare and APC PowerChute
安裝、設定:
在 vCenter 中,經由 winscp 程式上傳安裝檔 tar.gz 至兩個 VMWare 的 hosts 。(PowerChute for VMWare 版本 3)
用 putty 連入 esx (以 root 帳號) 中,解壓縮並執行安裝 script。
安裝完會給一個網址,用來複製到瀏覽器開啟網頁,可設定 host 與 ups 的 connection 的值。記住選 single mode (一power接到一台 apc ups)或 redundant mode(一host有兩個power接到兩台 apc sua3000 ups),為此兩台帳號密碼最好設一樣。連接到 ups 後,就可以進入設定關機動作。
設定關機動作:經由 vCenter 開瀏覽器鍵入網址 https://your.static.ip.ip:6547/ (此頁面有個問號,可以按進去看說明),然後鍵入帳號密碼開始設定。
按 on battery 設勾選:Yes, I want to shut down the PCNS operating system.
Shut down the PCNS operating system only when the event lasts this long (seconds): 600 秒。(十分鐘後 power off 兩個 ups)
在 vCenter 中的設定:
注意:每個 vm 中的原本 powerchute 的自動關機設定可以不用移除。但設定 120 秒後自動關機,但不關 ups。
進入 vSphere Client > host > config > virtual machine startup/shutdown > properties > 勾選 allow virtual machine to start and stop with the system > default startup delay 設 120 秒 、default shutdown delay 設 180 秒,選 guest shutdown。
下面的 startup order 可以將兩個 vm 都按 move up ,以便移到 automatic startup 群組裏。