HPE 對 Gen10 之後優先建議 Redfish 與 iLOREST。先登入後列 types,再選正確 schema;不同 iLO firmware 回傳的 resource type 版本可能不同,不要把 selector 寫死。
登入、探索與安全登出
查看 iLOREST 版本iLOREST
ilorest --version對照 iLO firmware 與 HPE 支援矩陣。
查看內建說明iLOREST
ilorest help每個 macro command 再用 -h 看當版參數。
開啟互動模式iLOREST
ilorest互動模式可避免每條命令都重新登入。
登入遠端 iLOiLOREST interactive
login ilo01.corp.example -u ilo-operator -p <password>範例只是占位符;正式環境避免把真密碼留在 history。
列出可用 TypesiLOREST interactive
types不同 iLO generation/firmware 的 selector 版本不同。
查看目前 SelectioniLOREST interactive
select沒選對 schema 時 get 可能回空或命中多個 resource。
登出 Redfish SessioniLOREST interactive
logoutHPE 提醒 session 不登出可能逐步耗盡可用 session。
系統、機箱與散熱
查看 iLO 韌體版本iLOREST interactive
select Manager.
get FirmwareVersion尾端點號可避免選到 ManagerCollection。
查看 Manager JSONiLOREST interactive
select Manager.
get --json輸出可能含網路與硬體識別資訊。
查看伺服器型號與電源iLOREST interactive
select ComputerSystem.
get Model SerialNumber PowerState Status --jsonSerial number 屬資產資訊,限制分享。
查看機箱健康iLOREST interactive
select Chassis.
get Status PowerState --json多 chassis resource 時先加 filter。
查看溫度與風扇iLOREST interactive
select Thermal.
get Temperatures Fans --jsonresource 欄位依 Redfish schema;先 types/select 確認。
保存 Thermal JSONiLOREST interactive
save --selector Thermal. -f thermal-snapshot.json適合變更前後比較;檔案含硬體細節。
查看韌體 InventoryiLOREST interactive
select SoftwareInventory.
get Name Version Updateable --json系統可能有多個 inventory resource。
Storage、Log 與韌體檢查
尋找 Storage TypesiLOREST interactive
types | findstr /I "Storage Drive Volume"Linux/macOS 把 findstr 換成 grep -Ei。
查看 Storage JSONiLOREST interactive
select Storage.
get --json只讀盤點 controller、drive、volume 與 status。
查看 Integrated Management LogiLOREST
ilorest serverlogs --selectlog=IML --url ilo01.corp.example --user ilo-operator --password <password> --logout真密碼應改用受保護認證;輸出前先看 serverlogs -h。
下載 Active Health System LogiLOREST interactive
serverlogs --selectlog=AHSAHS 可能很大且含完整硬體事件,依 support 程序處理。
做 Firmware Integrity CheckiLOREST interactive
fwintegritycheck僅適用支援的 Gen10 以上;它不是 firmware update。
查看 Firmware Update 說明iLOREST
ilorest firmwareupdate -h先讀當版支援方式、TPM/reboot/install set 影響,不直接貼 update 命令。
啟用 Verbose 診斷iLOREST
ilorest -v help遇錯誤碼時短時間用 -v;debug log 可能含連線與環境資訊。
查看 iLOREST Return Code 文件瀏覽器/文件
https://servermanagementportal.ext.hpe.com/docs/redfishclients/ilorest-userguide/errors先按 return code 定位 authentication、schema、network 或 firmware 問題。
怎麼確認有做對
- Manager、ComputerSystem、Chassis、Thermal、Storage 的 Status 沒有異常。
- IML/AHS 事件時間和監控告警、硬體 LED、OS log 能對上。
- 每個遠端 session 都 logout,沒有真密碼留在腳本、history 或 log。
常見錯誤
- 把 iLO Web 密碼直接寫進批次檔。
- 不同 iLO generation 寫死同一個 schema version。
- 看到一顆硬碟 Warning 就直接更換,沒看 RAID/controller/predictive failure。
- 把 firmwareupdate、reboot 或 factorydefaults 當唯讀檢查。
常見問題
iLOREST 一定要把密碼放在 -p 嗎?
不是唯一選項。可用互動 session、certificate authentication、受保護設定或組織秘密管理流程;重點是不把真密碼留在 history、process list 或版本庫。
iLO 網頁顯示 Healthy 就不用看 IML 嗎?
還是要看。總體 Health 可能已恢復,但 IML 會留下電源、風扇、記憶體、硬碟、溫度與 firmware 的歷史事件。
延伸閱讀
版本與官方文件
參數會隨工具版本與作業系統實作改變。正式環境先用 --help、-h 或系統內建說明確認,再以當版官方文件為準。
常見問題
iLOREST 一定要把密碼放在 -p 嗎?
不是唯一選項。可用互動 session、certificate authentication、受保護設定或組織秘密管理流程;重點是不把真密碼留在 history、process list 或版本庫。
iLO 網頁顯示 Healthy 就不用看 IML 嗎?
還是要看。總體 Health 可能已恢復,但 IML 會留下電源、風扇、記憶體、硬碟、溫度與 firmware 的歷史事件。