HPE iLO CLI 設定雜七雜八

重新開機 iLO

</>hpiLO-> reset map1

顯示 iLO 的 firmware 版本

</>hpiLO-> show /map1/firmware1 version

設定 iLO 內的主機名稱 Server Name

</>hpiLO-> cd /system1
</system1>hpiLO-> set oemhp_server_name=foo1

設定 iLO 內的系統名稱 System Name

</>hpiLO-> set /map1/enetport1 SystemName=bar1

顯示 iLO hostname

</system1>hpiLO-> show /map1/enetport1

/map1/enetport1
  Targets
    lanendpt1
  Properties
    Autosense=yes
    PermanentAddress=30:8d:99:xx:xx:xx
    LinkTechnology=Ethernet
    Speed=Auto
    SystemName=ROOM-H01-01-Bay01

設定 iLO hostname

</system1>hpiLO-> set /map1/enetport1 SystemName=R101-H01-01-Bay01

status=0
status_tag=COMMAND COMPLETED
Thu Mar  2 13:39:18 2023

Network settings change applied.


Settings change applied, iLO 4 will now be reset.
Logged Out: It may take several minutes before you can log back in.

設定機器 hostname

cd /system1
set oemhp_server_name=foo1
set oemhp_smh_fqdn=foo1.liho.tw
cd /map1/snmp1
set oemhp_imagenturl=foo1

設定 power 運作模式

</>hpiLO-> set /system1/oemhp_power1 oemhp_powerreg=max
or
</>hpiLO-> set /system1/oemhp_power1 oemhp_powerreg=dynamic

設定一次性網路開機

ssh root@192.168.xx.xx 'power on'
ssh root@192.168.xx.xx 'onetimeboot netdev1'
ssh root@192.168.xx.xx 'power reset'

一次性開機的選項

</>hpiLO-> help onetimeboot

status=0
status_tag=COMMAND COMPLETED
Tue Dec 27 09:48:11 2022


ONETIMEBOOT: The ONETIMEBOOT command is used to access the One-Time Boot
settings on the server.  The supported settings are a subset of
settings found in other interfaces.
Usage:
  onetimeboot               -- Displays the current state on the server.
  onetimeboot usb           -- Set to USB.
  onetimeboot ip            -- Set to Intelligent Provisioning.
  onetimeboot smartstartLX  -- Set to IP Smart Start Linux PE.
  onetimeboot netdev1       -- Set to Network Device 1.
  onetimeboot none          -- Disable One-Time Boot.

建立 root 管理者帳號

</>hpiLO-> create /map1/accounts1 username=root password=PASSWORD_CHANGE_ME name=root group=admin,config,oemhp_rc,oemhp_power,oemhp_vm

變更 密碼

</>hpiLO-> set /map1/accounts1/root password=NEWROOTPASSWORD