NAV
Shell

Overview

The RESTful Interface Tool is a command-line interface that allows you to manage Hewlett Packard Enterprise products that take advantage of RESTful APIs. For this release of the tool, you can manage HPE Gen9 servers running iLO 4 2.10 or later through iLO RESTful APIs. You can install the tool on your computer for remote use or you can install the tool locally on a server with a Windows OS or Linux OS. In addition to using the tool manually to execute individual commands, you can create scripts to automate tasks.

The RESTful Interface Tool can display and set parameters for the following:

Installation

Requirements

The requirements for the server, which you will manage with the tool, are as follows:

Installing the RESTful Interface Tool

Perform the following steps to install the tool in a Windows OS or Linux OS.

Windows

  1. Download the RESTful Interface Tool (Windows MSI package) from http://www.hpe.com/info/resttool.
  2. Install the package on the server you prefer to manage for local management. For remote management, install the package on a laptop or server that has access to the managed server network.

Linux

  1. Download the RESTful Interface Tool (Linux RPM package) from http://www.hpe.com/info/resttool.
  2. Install the installation package on the server you prefer to manage for local management. For remote management, install the package on a laptop or server that has access to the managed server network.

Starting the RESTful Interface Tool

Windows

  1. Click the Start menu.
  2. Click Hewlett Packard EnterpriseHPE RESTful Interface Tool.
  3. Right-click the HPE RESTful Interface Tool prompt, and then click Run as Administrator.

Linux

  1. Open a terminal window.
  2. Run the following command as an administrator to start interactive mode: /usr/sbin/ilorest

Using the RESTful Interface Tool

RESTful Interface Tool Modes of Operation

The RESTful Interface Tool has three modes of operation. By default, the interactive mode is utilized when you start the RESTful Interface Tool. With scriptable mode, you can use a script that gives commands to the RESTful Interface Tool. The file-based mode allows you to use a script that gives commands to the RESTful Interface Tool and uses a file to load and save settings.

Interactive Mode

Interactive mode is started when you run the RESTful Interface Tool without any command-line parameters. The ilorest > prompt is displayed and you can enter commands one at a time. You can exit the interactive mode by entering the exit command at the prompt. On Windows systems, double-click ilorest.exe to start an interactive session. You must be an administrator to run ilorest.exe.

Interactive Mode

Scriptable Mode

The following script retrieves information regarding the Bios type:

:: This is a batch file that logs into a remote server,
:: selects the Bios type, and gets the BootMode value

:: Usage :: 
:: selectget.bat [URI] [USERNAME] [PASSWORD] 
@echo off

set argC=0
for %%x in (%*) do Set /A argC+=1
if %argC% LSS 3 goto :failCondition
goto :main

:failCondition
@echo Usage:
@echo selectget.bat [URI] [USERNAME] [PASSWORD]
goto :EOF

:main
@echo *****************************************
@echo ************* Logging in... *************
@echo *****************************************
ilorest.exe login %1 -u %2 -p %3
@echo *****************************************
@echo ******* selecting Bios type... ********
@echo *****************************************
ilorest.exe select Bios.
@echo *****************************************
@echo ********** getting BootMode... **********
@echo *****************************************
ilorest.exe get BootMode
pause

You can use the scriptable mode to script all the commands using an external input file. The script contains a list of the RESTful Interface Tool command lines that let users get and set properties of server objects.

In this example, first the Bios type is selected, and then the get command is used to retrieve information about the BootMode property of Bios.

File-based mode

The following script allows you to save, edit, and load a file to the server.

:: This a file-based edit mode helper for RESTful Interface Tool
:: 1. Run to download selected type to a file called ilorest.json
:: 2. Edit the ilorest.json file to make changes.
:: 3. Press any key running batch program to continue with program,
::    uploading the newly edited program to the server.

:: Usage ::
:: saveload.bat [SELECTOR] [FILENAME]
:: Specify a type with the SELECTOR tag, and
:: save to a file called FILENAME
@echo off
set argC=0
for %%x in (%*) do Set /A argC+=1
if %argC% LSS 2 goto :failCondition
goto :main

:failCondition
@echo Usage:
@echo saveload.bat [SELECTOR] [FILENAME]
@echo specify a type with the SELECTOR tag, and
@echo save to a file called FILENAME
goto :EOF

:main
ilorest.exe login
ilorest.exe save --selector=%1 --json -f %2
@echo Edit the file, then:
pause
ilorest.exe load -f %2

File-based mode allows you to save and load settings from a file. This is similar to the conrep.dat files used by CONREP. File-based mode supports the JSON format.

When the example script is run, the following result is produced:

File Mode example

Here, the Bios type is saved to a file called ilorest1.json. Then, after you modify any properties, the load command is used to make these changes on the server.

The properties of Bios can be edited here, and then loaded on the server. When the file is loaded on the server, changes to read-only values are not reflected. The full list in this example is truncated to save space.

After saving this configuration, the ilorest1.json file looks like this:

{
    {
        "Comments":{
            "Manufacturer": "HP",
            "Model": "ProLiant DL360 Gen9",
            "BIOSFamily": "P89",
            "BIOSDate": "05/03/2015"
        }
    },
    {
        "HpBios.1.2.0": {
            "/rest/v1/systems/1/bios/Settings": {
                "AcpiRootBridgePxm": "Enabled",
                "AcpiSlit": "Enabled",
                "AdminName": "Jean Kranz",
                ...
                "WakeOnLan": "Enabled"
            }
        }
    }
}

Executing commands in parallel

Run the following command to start an iLOrest session in 10 different iLO servers:

pdsh -R exec -w server[1-10] ilorest --cache-dir %h login ilo-%h -u username -p password.

When you run the example command, PDSH issues the following 10 commands in batch and background mode. For each command, the iLOrest tool saves the data in a different location. For example, for server1, the data is cached in directory server1, for server2, the data is cached in directory server2.

ilorest --cache-dir server1 login ilo-server1 -u username -p password

ilorest --cache-dir server2 login ilo-server2 -u username -p password

ilorest --cache-dir server3 login ilo-server3 -u username -p password

ilorest --cache-dir server4 login ilo-server4 -u username -p password

ilorest --cache-dir server5 login ilo-server5 -u username -p password

ilorest --cache-dir server6 login ilo-server6 -u username -p password

ilorest --cache-dir server7 login ilo-server7 -u username -p password

ilorest --cache-dir server8 login ilo-server8 -u username -p password

ilorest --cache-dir server9 login ilo-server9 -u username -p password

ilorest --cache-dir server10 login ilo-server10 -u username -p password

Now that an iLOrest session is created on each iLO, you can select, set, or get information from them.

The -R exec part of the example finds and locally executes the iLOrest executable. The -w server[1-10] part of the example replaces the string %h in the rest of the command with 1, 2, … 10.

pdsh -R exec --cache-dir server[1-10] ilorest <select, list, get or set> <Type or property>.

iLOrest uses a caching method to locally save servers’ data. To send iLOrest commands to many different systems at once remotely, you will need to specify a different cache directory for each of them. The following example uses PDSH, but any method of parallel scripting will work as long as you are specifying different cache directories.

Running iLOrest on multiple systems locally can be done using automation tools such as Ansible, Chef, and Puppet.

Configuration file (ilorest.conf)

Windows default configuration file

[ilorest]
#iLOrest reads the following environment variables, and applies them at runtime.  
#Note that they can be overridden by command line switches.

#####          Log Settings          #####
##########################################
# directory where iLOrest writes its log file
# logdir = .\ilorest_logs

#####         Cache Settings         #####
##########################################
# option to disable caching of all data
# cache = False

#####       Credential Settings      #####
##########################################
# option to use the provided url to login
# url = https://127.0.0.1

# option to use the provided username to login
# username = admin

# option to use the provided password to login
# password = password

#####         Commit Settings        #####
##########################################
# flag to commit in all places where applicable
# commit = True

#####    Output Default Settings     #####
##########################################
# flag to change output format in all places where applicable
# format = json

#####    Schema Default Settings     #####
##########################################
# directory where iLOrest will look for ilo schemas
# iloschemadir = .\

# directory where iLOrest will look for bios schemas
# biosschemadir = .\

#####  Default Save/Load Settings    #####
##########################################
# option to set default save output file
# savefile = ilorest.json

# option to set default load input file
# loadfile = ilorest.json

Linux default configuration file

[iLOrest]
#iLOrest reads the following environment variables, and applies them at runtime.  
#Note that they can be overridden by command line switches.

#####          Log Settings          #####
##########################################
# directory where iLOrest writes its log file
# logdir = /var/log/ilorest/

#####         Cache Settings         #####
##########################################
# option to disable caching of all data
# cache = False

#####       Credential Settings      #####
##########################################
# option to use the provided url to login
# url = https://127.0.0.1

# option to use the provided username to login
# username = admin

# option to use the provided password to login
# password = password

#####         Commit Settings        #####
##########################################
# flag to commit in all places where applicable
# commit = True

#####    Output Default Settings     #####
##########################################
# flag to change output format in all places where applicable
# format = json

#####    Schema Default Settings     #####
##########################################
# directory where iLOrest will look for ilo schemas
# iloschemadir = /usr/share/ilorest/

# directory where iLOrest will look for bios schemas
# biosschemadir = /usr/share/ilorest/

#####  Default Save/Load Settings    #####
##########################################
# option to set default save output file
# savefile = ilorest.json

# option to set default load input file
# loadfile = ilorest.json

The configuration file contains the default settings for the tool. You can use a text editor to change the behavior of the tool such as adding a server IP address, username, and password. The settings that you add or update in the configuration file are automatically loaded each time you start the tool.

Configuration file locations:

Higher Security Modes

This section describes how to set higher security modes and how to use the RESTful Interface Tool in these modes.

Setting iLO Higher Security Modes

To set security modes in RESTful Interface Tool, select the “HpeSecurityService.” type, and then set the “SecurityState” property to one of the allowed values and commit. Set Security 1

Using RESTful Interface Tool in iLO Higher Security Modes

RESTful Interface Tool in remote mode continues to function normally in higher security modes. To use RESTful Interface Tool locally in higher security modes, you must pass credentials along with your commands.

RESTful Interface Tool functions normally with higher security settings in remote mode. Set Security 2 To use RESTful Interface Tool locally in higher security modes, you must pass credentials to your commands. Set Security 3 If you do not pass the proper credentials in local mode, you receive a similar error. Set Security 4

A note on OS FIPS modes

RESTful Interface Tool 2.2 and greater have OS FIPS support. If an OS is set to enforce FIPS, RESTful Interface Tool uses a FIPS version of OpenSSL.

For users running from source that would like FIPS support, please see this link containing information on including this feature.

Commands for the RESTful Interface Tool

Global Options

This section lists all global options available.

-v, –verbose

Display verbose information.

-d, –debug

Display debug information.

–nocache

During execution the application will temporarily store data only in memory.

–nologo

Include to block copyright and logo.

–redfish

Use this flag if you wish to enable Redfish only compliance. It is enabled by default in systems with iLO5 and above.

–latestschema

Optionally use the latest schema instead of the one requested by the file.

–proxy=URL

Use the provided proxy for communication.

Global commands

This section includes commands as well as their usage and examples of general commands in the RESTful Interface Tool. They include commands used to do things such as listing help for using commands, viewing, retrieving, modifying, and committing changes to server properties, and authenticating and logging in and out of the server.

Help Command

Help example commands:

Entering help will list the global iLOrest options and all available commands.

iLOrest > help
Usage: iLOrest [GLOBAL OPTIONS] [COMMAND] [ARGUMENTS] [COMMAND OPTIONS]

Options:
  -h, --help            Show this help message and exit.
  -c FILE, --config=FILE
                        Use the provided configuration file instead of the
                        default one.
  --cache-dir=PATH      Use the provided directory as the location to cache
                        data (default location:
                        C:\Users\kocurema\AppData\Roaming\.iLOrest)

  GLOBAL OPTIONS:
    -v, --verbose       Display verbose information.
    -d, --debug         Display debug information.
    --logdir=PATH       Use the provided directory as the location for log
                        file.
    --nocache           During execution the application will temporarily
                        store data only in memory.
    --nologo            Include to block copyright and logo.
    --redfish           Use this flag if you wish to to enable Redfish only
                        compliance. It is enabled by default in systems with
                        iLO5 and above.
    --latestschema      Optionally use the latest schema instead of the one
                        requested by the file. Note: May cause errors in some
                        data retreval due to difference in schema versions.
    --proxy=URL         Use the provided proxy for communication.

BIOS COMMANDS
  biosdefaults                 - Set the currently logged in server to default
                                  BIOS settings.
  bootorder                    - Displays and sets the current boot order.
  iscsiconfig                  - Displays and configures the current iscsi
                                  settings.
  pending                      - Show the pending changes that will be applied
                                  on reboot.
  results                      - Show the results of changes which require a
                                  server reboot.
  setpassword                  - Sets the admin password and poweron password

COMMANDS
  commit                       - Applies all the changes made during the
                                  current session.
  get                          - Displays the current value(s) of a
                                  property(ies) within a selected type.
  info                         - Displays detailed information about a
                                  property within a selected type.
  list                         - Displays the current value(s) of a
                                  property(ies) within a selected type
                                  including reserved properties.
  load                         - Loads the server configuration settings from
                                  a file.
  login                        - Connects to a server, establishes a secure
                                  session, and discovers data from iLO.
  logout                       - Ends the current session and disconnects from
                                  the server.
  save                         - Saves the selected type's settings to a file.
  select                       - Selects the object type to be used.
  set                          - Changes the value of a property within the
                                  currently selected type.
  status                       - Displays all pending changes within a
                                  selected type that need to be committed.
  types                        - Displays all selectable types within the
                                  currently logged in server.
  exit                         - Exits from the interactive shell.
  help                         - Displays command line syntax and help menus
                                  for individual commands. Example: help login

RAW COMMANDS
  rawdelete                    - Raw form of the DELETE command.
  rawget                       - Raw form of the GET command.
  rawhead                      - Raw form of the HEAD command.
  rawpatch                     - Raw form of the PATCH command.
  rawpost                      - Raw form of the POST command.
  rawput                       - Raw form of the PUT command.

SMART ARRAY COMMANDS
  clearcontrollerconfig        - Clears smart array controller configuration.
  createlogicaldrive           - Creates a new logical drive on the selected
                                  controller.
  deletelogicaldrive           - Deletes logical drives from the selected
                                  controller.
  drivesanitize                - Erase/Sanitizes physical drives
  factoryresetcontroller       - Factory resets a controller by index or
                                  location.
  smartarray                   - Discovers all storage controllers installed
                                  in the server and managed by the
                                  SmartStorage.

iLO COMMANDS
  certificate                  - Command for importing both iLO and login
                                  authorization certificates as well as
                                  generating iLO certificate signing requests
  clearrestapistate            - Clears the persistent state of the REST API.
                                  Some portions of the API may not be available
                                  until after the server reboots.
  directory                    - Update directory settings, add/delete
                                  directory roles, and test directory settings.
  disableilofunctionality      - disables iLO's accessibility via the network
                                  and resets iLO. WARNING: This should be used
                                  with caution as it will render iLO unable to
                                  respond to further network operations
                                  (including REST operations) until iLO is
                                  re-enabled using the RBSU menu.
  eskm                         - Command for all ESKM available actions.
  factorydefaults              - Resets iLO to factory defaults. WARNING: user
                                  data will be removed use with caution.
  fwintegritycheck             - Perform a firmware integrity check on the
                                  currently logged in server.
  firmwareupdate               - Perform a firmware update on the currently
                                  logged in server.
  iloaccounts                  - Adds / deletes an iLO account on the
                                  currently logged in server.
  backuprestore                - Backup and restore iLO to a server using a
                                  .bak file.
  iloclone                     - Clone the iLO config of the currently logged
                                  in server and copy it to the server in the
                                  arguments.
  ilofederation                - Adds / deletes an iLO federaion group on the
                                  currently logged in server.
  ilolicense                   - Adds an iLO license key to the currently
                                  logged in server.
  iloreset                     - Reset iLO on the current logged in server.
  ipprofiles                   - This is used to manage hpeipprofile data
                                  store.
  onebuttonerase               - Performs One Button Erase on a system .
  reboot                       - Reboot operations for the current logged in
                                  server.
  sendtest                     - Command for sending various tests to iLO.
  serverclone                  - Creates a JSON formated clone file of a
                                  system's iLO, Bios, and SSA configuration
                                  which can be duplicated onto other systems.
                                  User editable JSON file can be manipulated to
                                  modify settings before being loaded onto
                                  another machine.
  serverinfo                   - Shows aggregate health status and details of
                                  the currently logged in server.
  serverlogs                   - Download and perform log operations.
  serverstate                  - Returns the current state of the server.
  sigrecompute                 - Command to recalculate the signature of the
                                  computer's configuration.
  singlesignon                 - Command for all single sign on available
                                  actions.
  virtualmedia                 - Command for inserting and removing virtual
                                  media.

iLO REPOSITORY COMMANDS
  deletecomp                   - Deletes components/binaries from the iLO
                                  Repository.
  downloadcomp                 - Downloads components/binaries from the iLO
                                  Repository.
  flashfwpkg                   - Flashes fwpkg components using the iLO
                                  repository.
  installset                   - Manages install sets for iLO.
  listcomp                     - Lists components/binaries from the iLO
                                  Repository.
  maintenancewindow            - Manages the maintenance windows for iLO.
  makeinstallset               - Creates install sets for iLO.
  taskqueue                    - Manages the update task queue for iLO.
  uploadcomp                   - Upload components/binary to the iLO
                                  Repository.

Providing a specific command will list help regarding that specific command.

iLOrest > help login
Usage: login [URL] [OPTIONS]

        To login remotely run using iLO url and iLO credentials
        example: login  -u  -p 

        To login on a local server run without arguments
        example: login

Options:
  -h, --help            show this help message and exit
  -u USER, --user=USER  If you are not logged in yet, including this flag
                        along with the password and URL flags can be used to
                        log into a server in the same command.
  -p PASSWORD, --password=PASSWORD
                        Use the provided iLO password to log in.
  --includelogs         Optionally include logs in the data retrieval process.
  --selector=SELECTOR   Optionally include this flag to select a type to run
                        the current command on. Use this flag when you wish to
                        select a type without entering another command, or if
                        you wish to work with a type that is different from
                        the one you currently have selected.
  --path=PATH           Optionally set a starting point for data collection
                        during login. If you do not specify a starting point,
                        the default path will be /redfish/v1/. Note: The path
                        flag can only be specified at the time of login.
                        Warning: Only for advanced users, and generally not
                        needed for normal operations.
  --biospassword=BIOSPASSWORD
                        Select this flag to input a BIOS password. Include
                        this flag if second-level BIOS authentication is
                        needed for the command to execute. This option is only
                        used on Gen 9 systems.

The alternate syntax to list details regarding a command is -h.

iLOrest > login -h
Usage: login [URL] [OPTIONS]

        To login remotely run using iLO url and iLO credentials
        example: login  -u  -p 

        To login on a local server run without arguments
        example: login

Options:
  -h, --help            show this help message and exit
  -u USER, --user=USER  If you are not logged in yet, including this flag
                        along with the password and URL flags can be used to
                        log into a server in the same command.
  -p PASSWORD, --password=PASSWORD
                        Use the provided iLO password to log in.
  --includelogs         Optionally include logs in the data retrieval process.
  --selector=SELECTOR   Optionally include this flag to select a type to run
                        the current command on. Use this flag when you wish to
                        select a type without entering another command, or if
                        you wish to work with a type that is different from
                        the one you currently have selected.
  --path=PATH           Optionally set a starting point for data collection
                        during login. If you do not specify a starting point,
                        the default path will be /redfish/v1/. Note: The path
                        flag can only be specified at the time of login.
                        Warning: Only for advanced users, and generally not
                        needed for normal operations.
  --biospassword=BIOSPASSWORD
                        Select this flag to input a BIOS password. Include
                        this flag if second-level BIOS authentication is
                        needed for the command to execute. This option is only
                        used on Gen 9 systems.

Syntax

help [command] [optional parameters]

Description

Displays command-line syntax and help menus for individual commands. Use this command if you want to know more about a command or need help using a command. Alternatively, you can use the help command without specifying a particular command if you wish to see all the available commands and options.

Parameters

Supplying a command to help will display the help message corresponding to the given command, as well as the options relating to that particular command.

Running the help command with the –h or –help command will display information on how to use the help command.

Use the provided configuration file instead of the default one.

Use the provided directory as the location to cache data (default location: C:\Users\USERNAME\AppData\Roaming\.ilorest).

Inputs

None

Outputs

None

Login command

Login example commands:

To login remotely, supply the URL, username, and password for the server.

iLOrest > login xx.xx.xx.xx -u username -p password
Discovering data...Done

Here the selector option has been included so that the Bios type is selected once the user is logged in. You can prove that the Bios type has indeed been selected when we enter the select command.

iLOrest > login xx.xx.xx.xx -u username -p password --select Bios.
Discovering data...Done
iLOrest > select
Current selection: Bios.v1_0_0

Here the URL, username, and password information are not specified here or in the configuration file, and the server was logged in to locally.

iLOrest > login
Discovering data...Done

Syntax

login [URL] [User] [Password] [Optional Parameters]

Description

Connects to a server, establishes a secure session, and discovers data from iLO. If you are logging in to a local server, run the command without arguments. If you are not logging in to a local server, supply the URL argument along with the user and password options.

Usage in Other Commands

Login remotely as part of other commands by including the –url, (-u, –user), and (-p, –password) flags. Locally you will be logged in automatically unless running in higher security modes (see Higher Security Modes).

Parameters

Connect to the server located at the provided URL.

Including the help flag on this command will display help on the usage of this command.

Connect to the server as the provided user.

Connect to the server with the password corresponding to the given user.

Optionally choose to set the includelogs flag. Doing so will include logs in the data retrieval process.

Optionally including the selector flag allows you to select a type to run while running the current command. Use this flag when you wish to select a type without entering another command, or if you wish to work with a type that is different from the one you currently have selected.

Optionally set a starting point for data collection. If you do not specify a starting point, the default path will be /rest/v1.

Select this flag to input a BIOS password. Include this flag if second-level BIOS authentication is needed for the command to execute.

Types command

Types example commands:

This command will list all the available types that you can select. The full list has been truncated for space.

iLOrest > login xx.xx.xx.xx -u username -p password
Discovering data...Done
iLOrest > types
Type options:
AccountService.v1_3_0
Bios.v1_0_0
CertificateCollection
Chassis.v1_6_0
ChassisCollection
ComputerSystem.v1_4_0
ComputerSystemCollection
EthernetInterface.v1_4_1
EthernetInterfaceCollection
EventDestinationCollection
EventService.v1_0_8
HostInterface.v1_1_1
HostInterfaceCollection
HpeBaseConfigs.v2_0_0
HpeBaseNetworkAdapter.v2_0_0
HpeBaseNetworkAdapterCollection
HpeBiosMapping.v2_0_0
HpeCertAuth.v1_1_0
HpeCertificate.v1_0_0
HpeCertificateCollection
HpeComponent.v1_0_1
HpeComponentCollection
HpeComponentInstallSet.v1_0_3
HpeComponentInstallSetCollection
HpeComponentUpdateTaskQueueCollection
HpeDirectoryTest.v1_0_0
HpeESKM.v2_0_0
...

This command simultaneously logs in to the server at the provided URL with the provided username and password, and list all the available types that you can select. The full list has been truncated here for space.

iLOrest > types --url xx.xx.xx.xx -u username -p password
Discovering data...Done
Type options:
AccountService.v1_3_0
Bios.v1_0_0
CertificateCollection
Chassis.v1_6_0
ChassisCollection
ComputerSystem.v1_4_0
ComputerSystemCollection
EthernetInterface.v1_4_1
EthernetInterfaceCollection
EventDestinationCollection
EventService.v1_0_8
HostInterface.v1_1_1
HostInterfaceCollection
HpeBaseConfigs.v2_0_0
HpeBaseNetworkAdapter.v2_0_0
HpeBaseNetworkAdapterCollection
HpeBiosMapping.v2_0_0
HpeCertAuth.v1_1_0
HpeCertificate.v1_0_0
HpeCertificateCollection
HpeComponent.v1_0_1
HpeComponentCollection
HpeComponentInstallSet.v1_0_3
HpeComponentInstallSetCollection
HpeComponentUpdateTaskQueueCollection
HpeDirectoryTest.v1_0_0
HpeESKM.v2_0_0
...

Adding the fulltypes option will return the full type name instead of the default simplified versions. This is only available on Redfish systems.

iLOrest > types --fulltypes
Type options:
#AccountService.v1_3_0.AccountService
#Bios.v1_0_0.Bios
#CertificateCollection.CertificateCollection
#Chassis.v1_6_0.Chassis
#ChassisCollection.ChassisCollection
#ComputerSystem.v1_4_0.ComputerSystem
#ComputerSystemCollection.ComputerSystemCollection
#EthernetInterface.v1_4_1.EthernetInterface
#EthernetInterfaceCollection.EthernetInterfaceCollection
#EventDestinationCollection.EventDestinationCollection
#EventService.v1_0_8.EventService
#HostInterface.v1_1_1.HostInterface
#HostInterfaceCollection.HostInterfaceCollection
#HpeBaseConfigs.v2_0_0.HpeBaseConfigs
#HpeBaseNetworkAdapter.v2_0_0.HpeBaseNetworkAdapter
#HpeBaseNetworkAdapterCollection.HpeBaseNetworkAdapterCollection
#HpeBiosMapping.v2_0_0.HpeBiosMapping
#HpeCertAuth.v1_1_0.HpeCertAuth
#HpeCertificate.v1_0_0.HpeCertificate
#HpeCertificateCollection.HpeCertificateCollection
#HpeComponent.v1_0_1.HpeComponent
#HpeComponentCollection.HpeComponentCollection
#HpeComponentInstallSet.v1_0_3.HpeComponentInstallSet
#HpeComponentInstallSetCollection.HpeComponentInstallSetCollection
#HpeComponentUpdateTaskQueueCollection.HpeComponentUpdateTaskQueueCollection
#HpeDirectoryTest.v1_0_0.HpeDirectoryTest
#HpeESKM.v2_0_0.HpeESKM
...

Syntax

types [Optional Parameters]

Description

The types command displays all selectable types available within the currently logged in server. Types include a name as well as version information. Types represent the schema used for the resource and indicate the version of the schema. Version information is major.minor.errata (for example: SystemRoot.0.9.5). Major versions are not backwards compatible, but everything else is.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to login to a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Optionally choose to set the includelogs flag. Doing so will include logs in the data retrieval process.

Optionally set a starting point for data collection. If you do not specify a starting point, the default path will be/rest/v1.

Optionally include this flag if you would prefer to return the full type name instead of the simplified versions.

Inputs

None

Outputs

None

Select command

Select example commands:

This command simultaneously logs in to the server at the provided URL (–url) with the provided username (-u) and password (-p), and selects the ComputerSystem. type.

iLOrest > select ComputerSystem. --url xx.xx.xx.xx -u username -p password
Discovering data...Done
iLOrest > select
Current selection: ComputerSystem.v1_4_0

Running the select command with no argument will return the current selection.

iLOrest > select
Error: No type currently selected. Please use the 'types' command to
get a list of types, or pass your type by using the '--selector' flag.
iLOrest > select Bios.
iLOrest > select
Current selection: Bios.v1_0_0

Adding a period after the type selected, Bios, limits the selection, preventing accidentally also selecting anything else starting with Bios. This also removes the need to include the version.

iLOrest > select Bios
iLOrest > select
Current selection: HpeBiosMapping.v2_0_0, Bios.v1_0_0
iLOrest > select Bios.
iLOrest > select
Current selection: Bios.v1_0_0

iLOrest caches data once a type has been selected for the first time. To refresh a type with the most up to date information use the --refresh option.

iLOrest > select ComputerSystem.
iLOrest > get Oem/Hpe/PowerOnMinutes
Oem=
     Hpe=
          PowerOnMinutes=814088
iLOrest > select ComputerSystem. --refresh
iLOrest > get Oem/Hpe/PowerOnMinutes
Oem=
     Hpe=
          PowerOnMinutes=814089

Syntax

select [Type] [Optional Parameters]

Description

Use select to choose a specific type to work with. Eligible types for selection are those listed by the types command. Because commands are entered individually in the RESTful Interface Tool, working with specific types requires that you highlight or select the particular type you are working with. Use the select command to highlight a type so that you can work with it.

Usage in Other Commands

Select a type from another command by including the (–select, –selector) option flag followed by the type to select. Not all commands have the select flag, run help on the command to see available options.

Parameters

Specify the type you want to select. Omitting a type to select will cause select to display the currently selected type.

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to login to a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Optionally choose to set the includelogs flag. Doing so will include logs in the data retrieval process.

Optionally set a starting point for data collection. If you do not specify a starting point, the default path will be/rest/v1.

Select this flag to input a BIOS password. Include this flag if second-level BIOS authentication is needed for the command to execute.

Inputs

None

Outputs

None

List command

List command examples:

With a Type selected, run the command without arguments to list all properties within the selected type, including reserved properties. The full list has been truncated here for space.

iLOrest > select Bios.
iLOrest > list
@odata.context=/redfish/v1/$metadata#Bios.Bios
@odata.etag=W/"02E13BA89B606F6F6F02950EB3CA676D"
@odata.id=/redfish/v1/systems/1/bios/settings/
@odata.type=#Bios.v1_0_0.Bios
AcpiHpet=Enabled
AcpiRootBridgePxm=Enabled
AcpiSlit=Enabled
AdjSecPrefetch=Enabled
AdminEmail=""
AdminName=""
AdminOtherInfo=""
AdminPhone=""
AdvCrashDumpMode=Disabled
AdvancedMemProtection=AdvancedEcc
AsrStatus=Enabled
AsrTimeoutMinutes=Timeout10
AssetTagProtection=Unlocked
AttributeRegistry=BiosAttributeRegistryU32.v1_2_10
AutoPowerOn=RestoreLastState
BootMode=Uefi
...

Including the -j,--json option preserves the JSON structure of the type’s information. The full list has been truncated here for space.

iLOrest > select ComputerSystem.
iLOrest > list --json
{
  "@odata.context": "/redfish/v1/$metadata#ComputerSystem.ComputerSystem",
  "@odata.etag": "W/\"9D48B4B7\"",
  "@odata.id": "/redfish/v1/Systems/1/",
  "@odata.type": "#ComputerSystem.v1_4_0.ComputerSystem",
  "Actions": {
    "#ComputerSystem.Reset": {
      "ResetType@Redfish.AllowableValues": [
        "On",
        "ForceOff",
        "ForceRestart",
        "Nmi",
        "PushPowerButton"
      ],
      "target": "/redfish/v1/Systems/1/Actions/ComputerSystem.Reset/"
    }
  },
  "AssetTag": "",
  "Bios": {
    "@odata.id": "/redfish/v1/systems/1/bios/"
  },
  "BiosVersion": "U32 v2.10 (12/14/2018)",
  "Boot": {
    "BootSourceOverrideTarget": "None",
    "BootSourceOverrideTarget@Redfish.AllowableValues": [
      "None",
      "Cd",
      "Hdd",
...

To return specific properties or sub-properties include them as arguments. If the property you want to return is a sub-property add them in the form Property/Sub-property.

iLOrest > list @odata.id Boot/BootSourceOverrideMode AssetTag
@odata.id=/redfish/v1/Systems/1/
AssetTag=""
Boot=
      BootSourceOverrideMode=UEFI

Syntax

list [Property(s)] [Optional Parameters]

Description

Displays the current values of the properties of a selected type including reserved properties in human-readable and optionally JSON formats. Optionally include arguments to only return the values of those properties.

Parameters

Supplying a property or multiple properties will cause list to display the current value for that particular property or properties. Otherwise, if you wish to retrieve all the properties, run without arguments. Use this command only after a type has already been selected. If the value you are looking up is not available, it will return with no contents found for that property entry.

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to login to a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Optionally choose to set the includelogs flag. Doing so will include logs in the data retrieval process.

Optionally set a filter value for a filter attribute. This uses the provided filter for the currently selected type.

Optionally include this flag if you wish to change the displayed output to JSON format. Preserving the JSON data structure can make the information easier to parse.

Optionally set a starting point for data collection. If you do not specify a starting point, the default path will be /rest/v1.

Optionally include the logout flag to log out of the server after this command is completed. You need to be logged in to use this flag.

Inputs

None

Outputs

None

Info Command

Info command examples:

Omitting a property when using the info command causes info to list all available options, given that you have already selected a type. The full list has been truncated for space.

iLOrest > select Bios.
iLOrest > info
Info options:
AcpiHpet
AcpiRootBridgePxm
AcpiSlit
AdjSecPrefetch
AdminEmail
AdminName
AdminOtherInfo
AdminPhone

This command simultaneously logs in to the server at the provided URL (–url) with the provided username (-u) and password (-p), selects the Power. type, and displays the PowerSupplies information.

iLOrest > info PowerSupplies -u username -p password --url xx.xx.xx.xx --select Power.
Discovering data...Done

NAME
    PowerSupplies


DESCRIPTION
    Details of the power supplies associated with this system or
    device


TYPE
    array


READ-ONLY
    True


SUB-PROPERTIES
    Redundancy, Name, SerialNumber, MemberId, @odata.id,
    PowerCapacityWatts, Model, PartNumber, Status,
    LastPowerOutputWatts, SparePartNumber, RelatedItem,
    LineInputVoltageType, Oem, PowerSupplyType, LineInputVoltage,
    FirmwareVersion, Manufacturer

Multiple properties under the VirtualMedia type are specified. By passing multiple properties, it returns the information on all of the properties passed.

iLOrest > select VirtualMedia.
iLOrest > info Image WriteProtected

NAME
    Image


DESCRIPTION
    The valid URI indicating the image that is mounted on this server.
    A null value indicates that no image exists.


TYPE
    string
    null


READ-ONLY
    False


**************************************************

NAME
    WriteProtected


DESCRIPTION
    Indicates whether the virtual media is protected against write
    operations.


TYPE
    boolean
    null


READ-ONLY
    False


POSSIBLE VALUES
    True or False

Any Sub-Properties shown in an info response can be queried in the same form as set, list, and get: Property/Sub-property.

iLOrest > select ComputerSystem.
iLOrest > info Boot

NAME
    Boot


DESCRIPTION
    The boot information for the current resource.


TYPE
    object


READ-ONLY
    False


SUB-PROPERTIES
    BootSourceOverrideTarget,
    BootSourceOverrideTarget@Redfish.AllowableValues,
    BootSourceOverrideEnabled, BootSourceOverrideMode,
    UefiTargetBootSourceOverride@Redfish.AllowableValues,
    UefiTargetBootSourceOverride
iLOrest > info Boot/BootSourceOverrideTarget

NAME
    BootSourceOverrideTarget


DESCRIPTION
    The current boot source to be used at next boot instead of the
    normal boot device, if BootSourceOverrideEnabled is true.


TYPE
    string
    null


READ-ONLY
    False

Syntax

info [Property(s)] [Optional Parameters]

Description

Displays detailed information about a property within a selected type. Information displayed includes the data type of the value, if the property is read-only or not, a brief description, possible values, and any sub-properties associated with the property.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to login to a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Optionally choose to set the includelogs flag. Doing so will include logs in the data retrieval process.

Optionally use the latest schema instead of the one requested by the file.

Optionally include this flag if you wish to change the displayed output to JSON format. Preserving the JSON data structure makes the information easier to read.

Optionally set a starting point for data collection. If you do not specify a starting point, the default path will be /rest/v1.

Optionally include the logout flag to log out of the server after this command is completed. You need to be logged in to use this flag.

Inputs

None

Outputs

None

Get command

Get example commands:

Using get without any property specified shows the properties of the selected type. The full list is truncated for space.

iLOrest > select Bios.
iLOrest > get
AcpiHpet=Enabled
AcpiRootBridgePxm=Enabled
AcpiSlit=Enabled
AdjSecPrefetch=Enabled
AdminEmail=""
AdminName=Michael L
AdminOtherInfo=""
AdminPhone=""
...

Using get with a specific property lists the current value of that property, given that a type has already been selected.

iLOrest > get AdminName
AdminName=Jason E

This command simultaneously logs in to the server at the provided URL (–url) with the provided username (-u) and password (-p), selects the Bios. type, and the get command is used to retrieve the BootOrderPolicy property of Bios.

iLOrest > get BootOrderPolicy --url xx.xx.xx.xx -u username -p password --select Bios.
Discovering data...Done
BootOrderPolicy=RetryIndefinitely

Because the logout flag was included, the user is logged out of the server after the get command is performed.

iLOrest > select ComputerSystem.
iLOrest > get AssetTag --logout
AssetTag=""
Logging session out.

Any Sub-Properties shown can be queried in the same form as set, list, and info: Property/Sub-property. You can also specify multiple properties to get simultaneously.

iLOrest > select ComputerSystem.
iLOrest > get MemorySummary
MemorySummary=
               Status=
                       HealthRollup=OK
               TotalSystemPersistentMemoryGiB=0
               TotalSystemMemoryGiB=32
iLOrest > get MemorySummary/Status MemorySummary/TotalSystemMemoryGiB AssetTag
AssetTag=""
MemorySummary=
               Status=
                       HealthRollup=OK
               TotalSystemMemoryGiB=32

You can use the noreadonly flag to narrow down your results to only properties that can be changed.

iLOrest > select ComputerSystem.
iLOrest > get
AssetTag=""
BiosVersion=U32 v2.10 (12/14/2018)
Boot=
      BootSourceOverrideTarget=None
      BootSourceOverrideTarget@Redfish.AllowableValues=None
                                                        Cd
                                                        Hdd
                                                        Usb
                                                        SDCard
                                                        Utilities
                                                        Diags
                                                        BiosSetup
                                                        Pxe
                                                        UefiShell
                                                        UefiHttp
                                                        UefiTarget
      BootSourceOverrideEnabled=Disabled
...
iLOrest > get --noreadonly
AssetTag=""
Boot=
      BootSourceOverrideTarget=None
      BootSourceOverrideEnabled=Disabled
      BootSourceOverrideMode=Legacy
      UefiTargetBootSourceOverride=None
HostName=ahostname
IndicatorLED=Unknown
Oem=
     Hpe=
          EndOfPostDelaySeconds=None
          PowerOnDelay=Minimum
          ServerFQDN=""
          PowerAutoOn=RemainOff
          PostMode=None
          ProcessorJitterControl=
                                  Mode=Auto
          PostDiscoveryMode=None
          PowerRegulatorMode=OSControl

Syntax

get [Property(s)] [Optional Parameters]

Description

Displays the current value of a property of the currently selected type. Use this command only after a type has already been selected. If the value you are looking up is not available, it will return with no contents found for that property entry.

Parameters

Supplying a property or multiple properties will cause get to display the current value for that particular property or properties. Otherwise, if you wish to retrieve all the properties, run without arguments. This is still assuming you have a type already selected.

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to login to a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Optionally include this flag to set the includelogs flag. This will include logs in the data retrieval process.

-–selector=SELECTOR

Optionally including the selector flag allows you to select a type to run while running the current command. Use this command to select a type without entering another command, or to work with a type that is different from the one currently selected.

Optionally include to set a filter value for a filter attribute. This uses the provided filter for the currently selected type.

Optionally include this flag to change the displayed output to JSON format. Preserving the JSON data structure makes the information easier to read.

Optionally include this flag to set a starting point for data collection. If you do not specify a starting point, the default path will be /rest/v1.

Optionally include the logout flag to log out of the server after this command is completed. You need to be logged in to use this flag.

Optionally include this flag to display properties that are not read-only. This is useful to see what is configurable with the selected type(s).

Inputs

None

Outputs

None

Set command

Set example commands:

You can set multiple properties from the same type simultaneously. Add quotes around the property and value to add spaces in the value.

iLOrest > select Bios.
iLOrest > get AdminName ServiceName
AdminName=""
ServiceName=""
iLOrest > set "AdminName=Jason E" ServiceName=ExampleService
iLOrest > get AdminName ServiceName
AdminName=Jason E
ServiceName=ExampleService

This command simultaneously logs in to the server at the provided URL (–url) with the provided username (-u) and password (-p), selects the Bios. type, the set command is used to set the AdminName property to Jason E, and the commit flag has been added to apply the changes to the server.

iLOrest > set "AdminName=Jason E" --url xx.xx.xx.xx -u username -p password --select Bios. --commit
Discovering data...Done
Committing changes...
One or more properties were changed and will not take effect until system is reset.

To revert your changes on a type you can use the refresh flag.

iLOrest > select Bios.
iLOrest > get AdminName
AdminName=Jason E
iLOrest > set AdminName=JohnDoe
iLOrest > get AdminName
AdminName=JohnDoe
iLOrest > select Bios. --refresh
iLOrest > get AdminName
AdminName=Jason E

Description

Changes the value of a property in a currently selected type. Multiple properties can be set simultaneously.

Syntax

set [Property=Value] [Path] [Optional Parameters]

Correct syntax. This sets the AdminName to John.

Correct syntax. If the property has a space in it, use quotes around the entire property/value pair. Here the AdminName has been set to John Doe.

Correct syntax. Use this syntax if you wish to remove the AdminName property value, using quotes that have nothing between them.

Correct syntax. This is an alternate syntax that also removes the AdminName property and sets it to nothing. Use single quotes with nothing between them.

Correct syntax. This deletes the AdminName value.

This is incorrect syntax, and will not be correctly reflected on the server.

Parameters

Supplying a property and a value will stage an update to that property with the supplied value.

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to login to a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Optionally choose to set the includelogs flag. Doing so will include logs in the data retrieval process.

Optionally including the selector flag allows you to select a type to run while running the current command. Use this flag when you wish to select a type without entering another command, or if you wish to work with a type that is different from the one you currently have selected.

Optionally set a filter value for a filter attribute. This uses the provided filter for the currently selected type.

Optionally use the latest schema instead of the one requested by the file.

Use this flag when you are ready to commit all the changes for the current selection. Including the –commit flag will log you out of the server after the command is run. Some changes made in this way will be updated instantly, while others will be reflected the next time the server is started.

Optionally set a starting point for data collection. If you do not specify a starting point, the default path will be/rest/v1.

Optionally include the logout flag to log out of the server after this command is completed. You need to be logged in to use this flag.

Select this flag to input a BIOS password. Include this flag if second-level BIOS authentication is needed for the command to execute.

Use this flag to perform a reboot command function after completion of operations. For help with parameters and descriptions regarding the reboot flag, run help reboot.

Override the measures stopping the tool from writing over items that are system unique.

Inputs

None

Outputs

None

Save command

Save example commands:

Here, the server is logged into, Bios is selected, and the corresponding JSON file is saved to a local directory as the file ilorest.json. The ilorest.json file holds all the information regarding the selected type. Here, the save function was performed on the Bios type, so the ilorest.json file that was saved holds the information about Bios. The file holding that information looks like the following.

iLOrest > save --select Bios. --url xx.xx.xx.xx -u username -p password
Discovering data...Done
Saving configuration...
Configuration saved to: ilorest.json

Example json file:

[
  {
    "Comments": {
      "Manufacturer": "HPE", 
      "Model": "ProLiant DL360 Gen10", 
      "BIOSFamily": "U32", 
      "BIOSDate": "12/14/2018", 
      "SerialNumber": "Kappa", 
      "iLOVersion": "iLO 5 v1.40"
    }
  }, 
  {
    "#Bios.v1_0_0.Bios": {
      "/redfish/v1/systems/1/bios/settings/": {
        "@odata.context": "/redfish/v1/$metadata#Bios.Bios", 
        "@odata.etag": "W/\"02E13BA89B606F6F6F02950EB3CA676D\"", 
        "@odata.id": "/redfish/v1/systems/1/bios/settings/", 
        "AttributeRegistry": "BiosAttributeRegistryU32.v1_2_10", 
        "Attributes": {
          "MemFastTraining": "Enabled", 
          "PowerRegulator": "DynamicPowerSavings", 
          "EmbeddedDiagnostics": "Enabled", 
          "Ipv6Address": "::", 
          "PersistentMemBackupPowerPolicy": "UseExternalBackupPower", 
          "ServiceEmail": "", 
          "FlexLom1Aspm": "Disabled", 
          "UrlBootFile": "", 
          "DcuStreamPrefetcher": "Enabled", 
          "IntelNicDmaChannels": "Enabled", 
          ...
        }, 
        "Id": "settings", 
        "Name": "BIOS Pending Settings"
      }
    }
  }
]

This command simultaneously logs in to the server at the provided URL (–url) with the provided username (-u) and password (-p), selects the Bios. type, saves the JSON response to a file called BiosInfo.json in a local directory, and then logs out.

iLOrest > save --select Bios. --url xx.xx.xx.xx -u username -p password -f BiosInfo.json --logout
Discovering data...Done
Saving configuration...
Configuration saved to: BiosInfo.json
Logging session out.

Syntax

save [Optional Parameters]

Description

Saves the JSON information of a selected type to a local file. Use this command along with the load command when you want to modify properties of a selected type through file editing. Using this command saves a local copy of your selected type’s JSON information.

Parameters

Including the help flag on this command will display help on the usage of this command.

Use this flag if you wish to use a different filename than the default one. The default filename is ilorest.json.

If you are not logged in yet, including this flag along with the password and URL flags can be used to login to a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Optionally choose to set the includelogs flag. Doing so will include logs in the data retrieval process.

Optionally including the selector flag allows you to select a type to run while running the current command. Use this flag when you wish to select a type without entering another command, or if you wish to work with a type that is different from the one you currently have selected.

Optionally include this flag to save multiple types of single file. Override the currently selected type.

Optionally set a filter value for a filter attribute. This uses the provided filter for the currently selected type.

Optionally include this flag if you wish to change the displayed output to JSON format. Preserving the JSON data structure makes the information easier to read.

Optionally set a starting point for data collection. If you do not specify a starting point, the default path will be/rest/v1.

Optionally include the logout flag to log out of the server after this command is completed. You need to be logged in to use this flag.

Optionally include this flag to encrypt a file using the key provided.

Inputs

None

Outputs

JSON file

Save a selected type to a file in JSON format. You can edit the values in the file, and then use the load command to upload the changes to the server.

Load command

Load example commands:

If no filename is supplied with the (-f, –filename) option, save looks for a file named ilorest.json in the current working directory. Save will automatically select the required type to make changes.

iLOrest > load
Loading configuration...
Committing changes...
One or more properties were changed and will not take effect until system is reset.

This command simultaneously logs in to the server at the provided URL (–url) with the provided username (-u) and password (-p) and load a file from the current working directory called biosconfig.json.

iLOrest > load --url xx.xx.xx.xx -u username -p password -f biosconfig.json
Discovering data...Done
Loading configuration...
Committing changes...
One or more properties were changed and will not take effect until system is reset.

This is the multi-server configuration setup. You must pass in a multi-server file in the following format.

iLOrest > load -m mpfilename.txt -f biosconfig.json
Discovering data...Done
Loading configuration for multiple servers...
Logging session out.
Checking given server information...
Create multiple processes to load configuration concurrently to all servers...
Loading Configuration for xx.xx.xx.xx : SUCCESS
Loading Configuration for xx.xx.xx.xy : SUCCESS
All servers have been successfully configured.

All servers are configured concurrently. Because the filename tag is included, it searches for the file called biosconfig.json and loads that information to the servers. If no values have changed, the load process is complete. If any property values have changed, the changes are committed and the user is logged out of the server. Logs of the entire process are then stored in the same location as the iLOrest logs.

--url 10.0.0.100 -u username -p password
--url 10.0.0.101 -u username -p password
--url 10.0.0.102 -u username -p password
--url 10.0.0.103 -u username -p password

Syntax

load [Optional Parameters]

Description

Loads the server configuration from a file. Run this command without parameters to use the configuration found in the file called ilorest.json. Otherwise, you can point this command to use any file you specify. Use this function to change the properties of a type to new values. This command uploads the new values of the type’s properties to the server.

Parameters

Including the help flag on this command will display help on the usage of this command.

Use this flag if you wish to use a different filename than the default one. The default filename is ilorest.json.

If you are not logged in yet, including this flag along with the password and URL flags can be used to login to a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Optionally use the latest schema instead of the one requested by the file.

Select this flag to input a BIOS password. Include this flag if second-level BIOS authentication is needed for the command to execute.

Optionally include the logout flag to log out of the server after this command is completed. You need to be logged in to use this flag.

Override the measures stopping the tool from writing over items that are system unique.

Optionally supply a filename to a multi-processing file to load concurrently on multiple servers.

Use the provided directory to output data for a multiple server configuration.

Optionally include this flag to decrypt a file using the key provided.

Inputs

JSON Object

Input a JSON object to load from a custom configuration file, otherwise the configuration will default to looking for a file called ilorest.json.

Outputs

None

Status command

Status example commands:

The status command shows changes to be committed. The status command shows all pending changes, including changes for different types.

iLOrest > status
Current changes found:
Bios.v1_0_0(/redfish/v1/systems/1/bios/settings/) (Currently selected)
        Attributes/ServiceName=simpleservice
ComputerSystem.v1_4_0(/redfish/v1/Systems/1/)
        AssetTag=newtag

Once changes are committed they no longer show in status.

iLOrest > status
Current changes found:
Bios.v1_0_0(/redfish/v1/systems/1/bios/settings/) (Currently selected)
        Attributes/ServiceName=simpleservice
ComputerSystem.v1_4_0(/redfish/v1/Systems/1/)
        AssetTag=newtag
iLOrest > commit
Committing changes...
One or more properties were changed and will not take effect until system is reset.
The operation completed successfully.
iLOrest > status
No changes found

Syntax

status [Optional Parameters]

Description

Displays all pending changes, regardless of which type is currently selected. All the changes that have not been committed yet will be shown.

Parameters

Including the help flag on this command will display help on the usage of this command.

Inputs

None

Outputs

None

Commit command

Commit example commands:

Commit all pending changes made by set by running the commit command.

iLOrest > select ComputerSystem.
iLOrest > set AssetTag=newtag
iLOrest > select Bios.
iLOrest > set servicename=simpleservice
iLOrest > commit
Committing changes...
One or more properties were changed and will not take effect until system is reset.
The operation completed successfully.

If you do not commit before logging out changes will be lost.

iLOrest > select Bios.
iLOrest > get AdminName
AdminName=Chelsea K
iLOrest > set AdminName=newname
iLOrest > get AdminName
AdminName=newname
iLOrest > logout
Logging session out.
iLOrest > get AdminName --select Bios.
Discovering data...Done
AdminName=Chelsea K

Commit after running other commands by using the --commit option. This command simultaneously logs in to the server at the provided URL (–url) with the provided username (-u, –user) and password (-p, –password), selects the ComputerSystem. type, sets AssetTag to "", commits the change, and logs-out.

iLOrest > set AssetTag="" --url xx.xx.xx.xx -u username -p password --selector ComputerSystem. --commit --logout
Discovering data...Done
Committing changes...
The operation completed successfully.
Logging session out.

Syntax

commit [Optional Parameters]

Description

Applies all changes made during the current session. After you have changed one or more values for the property of a type, you need to commit those changes in order for those changes to be reflected on the server.

Usage in Other Commands

To commit at the end of a command, include the –commit option. Not all commands have the commit flag, run help on the command to see available options.

Parameters

Including the help flag on this command will display help on the usage of this command.

Select this flag to input a BIOS password. Include this flag if second-level BIOS authentication is needed for the command to execute.

Use this flag to perform a reboot command function after completion of operations. For help with parameters and descriptions regarding the reboot flag, run help reboot.

Inputs

None

Outputs

None

Logout command

Logout example commands:

Use the logout command to end the session and disconnect from the server.

iLOrest > login xx.xx.xx.xx -u username -p password
Discovering data...Done
iLOrest > logout
Logging session out.

Logout from another command using the --logout option.

iLOrest > get AssetTag --select ComputerSystem. --logout
AssetTag=""
Logging session out.

Syntax

logout [Optional Parameters]

Description

Use the logout command to exit your session and to disconnect from the server.

Usage in Other Commands

To log out at the end of a command, include the –logout option. Not all commands have the logout flag, run help on the command to see available options.

Parameters

Including the help flag on this command will display help on the usage of this command.

Inputs

None

Outputs

None

Exit command

Exit example commands

This command exits the interactive shell.

iLOrest > exit
Logging session out.
Bye for now

Syntax

exit [Optional Parameters]

Description

Use the exit command if you wish to exit from the interactive shell. Using exit will also log you out and disconnect you from the server.

Parameters

Including the help flag on this command will display help on the usage of this command.

Inputs

None

Outputs

None

Filtering and Other Advanced Options

This section covers some of the advanced features and options available with the iLOrest tool.

Filter Option

Selecting the EthernetInterface. type reveals many instances. To return a single instance we can filter by a property value. In this case we are filtering by @odata.id.

iLOrest > select EthernetInterface.
iLOrest > list @odata.id

@odata.id=/redfish/v1/Systems/1/EthernetInterfaces/2/

@odata.id=/redfish/v1/Systems/1/EthernetInterfaces/1/

@odata.id=/redfish/v1/Managers/1/EthernetInterfaces/1/

@odata.id=/redfish/v1/Systems/1/EthernetInterfaces/3/

@odata.id=/redfish/v1/Managers/1/EthernetInterfaces/2/

@odata.id=/redfish/v1/Systems/1/EthernetInterfaces/4/

iLOrest > list Id --filter "@odata.id=/redfish/v1/Managers/1/EthernetInterfaces/1/"
Id=1

By default filter will attempt to match the property and value case insensitively, but exactly. If no matches are found iLOrest will return an error.

iLOrest > list Id --filter "@Odata.id=/redfish/v1/Managers/1/"
Unable to locate instance for 'ethernetinterface.' and filter '@Odata.id=/redfish/v1/Managers/1/'

Partial string matching is supported with the * character.

iLOrest > list @odata.id Id --filter "@Odata.id=/redfish/v1/Managers/1/*"

@odata.id=/redfish/v1/Managers/1/EthernetInterfaces/1/
Id=1

@odata.id=/redfish/v1/Managers/1/EthernetInterfaces/2/
Id=2

Filter is also useful for setting properties to specific instances.

iLOrest > set FullDuplex=True --filter "@odata.id=/redfish/v1/Managers/1/EthernetInterfaces/2/"
iLOrest > status
Current changes found:
EthernetInterface.v1_4_1(/redfish/v1/Managers/1/EthernetInterfaces/2/) (Currently selected)
        FullDuplex=True

Syntax

–filter [FILTER_PROPERTY=FILTER_VALUE]

Description

If there is more than one instance of a Type on the system, when you select it, the filter option can be used to narrow down the results. With this narrowed result, you can set specific instance properties, list specific instance properties, or get specific instance properties.

Path Option

To start type collection from a specific path include the --path option followed by the path to start from. This can limit or add new types depending on the path specified.

iLOrest > login xx.xx.xx.xx -u username -p password --path /redfish/v1/systems/1/bios/
Discovering data......Done
iLOrest > types
Type options:
#Bios.v1_0_0.Bios
#HpeBaseConfigs.v2_0_0.HpeBaseConfigs
#HpeBiosMapping.v2_0_0.HpeBiosMapping
#HpeScalablePmem.v1_0_0.HpeScalablePmem
#HpeServerBootSettings.v2_0_0.HpeServerBootSettings
#HpeTlsConfig.v1_0_0.HpeTlsConfig
#HpeiSCSISoftwareInitiator.v2_0_0.HpeiSCSISoftwareInitiator

iLOrest > login xx.xx.xx.xx -u username -p password
Discovering data...Done
iLOrest > types
Type options:
AccountService.v1_3_0
Bios.v1_0_0
CertificateCollection
Chassis.v1_6_0
ChassisCollection
ComputerSystem.v1_4_0
ComputerSystemCollection
EthernetInterface.v1_4_1
EthernetInterfaceCollection
EventDestinationCollection
EventService.v1_0_8
HostInterface.v1_1_1
HostInterfaceCollection
HpeBaseConfigs.v2_0_0
HpeBaseNetworkAdapter.v2_0_0
HpeBaseNetworkAdapterCollection
HpeBiosMapping.v2_0_0
HpeCertAuth.v1_1_0
HpeCertificate.v1_0_0
HpeCertificateCollection
HpeComponent.v1_0_1
HpeComponentCollection
HpeComponentInstallSet.v1_0_3
HpeComponentInstallSetCollection
HpeComponentUpdateTaskQueueCollection
HpeDirectoryTest.v1_0_0
HpeESKM.v2_0_0
...

Syntax

–path [URI]

Description

The path option can set a different URI as the starting point for type discovery. The default path is /redfish/v1/. This option is useful if you wish to view specific types, which are not available by default or if you wish to lower the time it takes to login. It is not recommended to use this flag on systems with a resource directory.

BIOS commands

This section details usage and examples of RESTful Interface Tool commands related to configuring BIOS settings. These commands do things such as view and change the boot order, reset the BIOS configuration to the default settings, and configure iSCSI settings.

Bootorder command

Bootorder example commands:

Run without arguments to view the current persistent boot order, continuous and one time boot options, and continuous and one time boot UEFI options.

iLOrest > bootorder
Discovering data...Done

Current Persistent Boot Order:
1. HD.EmbRAID.1.6 (sles-secureboot)
2. HD.EmbRAID.1.7 (Windows Boot Manager)
3. HD.EmbRAID.1.8 (Red Hat Enterprise Linux)
4. NIC.LOM.1.1.IPv4 (Embedded LOM 1 Port 1 : HPE Ethernet 1Gb 4-port 331i Adapter - NIC (PXE IPv4))
5. NIC.LOM.1.1.Httpv4 (Embedded LOM 1 Port 1 : HPE Ethernet 1Gb 4-port 331i Adapter - NIC (HTTP(S) IPv4))
6. HD.SD.1.2 (Internal SD Card 1 : Generic USB3.0-CRW)
7. HD.EmbRAID.1.2 (Embedded RAID 1 : HPE Smart Array P408i-a SR Gen10 - Size:279.3 GiB Port:1I Bay:1 Box:1)
8. HD.EmbRAID.1.3 (Embedded RAID 1 : HPE Smart Array P408i-a SR Gen10 - Size:279.3 GiB Port:1I Bay:2 Box:1)
9. HD.EmbRAID.1.4 (Embedded RAID 1 : HPE Smart Array P408i-a SR Gen10 - Size:279.3 GiB Port:1I Bay:3 Box:1)
10. HD.EmbRAID.1.5 (Embedded RAID 1 : HPE Smart Array P408i-a SR Gen10 - Size:279.3 GiB Port:1I Bay:4 Box:1)
11. Generic.USB.1.1 (Generic USB Boot)
12. NIC.LOM.1.1.Httpv6 (Embedded LOM 1 Port 1 : HPE Ethernet 1Gb 4-port 331i Adapter - NIC (HTTP(S) IPv6))
13. NIC.LOM.1.1.IPv6 (Embedded LOM 1 Port 1 : HPE Ethernet 1Gb 4-port 331i Adapter - NIC (PXE IPv6))

Continuous and one time boot options:
1. None
2. Cd
3. Hdd
4. Usb
5. SDCard
6. Utilities
7. Diags
8. BiosSetup
9. Pxe
10. UefiShell
11. UefiHttp
12. UefiTarget

Continuous and one time boot uefi options:
1. HD.EmbRAID.1.7 (Windows Boot Manager)
2. HD.EmbRAID.1.6 (sles-secureboot)
3. HD.EmbRAID.1.8 (Red Hat Enterprise Linux)
4. NIC.LOM.1.1.IPv4 (Embedded LOM 1 Port 1 : HPE Ethernet 1Gb 4-port 331i Adapter - NIC (PXE IPv4))
5. NIC.LOM.1.1.Httpv4 (Embedded LOM 1 Port 1 : HPE Ethernet 1Gb 4-port 331i Adapter - NIC (HTTP(S) IPv4))
6. HD.SD.1.2 (Internal SD Card 1 : Generic USB3.0-CRW)
7. HD.EmbRAID.1.2 (Embedded RAID 1 : HPE Smart Array P408i-a SR Gen10 - Size:279.3 GiB Port:1I Bay:1 Box:1)
8. HD.EmbRAID.1.3 (Embedded RAID 1 : HPE Smart Array P408i-a SR Gen10 - Size:279.3 GiB Port:1I Bay:2 Box:1)
9. HD.EmbRAID.1.4 (Embedded RAID 1 : HPE Smart Array P408i-a SR Gen10 - Size:279.3 GiB Port:1I Bay:3 Box:1)
10. HD.EmbRAID.1.5 (Embedded RAID 1 : HPE Smart Array P408i-a SR Gen10 - Size:279.3 GiB Port:1I Bay:4 Box:1)
11. Generic.USB.1.1 (Generic USB Boot)
12. NIC.LOM.1.1.Httpv6 (Embedded LOM 1 Port 1 : HPE Ethernet 1Gb 4-port 331i Adapter - NIC (HTTP(S) IPv6))
13. NIC.LOM.1.1.IPv6 (Embedded LOM 1 Port 1 : HPE Ethernet 1Gb 4-port 331i Adapter - NIC (PXE IPv6))

List numbers associated with the Current Persistent Boot Order list to set a new boot order. Any numbers left off of the new list will be added to the end. Using the previous examples Current Persistent Boot Order, this command will place Generic.USB.1.1, HD.SD.1.2, and HD.EmbRAID.1.8 at the top in that order. The commit flag will commit the changes, otherwise changes are not saved.

iLOrest > bootorder [11,6,3] --commit
Committing changes...
One or more properties were changed and will not take effect until system is reset.
iLOrest > bootorder

Current Persistent Boot Order:
1. Generic.USB.1.1 (Generic USB Boot)
2. HD.SD.1.2 (Internal SD Card 1 : Generic USB3.0-CRW)
3. HD.EmbRAID.1.8 (Red Hat Enterprise Linux)
4. HD.EmbRAID.1.6 (sles-secureboot)
5. HD.EmbRAID.1.7 (Windows Boot Manager)
6. NIC.LOM.1.1.IPv4 (Embedded LOM 1 Port 1 : HPE Ethernet 1Gb 4-port 331i Adapter - NIC (PXE IPv4))
7. NIC.LOM.1.1.Httpv4 (Embedded LOM 1 Port 1 : HPE Ethernet 1Gb 4-port 331i Adapter - NIC (HTTP(S) IPv4))
8. HD.EmbRAID.1.2 (Embedded RAID 1 : HPE Smart Array P408i-a SR Gen10 - Size:279.3 GiB Port:1I Bay:1 Box:1)
9. HD.EmbRAID.1.3 (Embedded RAID 1 : HPE Smart Array P408i-a SR Gen10 - Size:279.3 GiB Port:1I Bay:2 Box:1)
10. HD.EmbRAID.1.4 (Embedded RAID 1 : HPE Smart Array P408i-a SR Gen10 - Size:279.3 GiB Port:1I Bay:3 Box:1)
11. HD.EmbRAID.1.5 (Embedded RAID 1 : HPE Smart Array P408i-a SR Gen10 - Size:279.3 GiB Port:1I Bay:4 Box:1)
12. NIC.LOM.1.1.Httpv6 (Embedded LOM 1 Port 1 : HPE Ethernet 1Gb 4-port 331i Adapter - NIC (HTTP(S) IPv6))
13. NIC.LOM.1.1.IPv6 (Embedded LOM 1 Port 1 : HPE Ethernet 1Gb 4-port 331i Adapter - NIC (PXE IPv6))
...

Use partial string matching to set a boot order independent of the current boot order. All boot options not listed will be added to the end of the boot order. This command will set All v4 NICs first, followed by all hard drives, followed by Generic.USB.1.1, then committing the results.

iLOrest > bootorder NIC.*v4 HD* Generic.USB.1.1
iLOrest > bootorder

Current Persistent Boot Order:
1. NIC.LOM.1.1.IPv4 (Embedded LOM 1 Port 1 : HPE Ethernet 1Gb 4-port 331i Adapter - NIC (PXE IPv4))
2. NIC.LOM.1.1.Httpv4 (Embedded LOM 1 Port 1 : HPE Ethernet 1Gb 4-port 331i Adapter - NIC (HTTP(S) IPv4))
3. HD.SD.1.2 (Internal SD Card 1 : Generic USB3.0-CRW)
4. HD.EmbRAID.1.8 (Red Hat Enterprise Linux)
5. HD.EmbRAID.1.6 (sles-secureboot)
6. HD.EmbRAID.1.7 (Windows Boot Manager)
7. HD.EmbRAID.1.2 (Embedded RAID 1 : HPE Smart Array P408i-a SR Gen10 - Size:279.3 GiB Port:1I Bay:1 Box:1)
8. HD.EmbRAID.1.3 (Embedded RAID 1 : HPE Smart Array P408i-a SR Gen10 - Size:279.3 GiB Port:1I Bay:2 Box:1)
9. HD.EmbRAID.1.4 (Embedded RAID 1 : HPE Smart Array P408i-a SR Gen10 - Size:279.3 GiB Port:1I Bay:3 Box:1)
10. HD.EmbRAID.1.5 (Embedded RAID 1 : HPE Smart Array P408i-a SR Gen10 - Size:279.3 GiB Port:1I Bay:4 Box:1)
11. Generic.USB.1.1 (Generic USB Boot)
12. NIC.LOM.1.1.Httpv6 (Embedded LOM 1 Port 1 : HPE Ethernet 1Gb 4-port 331i Adapter - NIC (HTTP(S) IPv6))
13. NIC.LOM.1.1.IPv6 (Embedded LOM 1 Port 1 : HPE Ethernet 1Gb 4-port 331i Adapter - NIC (PXE IPv6))
...

Change the one time boot order using the --onetimeboot option. Specify a option to boot to from the Continuous and one time boot options list.

iLOrest > bootorder --onetimeboot=Hdd --commit
Committing changes...
The operation completed successfully.

Change the continuous boot order using the --continuousboot option. Specify a option to boot to from the Continuous and one time boot options list.

iLOrest > bootorder --continuousboot=Cd --commit
Committing changes...
The operation completed successfully.

To turn off any continuous or one-time boot options that have been configured, use the --disablebootflag option.

iLOrest > bootorder --disablebootflag --commit
Committing changes...
The operation completed successfully.

Syntax

bootorder [Boot Order] [Optional Parameters]

Description

Modifies the current boot order and sets continuous and one-time boot settings. Run this command without arguments to display current boot order. Run it with arguments to change the boot order. To perform a one-time boot, continuous boot, or disable continuous boot or one-time boot, use the respective options.

Parameters

The boot order can be specified as a list of numbers or as a list of partial strings for matching. If omitted, displays the current boot order. See examples for usage and syntax.

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Use this flag when you are ready to commit all the changes for the current selection. Some changes made in this way will be updated instantly, while others will be reflected the next time the server is started.

Select this flag to input a BIOS password. Include this flag if second-level BIOS authentication is needed for the command to execute.

Use this flag to perform a reboot command function after completion of operations. For help with parameters and descriptions regarding the reboot flag, run help reboot.

Use this flag to configure a one-time boot option. Using this flag will prioritize the provided boot source only on the very next time the server is booted.

Use this flag to enable a continuous boot option. Using this flag will cause the system to boot to the selected device every time the system boots.

Use this to disable either continuous or one-time boot modes.

Use this flag to perform actions on secure boot keys. Possible values include defaultkeys: resets all keys to default, deletekeys: deletes all keys, deletepk: deletes all product keys.

Inputs

None

Outputs

None

BiosDefaults command

BiosDefaults example commands:

To set the bios back to factory defaults, run the command without arguments

iLOrest > biosdefaults
Resetting the currently logged in server's BIOS settings to defaults.
One or more properties were changed and will not take effect until system is reset.

To set the bios back to user defaults, include the --userdefaults flag.

iLOrest > biosdefaults --userdefaults
Resetting the currently logged in server's BIOS settings to defaults.
One or more properties were changed and will not take effect until system is reset.

This command simultaneously logs in to the server at the provided URL (–url) with the provided username (-u) and password (-p), sets the bios back to default settings, then reboots (–reboot) the server to apply the changes. Using the reboot option automatically logs-out of the server.

iLOrest > biosdefaults --url xx.xx.xx.xx -u username -p password --reboot=ForceRestart
Discovering data...Done
Resetting the currently logged in server's BIOS settings to defaults.
One or more properties were changed and will not take effect until system is reset.

After the server is rebooted the session will be terminated.
Please wait for the server to boot completely to login again.
Rebooting server in 3 seconds...
The operation completed successfully.
Logging session out.

Syntax

biosdefaults [Optional Parameters]

Description

Sets the BIOS settings of the currently logged in server back to the default settings.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Select this flag to input a BIOS password. Include this flag if second-level BIOS authentication is needed for the command to execute.

Use this flag to perform a reboot command function after completion of operations. For help with parameters and descriptions regarding the reboot flag, run help reboot.

Sets bios to user defaults instead of factory defaults.

Sets bios to manufacturer defaults instead of factory defaults.

Inputs

None

Outputs

None

iSCSIConfig command

iSCSIConfig example commands:

Using the iscsiconfig command without any options will display the current ISCSI configuration, including ISCSI initiator name and currently configured boot entries.

iLOrest > iscsiconfig

Iscsi Initiator Name: "iqn.2015-02.com.hpe:uefi-U32-Kappa"

Available iSCSI Boot Network Interfaces:
[1] Embedded LOM 1 Port 1 : HPE Ethernet 1Gb 4-port 331i Adapter - NIC
[2] Embedded LOM 1 Port 2 : HPE Ethernet 1Gb 4-port 331i Adapter - NIC
[3] Embedded LOM 1 Port 3 : HPE Ethernet 1Gb 4-port 331i Adapter - NIC
[4] Embedded LOM 1 Port 4 : HPE Ethernet 1Gb 4-port 331i Adapter - NIC

Use the list flag to retrieve the current configured iscsi boot attempts. If none are configured, then all sections will have a message stating Not Added.

iLOrest > iscsiconfig --list
Current iSCSI Attempts:
[
  {
    "Not Added": {}
  },
  {
    "Not Added": {}
  },
  {
    "Not Added": {}
  },
  {
    "Not Added": {}
  }
]

To add an iSCSI boot attempt use the --add option, specifying which iSCSI Network Interface to attempt a boot from. This command will add a boot attempt from option [2] in the Available iSCSI Boot Network Interfaces list.

iLOrest > iscsiconfig --add [2]
One or more properties were changed and will not take effect until system is reset.
iLOrest > iscsiconfig --list
Current iSCSI Attempts:
[
  {
    "Embedded LOM 1 Port 2 : HPE Ethernet 1Gb 4-port 331i Adapter - NIC": {
      "Attempt 1": {
        "iSCSILUN": "0",
        "iSCSIAttemptName": "1",
        "iSCSIConnectTimeoutMS": 20000,
        "iSCSIChapUsername": "",
        "iSCSIChapSecret": "",
        "iSCSIInitiatorGateway": "0.0.0.0",
        "iSCSINicSource": "NicBoot2",
        "iSCSIConnection": "Disabled",
        "iSCSIInitiatorNetmask": "0.0.0.0",
        "iSCSITargetName": "",
        "iSCSIReverseChapUsername": "",
        "iSCSIInitiatorInfoViaDHCP": true,
        "iSCSIAttemptInstance": 1,
        "iSCSITargetTcpPort": 3260,
        "iSCSIConnectRetry": 3,
        "StructuredBootString": null,
        "iSCSIReverseChapSecret": "",
        "iSCSIInitiatorIpAddress": "0.0.0.0",
        "iSCSIAuthenticationMethod": "None",
        "iSCSITargetInfoViaDHCP": true,
        "iSCSIChapType": "OneWay",
        "iSCSITargetIpAddress": "0.0.0.0",
        "iSCSIIpAddressType": "IPv4",
        "UEFIDevicePath": null
      }
    }
  },
  {
    "Not Added": {}
  },
  {
    "Not Added": {}
  },
  {
    "Not Added": {}
  }
]

Modify properties for boot attempts by outputting them to a file, editing the file, then apply the changes with the --modify option. You must include the --list option with the -f option to write to a file.

iLOrest > iscsiconfig --list -f output.txt
Results written out to 'output.txt'
iLOrest > iscsiconfig --modify output.txt
One or more properties were changed and will not take effect until system is reset.

To delete an iSCSI attempt use the --delete option, specifying which attempt to delete.

iLOrest > iscsiconfig --list
Current iSCSI Attempts:
[
  {
    "Embedded LOM 1 Port 2 : HPE Ethernet 1Gb 4-port 331i Adapter - NIC": {
      "Attempt 1": {
        "iSCSILUN": "0",
        "iSCSIAttemptName": "1",
        "iSCSIConnectTimeoutMS": 20000,
        "iSCSIChapUsername": "blah",
        "iSCSIChapSecret": "",
        "iSCSIInitiatorGateway": "0.0.0.0",
        "iSCSINicSource": "NicBoot2",
        "iSCSIConnection": "Disabled",
        "iSCSIInitiatorNetmask": "0.0.0.0",
        "iSCSITargetName": "",
        "iSCSIReverseChapUsername": "",
        "iSCSIInitiatorInfoViaDHCP": true,
        "iSCSIAttemptInstance": 1,
        "iSCSITargetTcpPort": 3260,
        "iSCSIConnectRetry": 3,
        "StructuredBootString": null,
        "iSCSIReverseChapSecret": "",
        "iSCSIInitiatorIpAddress": "0.0.0.0",
        "iSCSIAuthenticationMethod": "None",
        "iSCSITargetInfoViaDHCP": true,
        "iSCSIChapType": "OneWay",
        "iSCSITargetIpAddress": "0.0.0.0",
        "iSCSIIpAddressType": "IPv4",
        "UEFIDevicePath": null
      }
    }
  },
  {
    "Not Added": {}
  },
  {
    "Not Added": {}
  },
  {
    "Not Added": {}
  }
]

iLOrest > iscsiconfig --delete 1
One or more properties were changed and will not take effect until system is reset.
iLOrest > iscsiconfig --list
Current iSCSI Attempts:
[
  {
    "Not Added": {}
  },
  {
    "Not Added": {}
  },
  {
    "Not Added": {}
  },
  {
    "Not Added": {}
  }
]

Syntax

iscsiconfig [iSCSI Configuration] [Optional Parameters]

Description

Use this command to view the current iSCSI configuration, save the current iSCSI configuration to a file, load an iSCSI configuration from a file, or view available NIC resources for iSCSI configuration.

Parameters

Use this iSCSI configuration option to add an iSCSI configuration option.

Use this iSCSI configuration option to delete an iSCSI configuration option.

Use this iSCSI configuration option to modify an iSCSI configuration option.

Use this iSCSI configuration option to list the details of the different iSCSI configurations.

Including the help flag on this command will display help on the usage of this command.

Optionally include this flag to use the provided filename instead of the default ilorest.json file.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Select this flag to input a BIOS password. Include this flag if second-level BIOS authentication is needed for the command to execute.

Use this flag to perform a reboot command function after completion of operations. For help with parameters and descriptions regarding the reboot flag, run help reboot.

Inputs

None

Outputs

None

Results command

Results example commands:

Run the command without any parameters to gather the results of any changes which occurred on the last reboot.

iLOrest > results
Results of the previous reboot changes:

Bios:
The operation completed successfully.
SmartArray:
Request successfully completed
Boot:
The operation completed successfully.
Iscsi:
The operation completed successfully.

Syntax

results [optional parameters]

Description

Show the results of any changes, which require a system reboot to take effect.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Inputs

None

Outputs

None

Pending command

Pending example commands:

Run pending with no arguments show current changes that have been committed to the server and are awaiting a reboot. In this example, no changes have been found.

iLOrest > pending
Current Pending Changes:

SmartStorageConfig.v2_0_1:
No pending changes found.

HpeServerBootSettings.v2_0_0:
No pending changes found.

HpeScalablePmem.v1_0_0:
No pending changes found.

HpeiSCSISoftwareInitiator.v2_0_0:
No pending changes found.

HpeKmsConfig.v1_0_0:
No pending changes found.

HpeServerConfigLock.v1_0_0:
No pending changes found.

Bios.v1_0_0:
No pending changes found.

HpeTlsConfig.v1_0_0:
No pending changes found.

After committing a change to AdminName the pending command shows the change to AdminName that will take effect on reboot.

iLOrest > select bios.
iLOrest > set AdminName=newname --commit
Committing changes...
One or more properties were changed and will not take effect until system is reset.
iLOrest > pending
Current Pending Changes:

SmartStorageConfig.v2_0_1:
No pending changes found.

HpeServerBootSettings.v2_0_0:
No pending changes found.

HpeScalablePmem.v1_0_0:
No pending changes found.

HpeiSCSISoftwareInitiator.v2_0_0:
No pending changes found.

HpeKmsConfig.v1_0_0:
No pending changes found.

HpeServerConfigLock.v1_0_0:
No pending changes found.

Bios.v1_0_0:
Attributes=
            AdminName=
                       Current=""
                       Pending=newname

HpeTlsConfig.v1_0_0:
No pending changes found.

Syntax

pending [Optional Parameters]

Description

Displays pending committed changes that will be applied after a reboot.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

Inputs

None

Outputs

None

Setpassword command

Setpassword example commands:

To set a new password, include the new password and the current password. When setting a bios or power on password with no previous password set, OLD_PASSWORD must be set to "" signifying no password.

iLOrest > setpassword newpassword ""
The operation completed successfully.

When setting a bios or power on password back to nothing, NEW_PASSWORD must be set to "".

iLOrest > setpassword "" oldpassword
The operation completed successfully.

To set the power on password, include the --poweron option.

iLOrest > setpassword newpassword "" --poweron
The operation completed successfully.

Syntax

setpassword [NEW_PASSWORD] [OLD_PASSWORD] [OPTIONS]

Description

Sets the bios admin password and poweron password.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

Use this flag to perform a reboot command function after completion of operations. ‘REBOOT’ is replaceable parameter that can have multiple values. For help with parameters and descriptions regarding the reboot flag, run help reboot.

Inputs

None

Outputs

None

iLO Commands

This section includes advanced functions for manipulating iLO using the RESTful Interface Tool. These commands include operations such as turning the server hardware on and off, resetting iLO, and updating firmware.

iLO commands that are supported for a specific HPE server generation:

Certificate command

Certificate example commands:

To Generate an https certificate signing request use the csr argument along with the following information Organization Name, Organization Unit, Common Name, Country, State, City. Use quotes to include parameters which contain whitespace.

iLOrest > login
Discovering data...Done
iLOrest > certificate csr "Hewlett Packard Enterprise" "iLORest Group" CName "United States" Texas Houston 
iLO is creating a new certificate signing request This process can take up to 10 minutes.
X509 Certificate is being generated and the process might take up to 10 minutes.

To retrieve the certificate signing request use the getcsr argument. The default filename is certificate.txt, saved to the current working directory. Including the (-f, –filename) option will change the default name.

iLOrest > certificate getcsr
Discovering data...Done
Certificate saved to: certificate.txt

To import a CA certificate use the ca argument followed by a file containing the certificate.

iLOrest > certificate ca certfile.txt
The operation completed successfully.

To import a CRL certificate use the crl argument followed by a URI to the certificate file.

iLOrest > certificate crl http://hostname/location/to/cert.txt
The operation completed successfully.

To import a TLS certificate use the tls argument followed by a file containing the certificate.

iLOrest > certificate tls certfile.txt
The operation completed successfully.

Syntax

certificate [Optional Parameters]

Description

Command for importing both iLO and login authorization certificates as well as generating iLO certificate signing requests.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Use this flag if you wish to use a different filename for the certificate signing request. The default filename is certificate.txt.

Inputs

None

Outputs

None

Clearrestapistate command

Clearrestapistate example commands:

To Clear the persistent RESTful API state run the command without arguments.

iLOrest > clearrestapistate
The operation completed successfully.

Syntax

clearrestapistate [Optional Parameters]

Description

Clears the persistent RESTful API state. Generally not needed and shouldn’t be done unless there are issues viewing info, setting, or committing data.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Inputs

None

Outputs

None

Disableilofunctionality command

Disableilofunctionality example commands:

To Disable iLO functionality run the command without arguments.

iLOrest > disableilofunctionality
The operation completed successfully.
Disabling iLO functionality. iLO will be unavailable on the logged in server until it is re-enabled manually.
[200] The operation completed successfully.

Syntax

disableilofunctionality [Optional Parameters]

Description

Disable iLO functionality on the current logged in server.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Ignore any critical task checking and force disable iLO.

Inputs

None

Outputs

None

Eskm command

Eskm example commands:

To clear the ESKM logs use the clearlog argument.

iLOrest > eskm clearlog
The operation completed successfully.

To test the ESKM connections use the testconnections argument. The response will indicate if the system can connect properly or if there is an issue.

iLOrest > eskm testconnections
Enterprise Secure Key Manager Servers are not configured.

Syntax

eskm [Command] [Optional Parameters]

Description

Command for testing connections to the Enterprise Secure Key Manager system and clearing the Enterprise Secure Key Manager logs.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Inputs

None

Outputs

None

Factorydefaults command

Factorydefaults example commands:

To reset iLO to factory defaults in the current logged in server run the command without arguments.

iLOrest > factorydefaults
Resetting iLO to factory default settings
Current session will be terminated.
The operation completed successfully.

Syntax

factorydefaults [Optional Parameters]

Description

Reset iLO to factory defaults in the current logged in server.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Inputs

None

Outputs

None

Fwintegritycheck command

Fwintegritycheck example commands:

To perform a firmware integrity check run the command without arguments.

iLOrest > fwintegritycheck
The operation completed successfully.

To perform a firmware integrity check and return results of the check include the --results option.

iLOrest > fwintegritycheck --results
The operation completed successfully.
Awaiting results of firmware integrity check....
Scan Result: OK

Syntax

fwintegritycheck [Optional Parameters]

Description

Perform a firmware integrity check on the current logged in server.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Optionally include this flag to show results of firmware integrity check.

Inputs

None

Outputs

None

Reboot command

Reboot example commands:

If no arguments are supplied the default operation is ForceRestart.

iLOrest > reboot

After the server is rebooted the session will be terminated.
Please wait for the server to boot completely to login again.
Rebooting server in 3 seconds...
The operation completed successfully.
Logging session out.

To perform a power function supply one of the reboot type parameters as an argument.

iLOrest > reboot ForceOff

Server is powering off the session will be terminated.
Please wait for the server to boot completely to login again.
Powering off the server in 3 seconds...
The operation completed successfully.
Logging session out.

If the current power state does not allow for an operation to complete an error will be returned.

iLOrest > reboot On

Session will now be terminated.
Please wait for the server to boot completely to login again.
Turning on the server in 3 seconds...
iLO response with code [400]: The operation was not successful due to the current power state (for example, attempting to turn the power off when it is already off).

Syntax

reboot [Reboot Type] [Optional Parameters]

Description

Run this command to turn the system on, perform an immediate non-graceful shutdown, perform an immediate non-graceful shutdown followed by a restart of the system, generate a non-maskable interrupt and cause an immediate system halt, or simulate the pressing of the physical power button on the system.

Parameters

Use this reboot type to turn the system on. If the system is already on, this has no effect.

Use this reboot type to cause the system to perform an immediate non-graceful shutdown.

Use this reboot type to perform an immediate non-graceful shutdown followed by a restart of the system.

Use this reboot type to generate a non-maskable interrupt to cause an immediate system halt.

Use this reboot type to simulate the pressing of the physical power button on this system.

Simulates the pressing of the physical power button on this system.

Simulates pressing and holding of the power button on this systems.

Immediately removes power from the server, followed by a restart of the system.

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

You can optionally choose to set the includelogs flag. Doing so will include logs in the data retrieval process.

Optionally include to request user confirmation for reboot.

Inputs

None

Outputs

None

Sendtest command

Sendtest example commands:

Send syslog test to the current logged in server.

iLOrest > sendtest syslog
The operation completed successfully.

Send alert mail test to the current logged in server.

iLOrest > sendtest alertmail
The operation completed successfully.

Send SNMP test alert to the current logged in server.

iLOrest > sendtest snmpalert
The operation completed successfully.

Syntax

sendtest [Command] [Optional Parameters]

Description

Command for triggering various tests to iLO.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Inputs

None

Outputs

None

Serverlogs command

Serverlogs example commands:

Select AHS to download AHS logs from a server to a file. The filename is pre-generated from the server serial number and date and time the AHS log was gathered.

iLOrest > serverlogs --selectlog=AHS

To view logs select a log using the --selectlog option. You can output logs to a file with the (-f, --filename) option.

iLOrest > serverlogs --selectlog=IML

@odata.type=#LogEntry.v1_0_0.LogEntry
Name=Integrated Management Log
Created=2019-02-02T22:02:40Z
@odata.id=/redfish/v1/Systems/1/LogServices/IML/Entries/1/
@odata.context=/redfish/v1/$metadata#LogEntry.LogEntry
Id=1
Oem=
     Hpe=
          @odata.type=#HpeLogEntry.v2_1_0.HpeLogEntry
          Count=1
          Updated=2019-02-02T22:02:40Z
          Code=1
          EventNumber=2054
          @odata.context=/redfish/v1/$metadata#HpeLogEntry.HpeLogEntry
          Class=33
          Categories=Maintenance
                      Administration
OemRecordFormat=Hpe-IML
Message=IML Cleared (iLO 5 user: admin)
EntryType=Oem
Severity=OK

To filter logs you can use the --filter option.

iLOrest > serverlogs --selectlog=IML --filter Id=1

@odata.type=#LogEntry.v1_0_0.LogEntry
Name=Integrated Management Log
Created=2019-02-02T22:02:40Z
@odata.id=/redfish/v1/Systems/1/LogServices/IML/Entries/1/
@odata.context=/redfish/v1/$metadata#LogEntry.LogEntry
Id=1
Oem=
     Hpe=
          @odata.type=#HpeLogEntry.v2_1_0.HpeLogEntry
          Count=1
          Updated=2019-02-02T22:02:40Z
          Code=1
          EventNumber=2054
          @odata.context=/redfish/v1/$metadata#HpeLogEntry.HpeLogEntry
          Class=33
          Categories=Maintenance
                      Administration
OemRecordFormat=Hpe-IML
Message=IML Cleared (iLO 5 user: admin)
EntryType=Oem
Severity=OK

Use the --customiseAHS with a string to customize AHS results. This is only available for downloading remote AHS logs. This command will only download AHS logs from January 26th 2019 to February 1st 2019.

serverlogs --selectlog=AHS --customiseAHS "from=2019-01-26&&to=2019-02-01"

Clear logs by selecting a log with --selectlog and including the (-c, --clearlog) option. This command will clear the AHS logs.

iLOrest > serverlogs --selectlog=AHS --clearlog
One or more properties were changed and will not take effect until the device is reset and system is rebooted

To insert an IML log use the (-m, --maintenancemessage) flag. This is only available with IML logs.

iLOrest > serverlogs --selectlog=IML -m "Text message for maintenance"
[201] The operation completed successfully.

To set an IML log as repaired use the (-r, --repair) option. Specify the Id of a log to mark as repaired. You can only repair entries with severities of Critical or Warning.

iLOrest > serverlogs --selectlog=IML --filter Severity=Critical

@odata.type=#LogEntry.v1_0_0.LogEntry
Name=Integrated Management Log
Created=2019-02-02T22:08:32Z
@odata.id=/redfish/v1/Systems/1/LogServices/IML/Entries/3/
@odata.context=/redfish/v1/$metadata#LogEntry.LogEntry
Id=3
Oem=
     Hpe=
          @odata.type=#HpeLogEntry.v2_1_0.HpeLogEntry
          Count=2
          Updated=2019-02-02T22:10:05Z
          Code=1043
          EventNumber=2057
          @odata.context=/redfish/v1/$metadata#HpeLogEntry.HpeLogEntry
          RecommendedAction=Update the Innovation Engine Firmware.
          LearnMoreLink=http://www.hpe.com/support/class0x0032code0x0413-gen10
          Repaired=False
          Class=50
          Categories=Security
OemRecordFormat=Hpe-IML
Message=Innovation Engine Image Authentication Error. The Innovation Engine image could not be authenticated.
EntryType=Oem
Severity=Critical
iLOrest > serverlogs --selectlog=IML -r 3
The operation completed successfully.
iLOrest > serverlogs --selectlog=IML --filter Id=3

@odata.type=#LogEntry.v1_0_0.LogEntry
Name=Integrated Management Log
Created=2019-02-02T22:08:32Z
@odata.id=/redfish/v1/Systems/1/LogServices/IML/Entries/3/
@odata.context=/redfish/v1/$metadata#LogEntry.LogEntry
Id=3
Oem=
     Hpe=
          @odata.type=#HpeLogEntry.v2_1_0.HpeLogEntry
          Count=3
          Updated=2019-02-02T22:12:20Z
          Code=1043
          EventNumber=2057
          @odata.context=/redfish/v1/$metadata#HpeLogEntry.HpeLogEntry
          RecommendedAction=Update the Innovation Engine Firmware.
          LearnMoreLink=http://www.hpe.com/support/class0x0032code0x0413-gen10
          Repaired=True
          Class=50
          Categories=Security
OemRecordFormat=Hpe-IML
Message=Innovation Engine Image Authentication Error. The Innovation Engine image could not be authenticated.
EntryType=Oem
Severity=OK

Syntax

serverlogs –selectlog=[Log_Selection] [Optional Parameters]

Description

Command for downloading and performing log operations.

Parameters

Use this with the –selectlog option to perform operations on the AHS logs.

Use this with the –selectlog option to perform operations on the IEL logs.

Use this with the –selectlog option to perform operations on the IML logs.

Including the help flag on this command will display help on the usage of this command.

Use this flag if you wish to use a different filename than the default one. The default filename is ilorest.json.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Optionally set a filter value for a filter attribute. This uses the provided filter for the selected log.

Optionally include this flag if you wish to change the displayed output to JSON format. Preserving the JSON data structure makes the information easier to parse.

Optionally include the logout flag to log out of the server after this command is completed. Using this flag when not logged in will have no effect.

Read log from the given log service. Options: IML, IEL or AHS.

Clears the logs for the selected option.

Allows customized AHS log data to be downloaded.

Allows complete AHS log data to be downloaded.

Directory path for the ahs file.

Maintenance message to be inserted into the log. (IML LOGS ONLY FEATURE)

Use the provided filename to obtain server information.

Use the provided directory to output data for multiple server downloads.

Used to indicate the logs to be downloaded on multiple servers. Allowable values: IEL, IML, AHS, all or combination of any two.

Repair the IML log with the given ID.

Inputs

None

Outputs

None

iLOReset command

iLOReset example commands:

To reset iLO run the command without arguments.

iLOrest > iloreset

After iLO resets the session will be terminated.
Please wait for iLO to initialize completely before logging in again.
This process may take up to 3 minutes.

A management processor reset is in progress.

Syntax

iloreset [Optional Parameters]

Description

Run this command to reset iLO on the currently logged in server.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Inputs

None

Outputs

None

Ipprofiles command

Ipprofiles example commands:

To list the current profiles on the server, run the command without arguments..

iLOrest > ipprofiles
{
  "@odata.type": "#HpeIpProfiles.v1_0_0.HpeIpProfiles",
  "1540504034216": "{profile: data}"
}

To upload an ipprofile, input a valid JSON file path as an argument.

iLOrest > ipprofiles profile.json
The operation completed successfully.

To remove a profile, use the unique key contained in the profile with the (-d, --delete) option.

iLOrest > ipprofiles -d 1540504034216
The operation completed successfully.
iLOrest > ipprofiles
{
  "@odata.type": "#HpeIpProfiles.v1_0_0.HpeIpProfiles",
  "1549567973200": "{\"profile\": {}}"
}
iLOrest > ipprofiles -d 1549567973200
The operation completed successfully.
iLOrest > ipprofiles
{
  "@odata.type": "#HpeIpProfiles.v1_0_0.HpeIpProfiles"
}

Syntax

ipprofiles [Optional Parameters]

Description

Run this command to manage the hpeipprofile data store.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Write results to the specified file.

Look for the key or keys in the ipprofile manager and delete.

Copies the specified ip profile into the job queue and starts it.

Inputs

None

Outputs

None

Firmware update command

Firmware update example commands:

To update firmware specify the URI location of the firmware. iLO will then gather the file and flash it. The user will be logged out after firmware update completes successfully.

iLOrest > firmwareupdate http://firmwarehost/path/to/firmware/file.bin

Starting upgrading process...

iLO is uploading the necessary files. Please wait...

Updating: \

Firmware update has completed and iLO may reset.
If iLO resets the session will be terminated.
Please wait for iLO to initialize completely before logging in again.
A reboot may be required for firmware changes to take effect.
Logging session out.

Syntax

Firmwareupdate [URI] [Optional Parameters]

Description

Use this command to update the firmware via URI. iLO must be able to access the URI for update to complete successfully. This command only supports firmware with a .bin extension.

Parameters

Point the firmwareupdate command towards the .bin file that holds the file for the firmware update.

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Use this flag if the server you are currently logged into has a TPM chip installed.

Inputs

File

Input a URI pointing to a .bin file to perform the firmwareupdate command. The .bin file should hold the file needed to perform the firmware update.

Outputs

None

Iloaccounts command

Iloaccounts example commands:

To list the current iLO accounts on the system and their information, run the command without arguments.

iLOrest > iloaccounts
Discovering data...Done
iLO Account info:
[Id] UserName (LoginName):
Privileges
-----------------
[1] Administrator (Administrator):
ServiceAccount=False
HostNICConfigPriv=True
HostStorageConfigPriv=True
RemoteConsolePriv=True
iLOConfigPriv=True
VirtualMediaPriv=True
UserConfigPriv=True
HostBIOSConfigPriv=True
VirtualPowerAndResetPriv=True
LoginPriv=True
SystemRecoveryConfigPriv=True

To add an iLO account include the add argument with the new account USERNAME, LOGINNAME, and PASSWORD. To optionally specify privileges at creation, use the --addprivs option with numbers from the privilege list.

iLOrest > iloaccounts add USERNAME ACCOUNTNAME PASSWORD --addprivs 1,4,7
[201] The operation completed successfully.
iLOrest > iloaccounts
iLO Account info:
[Id] UserName (LoginName):
Privileges
-----------------
[1] Administrator (Administrator):
ServiceAccount=False
HostNICConfigPriv=True
HostStorageConfigPriv=True
RemoteConsolePriv=True
iLOConfigPriv=True
VirtualMediaPriv=True
UserConfigPriv=True
HostBIOSConfigPriv=True
VirtualPowerAndResetPriv=True
LoginPriv=True
SystemRecoveryConfigPriv=True

[3] USERNAME (ACCOUNTNAME):
ServiceAccount=False
HostNICConfigPriv=True
HostStorageConfigPriv=False
RemoteConsolePriv=False
iLOConfigPriv=True
VirtualMediaPriv=False
UserConfigPriv=False
HostBIOSConfigPriv=False
VirtualPowerAndResetPriv=False
LoginPriv=True
SystemRecoveryConfigPriv=False

To modify an iLO account’s privileges include the modify argument, the Id or the Username of the account to modify, and include the --addprivs and/or --removeprivs options with numbers from the privilege list.

iLOrest > iloaccounts
...
[3] USERNAME (ACCOUNTNAME):
ServiceAccount=False
HostNICConfigPriv=True
HostStorageConfigPriv=False
RemoteConsolePriv=False
iLOConfigPriv=True
VirtualMediaPriv=False
UserConfigPriv=False
HostBIOSConfigPriv=False
VirtualPowerAndResetPriv=False
LoginPriv=True
SystemRecoveryConfigPriv=False

iLOrest > iloaccounts modify USERNAME --addprivs 2,3 --removeprivs 7
The account was modified successfully.
iLOrest > iloaccounts
...
[3] USERNAME (ACCOUNTNAME):
ServiceAccount=False
HostNICConfigPriv=False
HostStorageConfigPriv=False
RemoteConsolePriv=True
iLOConfigPriv=True
VirtualMediaPriv=False
UserConfigPriv=True
HostBIOSConfigPriv=False
VirtualPowerAndResetPriv=False
LoginPriv=True
SystemRecoveryConfigPriv=False

To change the password of an account run the command with the changepass argument, specifying the Id or the Username of the account to modify and the new password.

iLOrest > iloaccounts changepass 3 newpassword
The account was modified successfully.

To delete an iLO account run the command with the delete argument, specifying the Id or the Username of the account for deletion.

iLOrest > iloaccounts delete USERNAME
The account was removed successfully.

Syntax

iloaccounts [COMMAND] [OPTIONS]

Description

Adds/deletes an iLO account on the currently logged in server and modifies iLO account privileges.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Optionally include this flag if you wish to specify which privileges you want added to the iLO account. Pick privileges from the privilege list in the above help text. Example: –addprivs=1,2,4

Optionally include this flag if you wish to specify which privileges you want removed from the iLO account. Pick privileges from the privilege list in the above help text. Example: –removeprivs=1,2,4

Optionally include this flag if you would like to specify Privileges by role. Valid choices are: Administrator, ReadOnly, and Operator.

Optionally include this flag if you wish to change the displayed output to JSON format. Preserving the JSON data structure makes the information easier to parse.

Inputs

None

Outputs

None

Iloclone command (Deprecated)

Iloclone example commands:

To create a clone file from the current logged in server run the command with the save argument. You can specify a save file using the (-f, --filename) option.

iLOrest > iloclone save
WARNING: iloclone command is being deprecated and will be removed in a future version. Use the serverclone command instead.
Gathering data required for clone. This may take a while...
You may be prompted to enter some information to complete the clone file.
Please input the password for user, Administrator:
Password:
Please input the key for federation, DEFAULT:
Password:
Configuration saved to: clone.json

To load the saved clone file to currently logged in server run the command with the load argument. You can specify a load file using the (-f, --filename) option.

iLOrest > iloclone load
WARNING: iloclone command is being deprecated and will be removed in a future version. Use the serverclone command instead.
Are you sure you would like to continue? All user settings will be erased. (y/n)y

Patching: /redfish/v1/AccountService/Accounts/1/
iLO response with code [400]: The user or login user name already exists.

Posting: /redfish/v1/AccountService/Accounts/
[201] The operation completed successfully.

Posting: /redfish/v1/AccountService/Accounts/
[201] The operation completed successfully.

Posting: /redfish/v1/AccountService/Accounts/
[201] The operation completed successfully.

Patching: /redfish/v1/AccountService/
[201] The operation completed successfully.

Patching: /redfish/v1/Managers/1/EthernetInterfaces/1/
One or more properties were changed, but these changes will not take effect until the management processor is reset.

Patching: /redfish/v1/Managers/1/EthernetInterfaces/2/
One or more properties were changed, but these changes will not take effect until the management processor is reset.

Patching: /redfish/v1/Managers/1/
The operation completed successfully.

Patching: /redfish/v1/Managers/1/DateTime/
One or more properties were changed, but these changes will not take effect until the management processor is reset.

Patching: /redfish/v1/Managers/1/SnmpService/
The operation completed successfully.

Patching: /redfish/v1/Managers/1/FederationGroups/DEFAULT/
The operation completed successfully.

Patching: /redfish/v1/Managers/1/SecurityService/SSO/
The operation completed successfully.

Patching: /redfish/v1/Systems/1/
The operation completed successfully.

Patching: /redfish/v1/Chassis/1/Power/
The operation completed successfully.

Patching: /redfish/v1/systems/1/bios/settings/
One or more properties were changed and will not take effect until system is reset.

Patching: /redfish/v1/systems/1/bios/boot/settings/
One or more properties were changed and will not take effect until system is reset.

Patching: /redfish/v1/Systems/1/SecureBoot/
One or more properties were changed and will not take effect until system is reset.

Patching: /redfish/v1/Managers/1/NetworkProtocol/
One or more properties were changed, but these changes will not take effect until the management processor is reset.
Waiting for iLO to reset...
3 minutes remaining...
2 minutes remaining...
1 minute remaining...

Syntax

iloclone [Optional Parameters]

Description

Command to clone the iLO and Bios config of the currently logged in server and copy it to other server(s).

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Use this flag if you wish to use a different filename than the default one. The default filename is clone.json.

Use this flag during iloclone save if you wish to import a SSO certificate to the server to be cloned. Add the sso cert file or URL to be used to the working directory before running clone load.

Use this flag during iloclone save if you wish to import a SSO certificate to the server to be cloned. Add the https cert file to be used to the working directory before running clone load.

Override the measures stoppping the tool from writing over items that are system unique.

Optionally include this flag to encrypt/decrypt a file using the key provided.

Inputs

None

Outputs

None

Ilofederation command

Ilofederation example commands:

To add an iLO federation group to the current logged in server include the add argument with the new federation name and federation key.

iLOrest > ilofederation
iLO Federation Id list with Privileges:

Name=DEFAULT:
HostNICConfigPriv=False
HostStorageConfigPriv=False
RemoteConsolePriv=False
iLOConfigPriv=False
VirtualMediaPriv=False
UserConfigPriv=False
HostBIOSConfigPriv=False
VirtualPowerAndResetPriv=False
LoginPriv=True
SystemRecoveryConfigPriv=False
iLOrest > ilofederation add newfedname 8charfedkey
The resource has been created successfully.
iLOrest > ilofederation
iLO Federation Id list with Privileges:

Name=DEFAULT:
HostNICConfigPriv=False
HostStorageConfigPriv=False
RemoteConsolePriv=False
iLOConfigPriv=False
VirtualMediaPriv=False
UserConfigPriv=False
HostBIOSConfigPriv=False
VirtualPowerAndResetPriv=False
LoginPriv=True
SystemRecoveryConfigPriv=False

Name=newfedname:
HostNICConfigPriv=True
HostStorageConfigPriv=True
RemoteConsolePriv=True
iLOConfigPriv=True
VirtualMediaPriv=True
UserConfigPriv=True
HostBIOSConfigPriv=True
VirtualPowerAndResetPriv=True
LoginPriv=True
SystemRecoveryConfigPriv=True

To list the current iLO federations and their information run the command with no arguments.


iLOrest > ilofederation
iLO Federation Id list with Privileges:

Name=DEFAULT:
HostNICConfigPriv=False
HostStorageConfigPriv=False
RemoteConsolePriv=False
iLOConfigPriv=False
VirtualMediaPriv=False
UserConfigPriv=False
HostBIOSConfigPriv=False
VirtualPowerAndResetPriv=False
LoginPriv=True
SystemRecoveryConfigPriv=False

To change the key of an iLO federation group include the changekey argument with the federation name and the new key.

iLOrest > ilofederation changekey newfedname newfedkey
The operation completed successfully.

To delete an iLO federation group include the delete argument with the federation name to delete.

iLOrest > ilofederation
iLO Federation Id list with Privileges:

Name=DEFAULT:
HostNICConfigPriv=False
HostStorageConfigPriv=False
RemoteConsolePriv=False
iLOConfigPriv=False
VirtualMediaPriv=False
UserConfigPriv=False
HostBIOSConfigPriv=False
VirtualPowerAndResetPriv=False
LoginPriv=True
SystemRecoveryConfigPriv=False

Name=newfedname:
HostNICConfigPriv=True
HostStorageConfigPriv=True
RemoteConsolePriv=True
iLOConfigPriv=True
VirtualMediaPriv=True
UserConfigPriv=True
HostBIOSConfigPriv=True
VirtualPowerAndResetPriv=True
LoginPriv=True
SystemRecoveryConfigPriv=True
iLOrest > ilofederation delete newfedname
The operation completed successfully.
iLOrest > ilofederation
iLO Federation Id list with Privileges:

Name=DEFAULT:
HostNICConfigPriv=False
HostStorageConfigPriv=False
RemoteConsolePriv=False
iLOConfigPriv=False
VirtualMediaPriv=False
UserConfigPriv=False
HostBIOSConfigPriv=False
VirtualPowerAndResetPriv=False
LoginPriv=True
SystemRecoveryConfigPriv=False

Syntax

ilofederation [Optional Parameters]

Description

Adds / deletes an iLO federaion group on the currently logged in server. - FEDERATIONNAME: The name (Id) of the federation group. - KEY: The key required to join the federation.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Optionally include this flag if you wish to set the remote console privileges to false.

Optionally include this flag if you wish to set the ilo config privileges to false.

Optionally include this flag if you wish to set the virtual media privileges to false.

Optionally include this flag if you wish to set the userconfig privileges to false.

Optionally include this flag if you wish to set the virtual power and reset privileges to false.

Optionally include this flag if you wish to set the login privileges to false.

Optionally include this flag if you wish to set the host BIOS config privileges to false. Only available on gen10 servers.

Optionally include this flag if you wish to set the host NIC config privileges to false. Only available on gen10 servers.

Optionally include this flag if you wish to set the host storage config privileges to false. Only available on gen10 servers.

Optionally include this flag if you wish to set the system recovery config privileges to false. Only available on gen10 servers.

Inputs

None

Outputs

None

Ilolicense command

Ilolicense example commands:

To Apply an iLO license on the current logged in server run the command with the license key as an argument.

iLOrest > ilolicense XXXXX-XXXXX-XXXXX-XXXXX-XXXXX
The resource has been created successfully.

Syntax

ilolicense [LICENSE_KEY] [OPTIONS]

Description

Applies an iLO license on the currently logged in server.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Inputs

None

Outputs

None

Serverstate command

Serverstate example commands:

To return the serverstate run the command without arguments. Possible values include: None, Unknown, Reset, PowerOff, InPost, InPostDiscoveryComplete, FinishedPost.

iLOrest > serverstate
The server is currently in state: FinishedPost

Syntax

serverstate [Optional Parameter]

Description

Returns the current state of the server.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Inputs

None

Outputs

None

Sigrecompute command

Sigrecompute example commands:

To Recalculate the signature on the systems configuration run the command without arguments.

iLOrest > sigrecompute
The operation completed successfully.

Syntax

sigrecompute [OPTIONS]

Description

Recalculate the signature on the systems configuration.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Inputs

None

Outputs

None

Singlesignon command

Singlesignon example commands:

To delete a specific SSO record by running the command with the deleterecord argument and specify it by number.

iLOrest > singlesignon deleterecord 1
The operation completed successfully.

To delete a specific SSO record by running the command with the deleterecord argument followed by the all keyword.

iLOrest > singlesignon deleterecord all
The operation completed successfully.

To import a SSO DNS name run the command with the dnsname argument followed by the DNS to import.

iLOrest > singlesignon importdns dnsname
The operation completed successfully.

To import a SSO certificate from a file run the command with the importcert argument followed by the certificate file to import. You can also import the certificate by URI, by specifying a URI path to the certificate instead.

iLOrest > singlesignon importcert certfile.txt
The operation completed successfully.

Syntax

Singlesignon [OPTIONS]

Description

Command for all single sign on available actions.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Inputs

None

Outputs

None

Virtualmedia command

Virtualmedia example commands:

To view current virtual media run the command without arguments.

iLOrest > virtualmedia
Available Virtual Media Options:
[1] Media Types Available: Floppy USBStick  Image Inserted: None
[2] Media Types Available: CD DVD  Image Inserted: None

To insert virtual media specify the type of virtual media by Id number followed by the URI location to the image. You can specify the media to boot next reset by including the --bootnextreset option.

iLOrest > virtualmedia 2 http://xx.xx.xx.xx/path/to/vm.iso --bootnextreset
The operation completed successfully.
iLOrest > virtualmedia
Available Virtual Media Options:
[1] Media Types Available: Floppy USBStick  Image Inserted: None
[2] Media Types Available: CD DVD  Image Inserted: http://xx.xx.xx.xx/path/to/vm.iso

To remove an inserted media specify the type of virtual media by Id number and include the --remove option.

iLOrest > virtualmedia 2 --remove
The operation completed successfully.
iLOrest > virtualmedia
Available Virtual Media Options:
[1] Media Types Available: Floppy USBStick  Image Inserted: None
[2] Media Types Available: CD DVD  Image Inserted: None

Syntax

virtualmedia [ID] [URI] [OPTIONS]

Description

Command for inserting and removing virtual media.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Use this flag to perform a reboot command function after completion of operations. For help with parameters and descriptions regarding the reboot flag, run help reboot.

Use this flag to remove the media from the selection.

Use this flag if you wish to boot from the image on next server reboot.

Inputs

None

Outputs

None

Backuprestore command

To create a backup (.bak) file run the command with the backup argument.

iLOrest > backuprestore backup
Downloading backup file HPE_Kappa_20190203_0012.bak...Download complete.

To restore a server using the .bak file run the command with the restore argument. By default the command will search for a (.bak) file in the current working directory. Specify a (.bak) file using the (-f, --filename) option.

iLOrest > backuprestore restore
Restore in progress. iLO while be unresponsive while the restore completes.
Your session will be terminated.
Logging session out.

Syntax

backuprestore [OPTIONS]

Description

Backup and restore iLO to a server using a .bak file.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

Use this command to specify the which backup file to restore. By default, the command will try to find a .bak file in the current working directory.

Use the provided password when creating the backup file. The same password must be used for restoring.

Inputs

None

Outputs

None

Directory command

To view current ldap or kerberos settings run the command with the ldap or kerberos arguments.

iLOrest > directory ldap
Discovering data...Done
LDAP settings:
--------------------------------
Enabled: False
Service Address: Not Set
Local Account Authorization: Enabled
Port: 55
Authentication Mode: Disabled
Search Settings:
        Search 1: blah
Remote Role Mapping(s):
        Local Role: dirgroupb3d8954f6ebbe735764e9f7c
        Remote Group: Administrators
        Local Role: dirgroup9d4546a03a03bb977c03086a
        Remote Group: Authenticated Users:S-1-5-11
iLOrest > directory kerberos
Kerberos settings:
--------------------------------
Enabled: False
Service Address: Not Set
Local Account Authorization: Enabled
Port: 1337
Realm: Not Set
Remote Role Mapping(s):
        Local Role: dirgroupb3d8954f6ebbe735764e9f7c
        Remote Group: Administrators
        Local Role: dirgroup9d4546a03a03bb977c03086a
        Remote Group: Authenticated Users:S-1-5-11

To add credentials to a service specify the service with the ldap or kerberos argument followed by the USERNAME and PASSWORD of the directory. The --enable flag was passed because previously the directory was disabled.

iLOrest > directory ldap USERNAME PASSWORD --enable
Changing settings...
The operation completed successfully.

To specify the service address (--serviceaddress), port (--port), authentication schema (--authentication), and/or search strings (--addsearch/--removesearch) specify their respective options. Authentication schema and search strings can only be used with the LDAP directory.

iLOrest > directory ldap --serviceaddress x.x.y.z --addsearch string3,string4 --authentication=ExtendedSchema --port 199
Changing settings...
The operation completed successfully.
iLOrest > directory ldap
LDAP settings:
--------------------------------
Enabled: True
Service Address: x.x.y.z
Local Account Authorization: Enabled
Port: 199
Authentication Mode: ExtendedSchema
Search Settings:
        Search 1: blah
        Search 2: string3
        Search 3: string4
Remote Role Mapping(s):
        Local Role: dirgroupb3d8954f6ebbe735764e9f7c
        Remote Group: Administrators
        Local Role: dirgroup9d4546a03a03bb977c03086a
        Remote Group: Authenticated Users:S-1-5-11

To specify the realm (--realm) and/or key tab (--keytab) specify their respective options. Realm and key tab can only be used with the Kerberos directory.

iLOrest > directory kerberos --realm Forgotten --keytab http://location/to/keytab.txt
Changing settings...
The operation completed successfully.
Adding keytab...
The operation completed successfully.

To add directory role maps include the ldap argument with the --addrolemap option with the form LocalRole:RemoteRoleGroup:OptionalSID. Available roles can be found be selecting the Role. type

iLOrest > directory ldap --addrolemap "Administrator:Owners,ReadOnly:Reading Users:S-1-7-23"
Changing settings...
The operation completed successfully.
iLOrest > directory ldap
LDAP settings:
--------------------------------
Enabled: True
Service Address: x.x.y.z:199
Local Account Authorization: Enabled
Port: 199
Authentication Mode: ExtendedSchema
Search Settings:
        Search 1: blah
        Search 2: string3
        Search 3: string4
Remote Role Mapping(s):
        Local Role: dirgroupb3d8954f6ebbe735764e9f7c
        Remote Group: Administrators
        Local Role: dirgroup9d4546a03a03bb977c03086a
        Remote Group: Authenticated Users:S-1-5-11
        Local Role: dirgroupb3b74668da9b6b0bc6864223
        Remote Group: Owners
        Local Role: dirgroup8e167f4006abce0ae22977d4
        Remote Group: Reading Users:S-1-7-23

To remove directory role maps include the ldap argument with the --removerolemap option specifying the LocalRole of the role map to remove. Multiple role maps can be removed by separating them with commas.

iLOrest > directory ldap --removerole dirgroupb3b74668da9b6b0bc6864223,dirgroup8e167f4006abce0ae22977d4
Changing settings...
The operation completed successfully.
iLOrest > directory ldap
LDAP settings:
--------------------------------
Enabled: True
Service Address: x.x.y.z:199
Local Account Authorization: Enabled
Port: 199
Authentication Mode: ExtendedSchema
Search Settings:
        Search 1: blah
        Search 2: string3
        Search 3: string4
Remote Role Mapping(s):
        Local Role: dirgroupb3d8954f6ebbe735764e9f7c
        Remote Group: Administrators
        Local Role: dirgroup9d4546a03a03bb977c03086a
        Remote Group: Authenticated Users:S-1-5-11

To perform directory tests use the test argument followed by start to start the directory test, stop to stop the directory test, or viewresults to view the results of the last directory test.

iLOrest > directory test start
Starting the directory test. Monitor results with command: directory viewresults
[200] The operation completed successfully.
iLOrest > directory test stop
Stopping the directory test.
[200] The operation completed successfully.
iLOrest > directory test viewresults
Test: Directory Server DNS Name
------------------------
Status: Failed
Notes: Unable to resolve host name x.x.y.z:199

Test: Ping Directory Server
------------------------
Status: Failed
Notes:

Test: Connect to Directory Server
------------------------
Status: Failed
Notes: Unable to connect to the directory server LDAP port within timeout. Verify directory server address. Use this to ensure iLO can correctly connect and use the directory server.

Test: Connect using SSL
------------------------
Status: Failed
Notes: Unable to connect to directory server within timeout.

Test: Bind to Directory Server
------------------------
Status: NotRun
Notes:

Test: Directory Administrator login
------------------------
Status: NotRun
Notes:

Test: User Authentication
------------------------
Status: NotRun
Notes:

Test: User Authorization
------------------------
Status: Failed
Notes:

Test: Directory User Contexts
------------------------
Status: NotRun
Notes:

Test: LOM Object exists
------------------------
Status: NotRun
Notes:

Syntax

directory [kerberos/ldap/test] [OPTIONS]

Description

This command will view/update Kerberos or Ldap directory settings, add/delete directory roles, and test directory settings.

Parameters

Use this parameter to update or view ldap settings.

Use this parameter to update or view Kerberos (Active Directory) settings.

Use this parameter to perform directory tests.

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

Use this command to enable or disable the LDAP or Kerberos services.

Use this command to set the service address of the LDAP or Kerberos Services.

Use this command to set the port of the LDAP or Kerberos services.

Use this command to set the Kerberos realm.

Use this command to import a Kerberos Keytab by its URI location.

Use this command to enable or disable the authentication for local accounts.

Use this command to choose a LDAP authentication mode. The available modes are DefaultSchema (Directory Default Schema or Schema- free) and ExtendedSchema (HPE Extended Schema).

Use this command to add or remove search strings for generic LDAP services.

Use this command to add or remove Role Mapping(s) for the LDAP and Kerberos services.

Use this command to change the displayed output to JSON format. Preserving the JSON data structure makes the information easier to parse.

Inputs

None

Outputs

None

One Button Erase Command

To initiate One Button Erase and erase all iLO settings, Bios settings, User Data, and iLO Repository data run the command without arguments.

iLOrest > onebuttonerase
Please type "erase" to begin erase process. Any other input will cancel the operation. If you wish to skip this prompt add the --confirm flag: erase
One or more properties were changed and will not take effect until system is reset.
The operation completed successfully.
        One Button Erase Status
==========================================================
Elapsed time in Minutes: 0
Elapsed Remaining Time in Minutes: 0
Bios Settings Erase: Idle
iLO Settings Erase: Idle
User Data Erase: Initiated /

To optionally skip the confirmation before initiating One Button Erase include the --confirm option.

iLOrest > onebuttonerase --confirm
One or more properties were changed and will not take effect until system is reset.
The operation completed successfully.
        One Button Erase Status
==========================================================
Elapsed time in Minutes: 0
Elapsed Remaining Time in Minutes: 0
Bios Settings Erase: Idle
iLO Settings Erase: Idle
User Data Erase: Initiated \

Syntax

onebuttonerase [OPTIONS]

Description

Performs One Button Erase on a system. Erases all iLO settings, Bios settings, User Data, and iLO Repository data.

Parameter

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

Use this command to skip monitoring of the one button erase process and simply trigger the operation.

Use this command to skip the confirmation prompt before starting One Button Erase and begin the operation.

Inputs

None

Outputs

None

Serverclone command

To save an iLO and Bios config run the command with the save argument. You can specify a filename using the (-f, --filename) option, if this option is not used the command will search for ilorest_clone.json.

iLOrest > serverclone save
Saving properties of type: AccountService, path: /redfish/v1/AccountService/
Saving properties of type: Bios, path: /redfish/v1/systems/1/bios/settings/
Saving properties of type: ComputerSystem, path: /redfish/v1/Systems/1/
Saving properties of type: EthernetInterface, path: /redfish/v1/Managers/1/EthernetInterfaces/1/
Saving properties of type: EthernetInterface, path: /redfish/v1/Managers/1/EthernetInterfaces/2/
Saving properties of type: HpeESKM, path: /redfish/v1/Managers/1/SecurityService/ESKM/
Saving properties of type: HpeServerBootSettings, path: /redfish/v1/systems/1/bios/boot/settings/
Saving properties of type: HpeiLODateTime, path: /redfish/v1/Managers/1/DateTime/
Please input the federation key for Federation user: DEFAULT
Password: password
Please re-enter the federation key for Federation user: DEFAULT
Password: password
Saving properties of type: HpeiLOFederationGroup, path: /redfish/v1/Managers/1/FederationGroups/DEFAULT/
License Key Found ending in XXXXX: 
Remember to edit your License Key...
Saving properties of type: HpeiLOLicense, path: /redfish/v1/Managers/1/LicenseService/1/
Saving properties of type: HpeiLOSSO, path: /redfish/v1/Managers/1/SecurityService/SSO/
Saving properties of type: HpeiLOSnmpService, path: /redfish/v1/Managers/1/SnmpService/
Saving properties of type: Manager, path: /redfish/v1/Managers/1/
Password: Please input the desired password for user: Administrator
password
Please re-enter the desired password for user: Administrator
Password: password
Saving properties of type: ManagerAccount, path: /redfish/v1/AccountService/Accounts/7/
Please input the desired password for user: tiQiR2
Password: 
Using a placeholder password of '' in ilorest_clone.json file.
Saving properties of type: ManagerAccount, path: /redfish/v1/AccountService/Accounts/8/
Saving properties of type: ManagerNetworkProtocol, path: /redfish/v1/Managers/1/NetworkProtocol/
Saving properties of type: SecureBoot, path: /redfish/v1/Systems/1/SecureBoot/
Saving properties of type: SmartStorageConfig, path: /redfish/v1/systems/1/smartstorageconfig/settings/
Saving of clonefile to 'ilorest_clone.json' is complete.

To save an iLO and Bios config while providing a placeholder value for all user inputs run the command with the save argument and include the (--silent, --quiet) option. This option can be used to problematically create a file without user input and then use a script to fill in the settings.

iLOrest > serverclone save --silent
Saving properties of type: AccountService, path: /redfish/v1/AccountService/
Saving properties of type: Bios, path: /redfish/v1/systems/1/bios/settings/
Saving properties of type: ComputerSystem, path: /redfish/v1/Systems/1/
Saving properties of type: EthernetInterface, path: /redfish/v1/Managers/1/EthernetInterfaces/1/
Saving properties of type: EthernetInterface, path: /redfish/v1/Managers/1/EthernetInterfaces/2/
Saving properties of type: HpeESKM, path: /redfish/v1/Managers/1/SecurityService/ESKM/
Saving properties of type: HpeSNMPAlertDestination, path: /redfish/v1/Managers/1/SnmpService/SNMPAlertDestinations/1/
Saving properties of type: HpeServerBootSettings, path: /redfish/v1/systems/1/bios/boot/settings/
Saving properties of type: HpeiLODateTime, path: /redfish/v1/Managers/1/DateTime/
Remember to edit the Federation key for acct: 'DEFAULT'.
Saving properties of type: HpeiLOFederationGroup, path: /redfish/v1/Managers/1/FederationGroups/DEFAULT/
Remember to edit the Federation key for acct: 'fed1'.
Saving properties of type: HpeiLOFederationGroup, path: /redfish/v1/Managers/1/FederationGroups/f250jenkins/
Remember to edit the Federation key for acct: '9P0Rn2'.
Saving properties of type: HpeiLOFederationGroup, path: /redfish/v1/Managers/1/FederationGroups/9P0Rn2/
License Key Found ending in: XXXXX
Remember to verify your License Key...
Saving properties of type: HpeiLOLicense, path: /redfish/v1/Managers/1/LicenseService/1/
Saving properties of type: HpeiLOSSO, path: /redfish/v1/Managers/1/SecurityService/SSO/
Saving properties of type: HpeiLOSnmpService, path: /redfish/v1/Managers/1/SnmpService/
Saving properties of type: Manager, path: /redfish/v1/Managers/1/
Remember to edit password for user: 'Administrator', login name: 'Administrator'.
Saving properties of type: ManagerAccount, path: /redfish/v1/AccountService/Accounts/1/
Remember to edit password for user: 'username', login name: 'username'.
Saving properties of type: ManagerAccount, path: /redfish/v1/AccountService/Accounts/2/
Remember to edit password for user: 'admin', login name: 'admin'.
Saving properties of type: ManagerAccount, path: /redfish/v1/AccountService/Accounts/120/
Saving properties of type: ManagerNetworkProtocol, path: /redfish/v1/Managers/1/NetworkProtocol/
Saving properties of type: SecureBoot, path: /redfish/v1/Systems/1/SecureBoot/
Saving properties of type: SmartStorageConfig, path: /redfish/v1/systems/1/smartstorageconfig/settings/
Saving of clonefile to 'ilorest_clone.json' is complete.

To load a clone file run the command with the load argument. You can specify a filename using the (-f, --filename) option, if this option is not used the command will search for ilorest_clone.json.

iLOrest > serverclone load -f ilorest_clone.json
A configuration file 'ilorest_clone.json' containing configuration changes will be applied to this iLO server resulting in system setting changes for BIOS, ethernet controllers, disk controllers, deletion and rearrangement of logical disks...etc. Please confirm you acknowledge and would like to perform this operation now? (y/n)

Proceeding with ServerClone Load Operation...
This system has BIOS Version U32.
BIOS Versions are different. Suggest to have 'U30' in place before upgrading.
This system has has iLO 5 with firmware revision 1.40.
iLO Versions are compatible.
iLO Firmware Revisions are compatible.
Would you like to continue with migration of iLO configuration from 'ProLiant DL380 Gen10' to 'ProLiant DL360 Gen10'? (y/n)

Attempting Clone from a 'ProLiant DL380 Gen10' to a 'ProLiant DL360 Gen10'.
The contents of type: '#HpeServerBootSettings.v2_0_0.HpeServerBootSettings' should be compatible with '#HpeServerBootSettings.v2_0_0.HpeServerBootSettings', on this system.
The contents of type: '#SecureBoot.v1_0_0.SecureBoot' should be compatible with '#SecureBoot.v1_0_0.SecureBoot', on this system.
The contents of type: '#Manager.v1_3_3.Manager' should be compatible with '#Manager.v1_3_3.Manager', on this system.
The contents of type: '#Bios.v1_0_0.Bios' should be compatible with '#Bios.v1_0_0.Bios', on this system.
The contents of type: '#HpeiLOSSO.v2_0_0.HpeiLOSSO' should be compatible with '#HpeiLOSSO.v2_0_0.HpeiLOSSO', on this system.
The contents of type: '#HpeiLOSnmpService.v2_2_0.HpeiLOSnmpService' should be compatible with '#HpeiLOSnmpService.v2_2_0.HpeiLOSnmpService', on this system.
The contents of type: '#HpeiLOFederationGroup.v2_0_0.HpeiLOFederationGroup' should be compatible with '#HpeiLOFederationGroup.v2_0_0.HpeiLOFederationGroup', on this system.
Adding 'DEFAULT' to iLO Federation.
This account already exists on this system: 'DEFAULT'
Changing Federation account: 'DEFAULT's' key. Privileges will not be altered.
The operation completed successfully.
The contents of type: '#HpeiLODateTime.v2_0_0.HpeiLODateTime' should be compatible with '#HpeiLODateTime.v2_0_0.HpeiLODateTime', on this system.
The contents of type: '#ManagerAccount.v1_1_3.ManagerAccount' should be compatible with '#ManagerAccount.v1_1_3.ManagerAccount', on this system.
Adding user 'Ldpksh' to iLO Accounts.
The account name 'Ldpksh' already exists on this system.
Checking for and implementing account modification.
Changing account password for 'Ldpksh'.
The account was modified successfully.
Changing privileges for 'Ldpksh'.
The account was modified successfully.
The contents of type: '#ManagerAccount.v1_1_3.ManagerAccount' should be compatible with '#ManagerAccount.v1_1_3.ManagerAccount', on this system.
Adding user 'Administrator' to iLO Accounts.
An error occurred: Privilege SystemRecoveryConfigPriv is not available on this iLO version.. Check the ServerClone Error logfile for further info: clone_error_logfile.log
Logging error to 'clone_error_logfile.log'.
The contents of type: '#AccountService.v1_3_0.AccountService' should be compatible with '#AccountService.v1_3_0.AccountService', on this system.
The contents of type: '#ManagerNetworkProtocol.v1_0_0.ManagerNetworkProtocol' should be compatible with '#ManagerNetworkProtocol.v1_0_0.ManagerNetworkProtocol', on this system.
The contents of type: '#EthernetInterface.v1_4_1.EthernetInterface' should be compatible with '#EthernetInterface.v1_4_1.EthernetInterface', on this system.
iLO response with code [400]: The value for the property is the correct type, but this value is incompatible with the current value of another property.
This machine may not have a reconfigurable MACAddress...Retrying without patching MACAddress.
The operation has been completed successfully.
The contents of type: '#EthernetInterface.v1_4_1.EthernetInterface' should be compatible with '#EthernetInterface.v1_4_1.EthernetInterface', on this system.
The operation completed successfully.
NIC Interface Disabled.
The contents of type: '#ComputerSystem.v1_4_0.ComputerSystem' should be compatible with '#ComputerSystem.v1_4_0.ComputerSystem', on this system.
The contents of type: '#SmartStorageConfig.v2_0_0.SmartStorageConfig' should be compatible with '#SmartStorageConfig.v2_0_0.SmartStorageConfig', on this system.
The contents of type: '#HpeiLOLicense.v2_1_1.HpeiLOLicense' should be compatible with '#HpeiLOLicense.v2_1_1.HpeiLOLicense', on this system.
Attempting to load a license key to the server.
The resource has been created successfully.
The type: '#HpeESKM.v2_0_0.HpeESKM' was not found on this system. Associated properties can not be applied...Skipping
Loading configuration...
Committing changes...
The property you are trying to change has been updated. Please check entry again before manipulating it.
The system is ready to be reset. Perform a reset now? (y/n)

Resetting iLO...

After iLO resets the session will be terminated.
Please wait for iLO to initialize completely before logging in again.
This process may take up to 3 minutes.

A management processor reset is in progress.
Sleeping 120 seconds for iLO reset...
Logging session out.
Discovering data...Done
Resetting System...
System already Powered Off: PowerOff
Loading of clonefile 'ilorest_clone.json' to server is complete. Review the changelog file 'changelog.log'.

To load a clone file with SSO and/or TLS certificates run the command with the load argument and include the --tlscert and/or --ssocert arguments followed by certificate files.

iLOrest > login
Discovering data...Done
iLOrest > serverclone load  --silent --tlscert sso_certificate.txt --ssocert certificate.txt
This system has BIOS Version U32.
BIOS Versions are different. Suggest to have 'U30' in place before upgrading.
This system has has iLO 5 with firmware revision 1.40.
iLO Versions are compatible.
iLO Firmware Revisions are compatible.
Attempting Clone from a 'ProLiant DL380 Gen10' to a 'ProLiant DL360 Gen10'.
Uploading SSO Certificate...
The operation completed successfully.
Uploading TLS Certificate...
The operation completed successfully.
The contents of type: '#HpeServerBootSettings.v2_0_0.HpeServerBootSettings' should be compatible with '#HpeServerBootSettings.v2_0_0.HpeServerBootSettings', on this system.
The contents of type: '#SecureBoot.v1_0_0.SecureBoot' should be compatible with '#SecureBoot.v1_0_0.SecureBoot', on this system.
The contents of type: '#Manager.v1_3_3.Manager' should be compatible with '#Manager.v1_3_3.Manager', on this system.
The contents of type: '#Bios.v1_0_0.Bios' should be compatible with '#Bios.v1_0_0.Bios', on this system.
The contents of type: '#HpeiLOSSO.v2_0_0.HpeiLOSSO' should be compatible with '#HpeiLOSSO.v2_0_0.HpeiLOSSO', on this system.
The contents of type: '#HpeiLOSnmpService.v2_2_0.HpeiLOSnmpService' should be compatible with '#HpeiLOSnmpService.v2_2_0.HpeiLOSnmpService', on this system.
The contents of type: '#HpeiLOFederationGroup.v2_0_0.HpeiLOFederationGroup' should be compatible with '#HpeiLOFederationGroup.v2_0_0.HpeiLOFederationGroup', on this system.
...

An example of simultaneously deleting one account and adding another within a JSON file. For new accounts, the path is simply a placeholder, iLO will determine the URI to be used.

Clone file snippet to be modified; the element to be removed is highlighted.

{
  ... 
  "#ManagerAccount.v1_1_3.ManagerAccount": {
    "/redfish/v1/AccountService/Accounts/1/": {
      "Privileges": {
        "HostNICConfigPriv": true, 
        "HostStorageConfigPriv": true, 
        "RemoteConsolePriv": true, 
        "iLOConfigPriv": true, 
        "VirtualMediaPriv": true, 
        "UserConfigPriv": true, 
        "HostBIOSConfigPriv": true, 
        "VirtualPowerAndResetPriv": true, 
        "LoginPriv": true, 
        "SystemRecoveryConfigPriv": true
      }, 
      "Password": "password", 
      "User_Name": "Administrator", 
      "Login_Name": "Administrator", 
      "AccountType": "User Account"
    }, 
    
    "/redfish/v1/AccountService/Accounts/16/": {
      "Privileges": {
        "HostNICConfigPriv": true, 
        "HostStorageConfigPriv": true, 
        "RemoteConsolePriv": true, 
        "iLOConfigPriv": true, 
        "VirtualMediaPriv": true, 
        "UserConfigPriv": true, 
        "HostBIOSConfigPriv": true, 
        "VirtualPowerAndResetPriv": true, 
        "LoginPriv": true, 
        "SystemRecoveryConfigPriv": false
      }, 
      "Password": "strongestavenger", 
      "User_Name": "thor", 
      "Login_Name": "Thor", 
      "AccountType": "User Account"
    }
    
  }
  ...
}

New version of clone file. The new element added is highlighted.

{
  ... 
  "#ManagerAccount.v1_1_3.ManagerAccount": {
    "/redfish/v1/AccountService/Accounts/1/": {
      "Privileges": {
        "HostNICConfigPriv": true, 
        "HostStorageConfigPriv": true, 
        "RemoteConsolePriv": true, 
        "iLOConfigPriv": true, 
        "VirtualMediaPriv": true, 
        "UserConfigPriv": true, 
        "HostBIOSConfigPriv": true, 
        "VirtualPowerAndResetPriv": true, 
        "LoginPriv": true, 
        "SystemRecoveryConfigPriv": true
      }, 
      "Password": "password", 
      "User_Name": "Administrator", 
      "Login_Name": "Administrator", 
      "AccountType": "User Account"
    }
    
    "/redfish/v1/AccountService/Accounts/4/": {
      "Privileges": {
        "HostNICConfigPriv": true, 
        "HostStorageConfigPriv": true, 
        "RemoteConsolePriv": true, 
        "iLOConfigPriv": true, 
        "VirtualMediaPriv": true, 
        "UserConfigPriv": true, 
        "HostBIOSConfigPriv": true, 
        "VirtualPowerAndResetPriv": true, 
        "LoginPriv": true, 
        "SystemRecoveryConfigPriv": false
      }, 
      "Password": "godofmischief", 
      "User_Name": "loki", 
      "Login_Name": "Loki", 
      "AccountType": "User Account"
    }
    
  }
  ...
}

Syntax

serverclone [save/load] [OPTIONS]

Description

Creates a JSON formatted clone file of a system’s iLO and Bios configuration by default. Optionally you can include SSA configuration as well as load SSO and TLS certificates.

Parameters

Used to save a clone file.

Used to load a clone file.

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

Use this command to logout.

Select this flag to input a BIOS password. Include this flag if second-level BIOS authentication is needed for the command to execute.

Use this command optionally to encrypt/decrypt a file using the key provided.

Use this command during ‘load’ to include an SSO certificate. This should be properly formatted in a simple text file.

Use this command during 'load’ to include a TLS certificate. This should be properly formatted in a simple text file.

This is an optional command used to rename the default clone file 'ilorest_clone.json’.

Allow for save to automatically archive the clone file and error log file. Use with load will archive the clone file, temporary patch file, error log file and changelog file.

Use this command to override the measures stopping the tool from writing over items that are system unique.

This is an optional command used to ignore user prompts for save or load processes.

This is an optional command used to include configuration of iLO Smart Array Devices during save or load processes.

This is an optional command used to remove Bios configuration during save or load processes.

Inputs

None

Outputs

None

iLO Repository Commands

Deletecomp command

Deletecomp example commands:

To delete firmware by file name run the command with the file name as an argument. You can also delete multiple files by file name.

iLOrest > deletecomp ilo5_137.bin
The operation completed successfully.
Deleted ilo5_137.bin

To delete firmware by Id run the command with the file Ids as arguments. You can also delete a single file by Id.

iLOrest > deletecomp 30d2d7fa b5a00edc
The operation completed successfully.
Deleted 30d2d7fa
The operation completed successfully.
Deleted b5a00edc

To delete all firmware on the iLO repository run the command and include the --all option.

iLOrest > deletecomp --all
The operation completed successfully.

Syntax

deletecomp [ID/Name(s)] [Optional Parameters]

Description

Deletes firmware from the iLO repository.

Parameters

The name or Id(s) of the components for deletion. Multiple components should be specified by a comma separated list without spaces.

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Delete all firmware.

Inputs

None

Outputs

None

Downloadcomp command

Downloadcomp example commands:

To download a file run this command specifying the file path of the firmware.

iLOrest > downloadcomp /fwrepo/ilo5_137.bin
Downloading component, this may take a while...
[200] The operation completed successfully.
Download complete
0 hour(s) 1 minute(s) 36 second(s)

Syntax

downloadcomp [File Path] [Optional Parameters]

Description

Downloads firmware from the iLO repository.

Parameters

-File Path

The path to the firmware to download.

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Optionally include this flag if you would prefer to connect using a session id instead of a normal login.

Optionally include logs in the data retrieval process.

Optionally include the logout flag to log out of the server after this command is completed. Using this flag when not logged in will have no effect.

output directory for saving the file.

Inputs

None

Outputs

None

Flashfwpkg command

flashfwpkg example commands:

To upload firmware and flash (or stage for a flash) run the command with the .fwpkg file.

iLOrest > fwpkg U32_1.46_10_02_2018.fwpkg
Uploading firmware: U32_1.46_10_02_2018.signed.flash
[200] The operation completed successfully.
Component U32_1.46_10_02_2018.signed.flash uploaded successfully
Waiting for iLO UpdateService to finish processing the component
0 hour(s) 1 minute(s) 28 second(s)
Firmware has successfully been flashed and a reboot is required for this firmware to take effect.

To skip checks for something blocking firmware updates also include the --ignorechecks option.

iLOrest > fwpkg ilo5_137.fwpkg --ignorechecks
Uploading firmware: ilo5_137.bin
[200] The operation completed successfully.
Component ilo5_137.bin uploaded successfully
Waiting for iLO UpdateService to finish processing the component
0 hour(s) 0 minute(s) 55 second(s)
Firmware has successfully been flashed.
iLO will reboot to complete flashing. Session will be terminated.
Logging session out.

Syntax

flashfwpkg [FWPKG PATH] [Optional Parameters]

Description

Run to upload and flash fwpkg components using the iLO repository.

Parameters

The path to the (.fwpkg) file for flashing or the (.fwpkg) file itself if it is in the current working directory.

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, use this flag along with the provided iLO URL to login to the server.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use the provided iLO password corresponding to the username you gave to login.

Include this flag to force upload firmware with the same name already on the repository.

Include this flag to ignore all checks to the taskqueue before attempting to process the .fwpkg file.

Inputs

None

Outputs

None

Installset command

Installset example commands:

To list current install sets run the command without arguments.

iLOrest > installset
Install Sets:

basic_update:
        command1: ApplyUpdate ilo5_137.bin

To add an install set run the command with the add argument followed by the install set json file. If using sequence type json file (see below) the --name option must be included.

iLOrest > installset add myinstallset.json
[201] The operation completed successfully.

To invoke an install set and have it start performing tasks run the command with the invoke argument followed by the -n, --name option specifying the name of the install set to invoke.

iLOrest > installset invoke --name basic_update
Invoking install set:basic_update
The operation completed successfully.

To delete an install set run the command with the delete argument followed by the --name specifying the name of the install set to delete.

iLOrest > installset delete --name basic_update
Deleting install set: basic_update...
The operation completed successfully.

To remove all install sets run the command with the --removeall option.

LOrest > installset --removeall
Deleting all install sets...
Deleting install set: basic_update
The operation completed successfully.

Install sets can be added by either the complete JSON structure…

{
    "Name": "installset name",
    "Description": "installset description",
    "Sequence": [{
            "Name": "Wait",
            "UpdatableBy": ["RuntimeAgent"],
            "Command": "Wait",
            "WaitTimeSeconds": 60
        },
        {
            "Name": "uniqueName",
            "UpdatableBy": ["RuntimeAgent"],
            "Command": "ApplyUpdate",
            "Filename": "filename.exe"
        },
        {
            "Name": "uniqueName2",
            "UpdatableBy": ["Bmc"],
            "Command": "ApplyUpdate",
            "WaitTimeSeconds": 0,
            "Filename": "filename2.hex"
        },
        {
            "Name": "uniqueName3",
            "UpdatableBy": ["Uefi", "RuntimeAgent"],
            "Command": "ApplyUpdate",
            "WaitTimeSeconds": 0,
            "Filename": "filename3.x86_64.rpm"
        },
        {
            "Name": "Reboot",
            "UpdatableBy": ["RuntimeAgent"],
            "Command": "ResetServer"
        }
    ],
    "IsRecovery": false
}

Or a list of sequences.

[
        {
            "Name": "Wait",
            "UpdatableBy": ["RuntimeAgent"],
            "Command": "Wait",
            "WaitTimeSeconds": 60
        },
        {
            "Name": "uniqueName",
            "UpdatableBy": ["RuntimeAgent"],
            "Command": "ApplyUpdate",
            "Filename": "filename.exe"
        },
        {
            "Name": "Reboot",
            "UpdatableBy": ["RuntimeAgent"],
            "Command": "ResetServer"
        }
]

Syntax

installset [Optional Parameters]

Description

Command to perform operations on install sets.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Install set name to create, remove, or invoke.

Remove all install sets.

Optionally include this flag to change the displayed output to JSON format. Preserving the JSON data structure makes the information easier to parse.

Optionally include this flag to set the expiry time for installset. ISO 8601 Redfish-style time string to be written after which iLO will automatically change state to Expired.

Optionally include this flag to set the earliest execution time for installset. ISO 8601 Redfish-style time string to be used.

Use this flag if the server you are currently logged into has a TPM chip installed.

If set then the components in the flash operations are used to replace matching contents in the Recovery Set.

This option clears previous items in the task queue before the Install Set is invoked.

Inputs

None

Outputs

None

Listcomp command

Listcomp example commands:

To list the firmware on the iLO repository of the currently logged in system run the command without arguments.

iLOrest > listcomp
Id: ca3bcc4b
Name: iLO 5
Version: 1.30
Locked:Yes
Component Uri:/fwrepo/ilo5_130.bin
File Path: ilo5_130.bin
SizeBytes: 33556520

Id: 30d2d7fa
Name: iLO 5
Version: 1.37
Locked:No
Component Uri:/fwrepo/ilo5_137.bin
File Path: ilo5_137.bin
SizeBytes: 33556520

Syntax

listcomp [Optional Parameters]

Description

Command to list the firmware on the iLO repository of the currently logged in system.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

Optionally include this flag if you wish to change the displayed output to JSON format. Preserving the JSON data structure makes the information easier to parse.

Inputs

None

Outputs

None

Maintenancewindow command

maintenancewindow example commands:

To list the current maintenancewindows on the system run the command without arguments.

iLOrest > maintenancewindow
MW-147746:
        Description: No description.
        Start After: 2015-11-21T00:00:00Z
        Expires at: No expire time set.

To Create a new maintenance window run the command with the add keyword followed by the time the maintenance window should start. If you do not supply a name for your maintenance window one will be randomly generated for you.

iLOrest > maintenancewindow add 2018-11-21T00:00:00
[201] The operation completed successfully.

To optionally specify an expire time (-e, --expire), maintenance window name (-n, --name), and/or description (--description) include their respective options.

iLOrest > maintenancewindow add 2019-11-21T00:00:00 --expire=2019-11-22T00:00:00 --name=MyMaintenanceWindow --description "My maintenance window description."
[201] The operation completed successfully.

To delete a maintenance window run the command with the delete keyword followed by the name of the maintenance window you wish to delete.

iLOrest > maintenancewindow delete MyMaintenanceWindow
Deleting MyMaintenanceWindow
The operation completed successfully.

Syntax

maintenancewindow [Optional Parameters]

Description

Command to add, remove, or delete maintenance windows from the iLO repository.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet , use this flag along with the provided iLO URL to login.

Optionally include this flag to change the displayed output to JSON format. Preserving the JSON data structure makes the information easier to parse.

Optionally include this flag to add a description to the maintenance window created by you.

Optionally include this flag to name the maintenance window created by you. If a name is not specified, system will add a unique name.

Optionally include this flag to add the time a maintenance window expires.

Inputs

None

Outputs

None

Makeinstallset command

Makeinstallset example commands:

Run without logging in for basic guidance on making an install set.

iLOrest > makeinstallset
Warning: This command will run in interactive mode.
Entering new shell, type backout to leave!
Running in basic guidance mode.
Enter a name for this command: command1

Possible Commands: ApplyUpdate, ResetServer, ResetBmc, Wait
Enter Command for command1: ApplyUpdate

Unique filename of component on iLO repository
Enter Filename for command1: ilo5_130.bin

Possible Update parameter(s):
Bmc: Updatable by iLO
Uefi: Updatable by Uefi
RuntimeAgent: Updatable by runtime agent such as SUM/SUT
Enter UpdatableBy for command1: Bmc

Enter a name for this command: backout
Is this a recovery installset? no
Enter installset name: basic_update
Enter description for the installset:
{
  "Sequence": [
    {
      "UpdatableBy": [
        "Bmc"
      ],
      "Command": "ApplyUpdate",
      "Name": "command1",
      "Filename": "ilo5_130.bin"
    }
  ],
  "IsRecovery": false,
  "Name": "basic_update",
  "Description": ""
}
installset saved to myinstallset.json

Run while logged into a system for guidance based on the current components on that system.

iLOrest > makeinstallset
Warning: This command will run in interactive mode.
Entering new shell, type backout to leave!
Running in logged in mode.
Enter a name for this command: update iLO

Possible Commands: ApplyUpdate, ResetServer, ResetBmc, Wait
Enter Command for update iLO: ApplyUpdate

Unique filename of component on iLO repository
Components currently in the repository that have not been added to the installset:
[1] iLO 5
[2] HP Lights-Out Online Configuration Utility for Windows x64 E...
[3] System BIOS - U30
Select the number of the component you want to add to the install set: 1

Enter a name for this command: update bios

Possible Commands: ApplyUpdate, ResetServer, ResetBmc, Wait
Enter Command for update bios: ApplyUpdate

Unique filename of component on iLO repository
Components currently in the repository that have not been added to the installset:
[1] HP Lights-Out Online Configuration Utility for Windows x64 E...
[2] System BIOS - U30
Select the number of the component you want to add to the install set: 2

Enter a name for this command: backout
Is this a recovery installset? no
Enter installset name: update fw
Enter description for the installset:
{
  "Sequence": [
    {
      "UpdatableBy": [
        "Bmc"
      ],
      "Command": "ApplyUpdate",
      "Name": "update iLO",
      "Filename": "ilo5_137.bin"
    },
    {
      "UpdatableBy": [
        "Bmc"
      ],
      "Command": "ApplyUpdate",
      "Name": "update bios",
      "Filename": "U30_1.46_10_02_2018.signed.flash"
    }
  ],
  "IsRecovery": false,
  "Name": "update fw",
  "Description": ""
}
installset saved to myinstallset.json

Syntax

makeinstallset [Optional Parameters]

Description

Run to make installsets for iLO. If not logged into the server, the command will provide basic guidance on making an installset. If logged into the server, the command will provide guidance based on the current components on the system.

Parameters

Including the help flag on this command will display help.

Include this flag to use a different filename than the default one. The default filename is myinstallset.json

Inputs

None

Outputs

None

Taskqueue command

Taskqueue example commands:

To create new wait task queue task include the create keyword followed by the amount of time to wait.

iLOrest > taskqueue create 60
[200] The operation completed successfully.
Creating task: "Wait-703879 60 seconds"
[201] The operation completed successfully.

To create a new firmware task queue task include the create keyword followed by the name of a firmware file that is already in the iLO repository.

iLOrest > taskqueue create ilo5_137.bin
[200] The operation completed successfully.
Creating task: "Update-740856 iLO 5"
[201] The operation completed successfully.

To view the current update task queue runt the command with no arguments.

iLOrest > taskqueue

Current Update Task Queue:

Task Wait-703879 60 seconds:
        Command: Wait 60 seconds
        State:Pending

Task Update-740856 iLO 5:
        Command: ApplyUpdate
        Filename: ilo5_137.bin
        State:Pending

To delete all tasks from the update task queue run the command with the --resetqueue option.

iLOrest > taskqueue --resetqueue
Deleting all update tasks...
Deleting: Wait-703879 60 seconds
The operation completed successfully.
Deleting: Update-740856 iLO 5
The operation completed successfully.

Syntax

taskqueue [Optional Parameters]

Description

Command to add or remove tasks from the task queue. Added tasks are appended to the end of the queue.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

Remove all update tasks in the queue.

Clean up all finished or errored tasks - leave pending.

Optionally include this flag if you wish to change the displayed output to JSON format. Preserving the JSON data structure makes the information easier to parse.

Include this flag when updating firmware if you have a TPM installed.

Inputs

None

Outputs

None

Uploadcomp command

Uploadcomp example commands:

To upload firmware to the iLO repository run the command with the --component option specifying the firmware file to upload.

iLOrest > uploadcomp --component ilo5_137.bin
[200] The operation completed successfully.
Component ilo5_137.bin uploaded successfully
Waiting for iLO UpdateService to finish processing the component
0 hour(s) 1 minute(s) 43 second(s)

Syntax

uploadcomp [Optional Parameters]

Description

Command to upload firmware on to iLO repository.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

Optionally include this flag if you would prefer to connect using a session id instead of a normal login.

Optionally include logs in the data retrieval process.

Optionally include this flag if you wish to change the displayed output to JSON format. Preserving the JSON data structure makes the information easier to parse.

Optionally include the logout flag to log out of the server after this command is completed. Using this flag when not logged in will have no effect.

Component or binary file path to upload to the update service.

Component signature file path needed by iLO to authenticate the component file. If not provided, the command will try to find the signature file from component file path.

Add this flag to force upload components with the same name already on the repository.

If true, uploads the component/binary on to the Repository. The default is set to True.

If true, the uploaded component/binary will be flashed. The default is set to False.

Inputs

None

Outputs

None

Smart Arrary Commands

The Smart Array commands are designed for use with HPE Gen10 servers.

SmartArray command

To list all available smart array controllers run the command without arguments.

ilorest > smartarray
[1]: Slot 0

To list all Existing Volume Unique Identifier’s for logical drives for all controllers run the command including the --logicaldrives option. Drives which are pending will instead show “Pending Drive” for the Volume Unique Identifier (this will be available after the system has been rebooted and the drive has been successfully created.). The information is presented such that the controller slot number is noted first, followed by all associated logical drives to that controller.

iLOrest > login
Discovering data...Done
ilorest > smartarray --logicaldrives
[1]: Slot 0
Logical Drives:
[1]: 600508B1001C599DE361257397F69972
[2]: Pending drive
[3]: Pending drive

To list all physical drives for all available controllers, run the command with the --physicaldrives option. The controller will be provided first followed by drive information (as associated to that controller). Drive information is in the format, [Controller Port (Internal)]:[Box]:[Bay].

iLOrest > login
Discovering data...Done
ilorest > smartarray --physicaldrives
[1]: Slot 0
Physical Drives:
[1]: 1I:3:4
[2]: 1I:3:3
[3]: 1I:3:2
[4]: 1I:3:1
[5]: 2I:3:5
[6]: 2I:3:6

To return a JSON formatted response including controller settings, as well as physical and logical drives information on the selected controller, include the --controller option followed by the number in brackets associated to the controller.

 
ilorest > smartarray --controller=1
{
  "CurrentParallelSurfaceScanCount": 1, 
  "DataGuard": "Disabled", 
  "DegradedPerformanceOptimization": "Disabled", 
  "DriveWriteCache": "Disabled", 
  "ElevatorSort": "Enabled", 
  "EncryptionConfiguration": "None", 
  "EncryptionEULA": null, 
  "ExpandPriority": "Medium", 
  "FlexibleLatencySchedulerSetting": "Default", 
  "InconsistencyRepairPolicy": "Disabled", 
  "Location": "Slot 0", 
  "LocationFormat": "PCISlot", 
  "LogicalDrives": [
    {
      "CapacityBlocks": 1172058032, 
      "ParityGroupCount": 0, 
      "SpareRebuildMode": null, 
      "Raid": "Raid0", 
      "LogicalDriveNumber": 1, 
      "Accelerator": "ControllerCache", 
      "BlockSizeBytes": 512, 
      "CapacityGiB": 558, 
      "SpareDrives": [], 
      "DriveLocationFormat": "ControllerPort:Box:Bay", 
      "LogicalDriveName": "004D56ABPEYHC0ARH951TK A39C", 
      "VolumeUniqueIdentifier": "600508B1001C599DE361257397F69972", 
      "StripeSizeBytes": 262144, 
      "StripSizeBytes": 262144, 
      "DataDrives": [
        "1I:3:2"
      ]
  ...

To return a JSON formatted response regarding the settings and attributes of the selected physical drive on the selected controller include the --controller option specifying the controller and the --pdrive option specifying the physical drive number in brackets.

ilorest > smartarray --controller=1 --pdrive=1
{
  "BlockSizeBytes": 512, 
  "CapacityGB": 400, 
  "CapacityLogicalBlocks": 781422768, 
  "CapacityMiB": 381554, 
  "CarrierApplicationVersion": "11", 
  "CarrierAuthenticationStatus": "OK", 
  "CurrentTemperatureCelsius": 41, 
  "DiskDriveStatusReasons": [
    "None"
  ], 
  "DiskDriveUse": "Raw", 
  "EncryptedDrive": false, 
  "FirmwareVersion": {
    "Current": {
      "VersionString": "HPD3"
    }
  }, 
  "InterfaceSpeedMbps": 12000, 
  "InterfaceType": "SAS", 
  "LegacyBootPriority": "Primary", 
  "Location": "1I:3:4", 
  "LocationFormat": "ControllerPort:Box:Bay", 
  "MaximumTemperatureCelsius": 46, 
  "MediaType": "SSD", 
  "Model": "MO0400JEFPA", 
  "PowerOnHours": 5943, 
  "SSDEnduranceUtilizationPercentage": 0, 
  "SerialNumber": "0QV2MS1A", 
  "Status": {
    "State": "Enabled", 
    "Health": "OK"
  }, 
  "UncorrectedReadErrors": 0, 
  "UncorrectedWriteErrors": 0
}

To return a JSON formatted response regarding the settings and attributes of the selected logical drive on the selected controller include the --controller option specifying the controller and the --ldrive option specifying the logical drive number in brackets.

iLOrest > smartarray --controller=1 --ldrive=1
{
  "Accelerator": "ControllerCache", 
  "BlockSizeBytes": 512, 
  "CapacityBlocks": 1172058032, 
  "CapacityGiB": 558, 
  "DataDrives": [
    "1I:3:2"
  ], 
  "DriveLocationFormat": "ControllerPort:Box:Bay", 
  "LegacyBootPriority": "None", 
  "LogicalDriveName": "004D56ABPEYHC0ARH951TK A39C", 
  "LogicalDriveNumber": 1, 
  "ParityGroupCount": 0, 
  "Raid": "Raid0", 
  "SpareDrives": [], 
  "SpareRebuildMode": null, 
  "StripSizeBytes": 262144, 
  "StripeSizeBytes": 262144, 
  "VolumeUniqueIdentifier": "600508B1001C599DE361257397F69972"
}

Syntax

Smartarray [Optional Parameters]

Description

Discovers all storage controllers installed in the server and managed by the SmartStorage.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Use this flag to select the corresponding controller.

Use this flag to return the physical drives for the controller selected.

Use this flag to return the logical drives for the controller selected.

Use this flag to select the corresponding physical disk.

Use this flag to select the corresponding logical disk.

Inputs

None

Outputs

None

Clearcontrollerconfig command

Clearcontrollerconfig example commands:

To clear a controller configuration run the command including the --controller option specifying the controller to clear.

 
ilorest > clearcontrollerconfig --controller=1
One or more properties were changed an will not take effect until system is reset.

To clear controller configuration on all available smart array controllers use --all.

 
ilorest > clearcontrollerconfig --all
Are you sure you would like to clear all available smart array controller configurations? (y/n)  y 
One or more properties were changed an will not take effect until system is reset.

Syntax

clearcontrollerconfig [Optional Parameters]

Description

Clears smart array controller configuration.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Use this flag to select the corresponding controller.

Use this flag to factory reset all controllers.

Use this flag to override the “are you sure?” text when clearing configurations on all available smart array controllers.

Inputs

None

Outputs

None

Createlogicaldrive command

Createlogicaldrive example commands:

To create a quick logical drive run the command with the following arguments: The type of creation as quickdrive, the raid level, the number of drives to use, the type of drive to use, the drive interface type, and the drive location. Also include the --controller option selecting the controller the drive will be created on. See the options list for possible values of these and more.

 
ilorest > createlogicaldrive quickdrive Raid0 2 HDD SATA Internal --controller=1
One or more properties were changed an will not take effect until system is reset.

To create a custom logical drive run the command with the following arguments: The type of creation as customdrive, the raid level, and the physicaldrive index(s). Also include the --controller option selecting the controller the drive will be created on. See the options list for possible values of these and more.

 
iLOrest > login
Discovering data...Done
ilorest > createlogicaldrive customdrive Raid5 2,3,4,5,6 --controller=1 --name=ANewLogicalDrive --spare-drives=2 --capacityGiB=100 --legacy-boot=Primary --accelerator-type=ControllerCache --spare-type=Dedicated
One or more properties were changed an will not take effect until system is reset.

Syntax

createlogicaldrive [Optional Parameters]

Description

Creates a new logical drive on the selected controller.

Options: - raid-level: Raid0, Raid1, Raid1ADM, Raid10, Raid10ADM, Raid5, Raid50, Raid6, Raid60 - media-type: SSD,HDD - interface-type: SAS, SATA - drive-location: Internal, External - –spare-type: Dedicated, Roaming - –accelerator-type: ControllerCache, IOBypass, None - –paritytype: Default, Rapid

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Use this flag to select the corresponding controller.

Optionally include to set the drive name (usable in custom creation only).

Optionally include to set the spare drives by the physical drive’s index (usable in custom creation only).

Optionally include to set the capacity of the drive in GiB (usable in custom creation only, use -1 for max size).

Optionally include to choose the spare drive type (usable in custom creation only).

Optionally include to choose the accelerator type.

Optionally include to choose the legacy boot priority (usable in custom creation only).

Optionally include to choose the capacity in blocks (use -1 for max size, usable in custom creation only).

Optionally include to include the number of parity groups to use (only valid for certain RAID levels).

Optionally include to choose the parity initialization type (usable in custom creation only).

Optionally include to choose the block size of the disk drive (usable in custom creation only).

Optionally include to choose the strip size in bytes (usable in custom creation only).

Optionally include to choose the stripe size in bytes (usable in custom creation only).

Inputs

None

Outputs

None

Deletelogicaldrive command

Deletelogicaldrive example commands:

To delete multiple logical drives by index include the index of the drive you wish to delete. Also include the --controller option specifying the controller to use. You can specify multiple drives as well as a comma separated list.

 
ilorest > deletelogicaldrive --controller=1 1
Are you sure you would like to continue deleting drive 004D56ABPEYHC0ARH951TK A39C? (y/n)
Setting logical drive 004D56ABPEYHC0ARH951TK A39C for deletion
One or more properties were changed and will not take effect until system is reset.

To delete all logical drives on a controller include the--controller option specifying the controller to perform the operation on and the --all option.

 
iLOrest > login
Discovering data...Done
ilorest > deletelogicaldrive --controller=1 --all
[200] The operation completed successfully.

Syntax

deletelogicaldrive [Optional Parameters]

Description

Deletes logical drives from the selected controller.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Use this flag to select the corresponding controller.

Use this flag to delete all logical drives on a controller.

Use this flag to override the “are you sure?” text when deleting a logical drive.

Inputs

None

Outputs

None

Drivesanitize command

Drivesanitize example commands:

To sanitize a physical drive pass its index along with the --controller option to dpecify which controller to perform the operation on.

 
ilorest > drivesanitize --controller=1 1
Setting physical drive 1I:3:4 for sanitization
One or more properties were changed and will not take effect until system is reset.
Sanitization will occur on the next system reboot.

To sanitize multiple physical drives pass the indexes as a comma separated list along with the --controller option to dpecify which controller to perform the operation on.

 
ilorest > drivesanitize --controller=1 2,3,4
Setting physical drive 1I:3:3 for sanitization
Setting physical drive 1I:3:2 for sanitization
Setting physical drive 1I:3:1 for sanitization
One or more properties were changed and will not take effect until system is reset.
Sanitization will occur on the next system reboot.

Syntax

drivesanitize [Optional Parameters]

Description

Erase/Sanitizes physical drives.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Use this flag to select the corresponding controller.

Include this flag to perform a coldboot command function after completion of operations and monitor sanitization.

Use this flag to sanitize all physical drives on a controller.

Inputs

None

Outputs

None

Factoryresetcontroller command

Factoryresetcontroller example commands:

To factory reset a controller run this command and specify it’s index with the --controller option.

 
ilorest > factoryresetcontroller --controller=1
One or more properties were changed and will not take effect until system is reset.

To factory reset all controllers --all option.

 
ilorest > factoryresetcontroller --all
Are you sure you would like to factory reset all available smart array controllers? (y/n) y
[1]: Slot 0 - has been reset to factory defaults.
[2]: Slot 1 - has been reset to factory defaults.
[3]: Slot 3 - has been reset to factory defaults.

Syntax

factoryresetcontroller [Optional Parameters]

Description

Restores a controller to factory defaults.

Parameters

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Use this flag to select the corresponding controller.

Use this flag to factory reset all controllers.

Use this flag to override the “are you sure?” text when performing a factory reset to selected smart array controllers.

Inputs

None

Outputs

None

Persistent Memory Commands

This section includes commands related to the discovery and configuration of HPE Persistent Memory.

Persistent Memory Discovery Command

Example: Show information about the physical persistent memory modules.

iLOrest > showpmm --device

Location        Capacity    Status    DIMMStatus    Life    FWVersion
PROC 1 DIMM 1   126.38 GB   OK        GoodInUse     100%    01.02.00.5360
PROC 1 DIMM 12  126.38 GB   OK        GoodInUse     100%    01.02.00.5360
PROC 2 DIMM 1   126.38 GB   OK        GoodInUse     100%    01.02.00.5360
PROC 2 DIMM 12  126.38 GB   OK        GoodInUse     100%    01.02.00.5360

Example: Show current configuration of selected persistent memory modules.

iLOrest > showpmm --config --dimm=1@12,2@12

Location        VolatileSize    PmemSize    PmemInterleaved
PROC 1 DIMM 12  126.38 GB       0.0 GB      N/A
PROC 2 DIMM 12  126.38 GB       0.0 GB      N/A

Example: Show the persistent interleave regions in JSON format.

iLOrest > showpmm --logical --dimm=1@12,2@12

[ { 'DimmIds': '1@1, 1@12',
    'PmemSize': { 'Units': 'GB',
                  'Value': 252.0}},
  { 'DimmIds': '2@1, 2@12',
    'PmemSize': { 'Units': 'GB',
                  'Value': 252.0}}]

Example: Show a summary of the persistent memory resources.

iLOrest > showpmm --summary

TotalCapacity:  505.52 GB
TotalVolatileSize:  505.52 GB
TotalPmemSize:  0.0 GB

Syntax

showpmm –device | -D [–dimm=(DIMM IDs) | -I] [–json | -j]

showpmm –config | -C [–dimm=(DIMM IDs) | -I] [–json | -j]

showpmm –logical | -L [–json | -j]

showpmm –summary | -M [–json | -j]

Description

Displays information about the installed persistent memory modules.

Parameters

Displays help on the usage of this command.

Shows a physical overview of the installed persistent memory modules.

Shows the current configuration of the installed persistent memory modules.

Shows the persistent interleave sets (if present).

Shows a summary of the installed persistent memory modules.

Optionally, use this flag to filter output by DIMM IDs (ProcessorNumber@SlotNumber). Can be used in conjunction with the -D | --device or the -C | --config flags.

Optionally use this flag to display output in JSON format.

Persistent Memory Guided Configuration Command

Example: Show a list of supported guided configurations.

iLOrest > applypmmconfig --list

Available Configurations:

MemoryMode
        Configure all PMMs to 100% Memory Mode.
PmemInterleaved
        Configure all PMMs to 100% Persistent. Interleave the Persistent memory regions within each processor.
PmemNotInterleaved
        Configure all PMMs to 100% Persistent. The Persistent memory regions are not interleaved.

Example: Configure all installed persistent memory modules as 100% Volatile.

iLOrest > applypmmconfig --config MemoryMode


***WARNING: Configuration changes require reboot to take effect***

Operation    PmemSize    VolatileSize    DimmIds
CREATE       0.0 GB      252.76 GB       1@1, 1@12
CREATE       0.0 GB      252.76 GB       2@1, 2@12

Syntax

applypmmconfig -L | –list

applypmmconfig -C | –config [-f | –force]

Description

Apply a pre-defined configuration to the installed persistent memory modules.

Parameters

Displays help on the usage of this command.

Display a list of available pre-defined configIDs along with a brief description.

Specify one of the pre-defined configIDs to apply to all the persistent memory modules.

Allow the user to force the configuration by automatically accepting any prompts.

Persistent Memory Advanced Configuration Command

Example: Configure all persistent memory modules on processors 1 and 3 to 50% Volatile with no persistent interleave regions.

iLOrest > provisionpmm -m 50 -i off -p 1,3

***WARNING: Configuration changes require reboot to take effect***

Operation    PmemSize    VolatileSize    DimmIds
CREATE       63.19 GB    63.19 GB        1@1
CREATE       63.19 GB    63.19 GB        1@12
CREATE       63.19 GB    63.19 GB        3@1
CREATE       63.19 GB    63.19 GB        3@12

Example: Configure all installed persistent memory modules to 25% Volatile with persistent interleave regions.

iLOrest > provisionpmm -m 25 -i on

***WARNING: Configuration changes require reboot to take effect***

Operation    PmemSize    VolatileSize    DimmIds
DELETE       126.0 GB    126.76 GB       1@1, 1@12
DELETE       126.0 GB    126.76 GB       2@1, 2@12
CREATE       189.57 GB   63.19 GB        1@1, 1@12
CREATE       189.57 GB   63.19 GB        2@1, 2@12

Syntax

provisionpmm [-h | –help] [-m | –memory-mode=(0|%)] [-i | –pmem-interleave=(On|Off)] [-p | –proc=(processorID)] [-f | –force]

Description

Applies user specified configuration to the persistent memory modules.

Parameters

Displays help on the usage of this command.

Optionally allows user to specify the percentage of total capacity that should be configured as Volatile. Defaults to 0% Volatile. The remaining capacity will be configured as Persistent.

Indicates whether the persistent memory regions should be interleaved (Allowed values: “on”, “off”).

Optionally allows user to specify the processors (comma separated list of ProcessorNumbers) on which the selected configuration would be applied. Defaults to all processors.

Allows the user to force the configuration by automatically accepting any prompts.

Show Pending Configuration Command

Example: Show persistent memory configuration changes pending a reboot.

iLOrest > showpmmpendingconfig

Operation    PmemSize    VolatileSize    DimmIds
DELETE       190.0 GB    62.76 GB        1@1, 1@12
DELETE       190.0 GB    62.76 GB        2@1, 2@12
CREATE       94.78 GB    31.59 GB        1@1
CREATE       94.78 GB    31.59 GB        1@12
CREATE       94.78 GB    31.59 GB        2@1
CREATE       94.78 GB    31.59 GB        2@12

Syntax

showpmmpendingconfig [-j | –json]

Description

Shows the queued tasks pending a reboot for configuring the persistent memory modules.

Parameters

Displays help on the usage of this command.

Optionally, use this flag to display output in JSON format.

Clear Pending Configuration Command

Example: Clears all the pending persistent memory configuration tasks.

iLOrest > clearpmmpendingconfig

Deleted Task #1948
Deleted Task #1949
Deleted Task #1950
Deleted Task #1951
Deleted Task #1952
Deleted Task #1953

Syntax

clearpmmpendingconfig

Description

Clears all the pending persistent memory configuration tasks.

Parameters

Displays help on the usage of this command.

Example: Show a list of recommended persistent memory configurations

iLOrest > showrecommendedpmmconfig

MemoryModeTotalSize    PmemTotalSize    CacheRatio
0 GB                   505 GB           N/A
377 GB                 128 GB           1:2.9
505 GB                 0 GB             1:3.9

Syntax

showrecommendedpmmconfig

Description

Shows the recommended persistent memory configurations.

Parameters

Displays help on the usage of this command.

Raw commands

This section lists the raw HTTP RESTful operations that can be used through the RESTful Interface Tool. The commands in this section are the equivalents of HTTP RESTful PATCH, GET, POST, PUT, DELETE, and HEAD.

RawPatch command

RawPatch example commands:

To directly patch to a URI with JSON data run the command supplying a filename with a json payload.

iLOrest > rawpatch rawpatch.json
The operation completed successfully.

The following rawpatch.json file was used in the above example:

{
    "path": "/redfish/v1/systems/1",
    "body": {
        "AssetTag": "NewAssetTag"
    }
}

Syntax

rawpatch [Filename] [Optional Parameters]

Description

Use this command to perform an HTTP RESTful Patch command. Run to send a patch from the data in the input file.

Parameters

Filename parameter example:

{
    "path": "/redfish/v1/systems/1",
    "body": {
        "AssetTag": "NewAssetTag"
    }
}

Include the filename to use the data in the input file to send the patch. See the example JSON file that can be used to rawpatch on the side.

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Optionally include this flag if you would prefer to connect using a session id instead of a normal login.

Use this flag to silence responses.

Use this flag to return the iLO response body.

Use this flag to return the iLO response headers.

Use this flag to add extra headers to the request.

Usage: –headers=HEADER:VALUE,HEADER:VALUE

Select this flag to input a BIOS password. Include this flag if second-level BIOS authentication is needed for the command to execute.

Use to pass in the provider ID header.

Use this flag to enable service mode and increase the function speed.

Inputs

File

Input the file containing the JSON information you wish to use for the HTTP RESTful PATCH command.

Outputs

None

RawGet command

RawGet example commands:

To get the complete JSON response directly from the URI requested run the command specifying a URI to retrieve.

LOrest > rawget /redfish/v1/systems/1
[200] The operation completed successfully.
{
  "BiosVersion": "U32 v2.10 (12/14/2018)",
  "SKU": "Kappa",
  "PowerState": "On",
  "Processors": {
    "@odata.id": "/redfish/v1/Systems/1/Processors"
  },
  "SerialNumber": "Kappa",
  "Boot": {
    "BootSourceOverrideTarget": "Cd",
    "BootSourceOverrideTarget@Redfish.AllowableValues": [
      "None",
      "Cd",
      "Hdd",
      "Usb",
      "SDCard",
      "Utilities",
      "Diags",
      "BiosSetup",
      "Pxe",
      "UefiShell",
      "UefiHttp",
      "UefiTarget"
    ],

Specify a file to save the response to by including the -f, --filename option.

LOrest > rawget /redfish/v1/systems/1 -f system.json
[200] The operation completed successfully.
Results written out to 'system.json'.

Use the --expand flag to expand collection URIs to include the response of collection members. The full response has been truncated for space.

iLOrest > rawget /redfish/v1/systems/1 -f system.json
[200] The operation completed successfully.
Results written out to 'system.json'.
iLOrest > rawget /redfish/v1/systems/
[200] The operation completed successfully.
{
  "@odata.type": "#ComputerSystemCollection.ComputerSystemCollection",
  "Description": "Computer Systems view",
  "Members@odata.count": 1,
  "@odata.id": "/redfish/v1/Systems/",
  "@odata.context": "/redfish/v1/$metadata#ComputerSystemCollection.ComputerSystemCollection",
  "Members": [
    {
      "@odata.id": "/redfish/v1/Systems/1/"
    }
  ],
  "@odata.etag": "W/\"AA6D42B0\"",
  "Name": "Computer Systems"
}
iLOrest > rawget /redfish/v1/systems/ --expand
[200] The operation completed successfully.
{
  "@odata.type": "#ComputerSystemCollection.ComputerSystemCollection",
  "Description": "Computer Systems view",
  "Members@odata.count": 1,
  "@odata.id": "/redfish/v1/Systems/",
  "@odata.context": "/redfish/v1/$metadata#ComputerSystemCollection.ComputerSystemCollection",
  "Members": [
    {
      "BiosVersion": "U32 v2.10 (12/14/2018)",
      "SKU": "Kappa",
      "PowerState": "On",
      "Processors": {
        "@odata.id": "/redfish/v1/Systems/1/Processors/"
      },
      "SerialNumber": "Kappa",
      "Boot": {
        "BootSourceOverrideTarget": "Cd",
        "BootSourceOverrideTarget@Redfish.AllowableValues": [
          "None",
          "Cd",
          "Hdd",
          "Usb",
          "SDCard",
          "Utilities",
          "Diags",
          "BiosSetup",
          "Pxe",
          "UefiShell",
          "UefiHttp",
          "UefiTarget"
        ],

Syntax

rawget [Path] [Optional Parameters]

Description

Use this command to perform an HTTP RESTful GET command. Run to retrieve data from the passed in path.

Parameters

Pass the path to the rawget command to point it at a location.

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Use this flag to return the iLO response body.

Use this flag to return the iLO response headers.

Use this flag to add extra headers to the request.

Usage: –headers=HEADER:VALUE,HEADER:VALUE

Use this flag to silence responses

Optionally include this flag if you would prefer to connect using a session id instead of a normal login.

Write results to the specified file.

Write the results to the specified file in binary.

Use this flag to enable service mode and increase the function speed.

Use this flag to expand the path specified using the expand notation ’?$expand=.’

Inputs

None

Outputs

File

If you include the filename flag, this command will return an output file of the information retrieved when the rawget command was executed.

RawPost command

RawPost example commands:

To directly post to a URI with JSON data run the command supplying a filename with a json payload.

iLOrest > rawpost rawpost.json
The operation completed successfully.

The following rawpost.json file is used in the example above:

{
    "path": "/redfish/v1/Systems/1/Actions/ComputerSystem.Reset/",
    "body": {
        "ResetType": "ForceRestart"
    }
}

Syntax

rawpost [Filename] [Optional Parameters]

Description

Use this command to perform an HTTP RESTful POST command. Run to post the data from the passed in path.

Parameters

Example Filename parameter JSON file below:

{
    "path": "/redfish/v1/Systems/1/Actions/ComputerSystem.Reset/",
    "body": {
        "ResetType": "ForceRestart"
    }
}

Include the filename to send a post from the data included in this input file. An example JSON file is shown on the side.

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Use this flag to return the iLO response body.

Use this flag to return the iLO response headers.

Use this flag to add extra headers to the request.

Usage: –headers=HEADER:VALUE,HEADER:VALUE

Use this flag to silence responses.

Optionally include this flag if you would prefer to connect using a session id instead of a normal login.

Use to pass in the provider ID header.

Use this flag to enable service mode and increase the function speed.

Inputs

File

Input the file containing the JSON information you wish to use for the HTTP RESTful PUT command.

Outputs

None

RawPut command

RawPut example commands:

To directly put to a URI with JSON data run the command supplying a filename with a json payload.

iLOrest > rawput put.json
One or more properties were changed and will not take effect until system is reset.

This example uses the following put.json file:

{
    "path": "/redfish/v1/systems/1/bios/Settings/",
    "body": {
        "Attributes": {
            "BaseConfig": "default"
        }
    }
}

Syntax

rawput [Filename] [Optional Parameters]

Description

Use this command to perform an HTTP RESTful PUT command. Run to retrieve data from the passed in path.

Parameters

Example input file below:

{
    "path": "/redfish/v1/systems/1/bios/Settings/",
    "body": {
        "Attributes": {
            "BaseConfig": "default"
        }
    }
}

Include the filename to send a PUT from the data included in this input file. Example Input file shown on the side.

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

Use this flag to return the iLO response body.

Use this flag to return the iLO response headers.

Use this flag to add extra headers to the request.

Usage: –headers=HEADER:VALUE,HEADER:VALUE

Use this flag to silence responses.

Optionally include this flag if you would prefer to connect using a session id instead of a normal login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Select this flag to input a BIOS password. Include this flag if second-level BIOS authentication is needed for the command to execute.

Use to pass in the provider ID header.

Use this flag to enable service mode and increase the function speed.

Inputs

File

Input the file containing the JSON information you wish to use for the HTTP RESTful PUT command.

Outputs

None

RawDelete command

RawDelete example commands:

To directly delete a URI run the command specifying a URI to delete.

iLOrest > rawdelete /redfish/v1/AccountService/Accounts/3/
The account was removed successfully.

Syntax

rawdelete [Path] [Optional Parameters]

Description

Use this command to perform an HTTP RESTful DELETE command. Run to delete data from the passed in path.

Parameters

Pass in the path to point the HTTP RESTful DELETE command.

Including the help flag on this command will display help on the usage of this command.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Use to pass in the provider ID header.

Optionally include this flag if you would prefer to connect using a session id instead of a normal login.

Use this flag to enable service mode and increase the function speed.

Inputs

None

Outputs

None

RawHead command

RawHead example commands:

To directly read the head values of a URI run the command specifying a URI query.

iLOrest > rawhead /redfish/v1/Systems/1/
[200] The operation completed successfully.
{
  "Content-Length": "0",
  "X_HP-CHRP-Service-Version": "1.0.3",
  "ETag": "W/\"F24B9154\"",
  "Link": "; rel=describedby",
  "Allow": "GET, HEAD, POST, PATCH",
  "Date": "Sun, 03 Feb 2019 22:33:10 GMT",
  "OData-Version": "4.0",
  "X-Frame-Options": "sameorigin"
}

Syntax

rawhead [Path] [Optional Parameters]

Description

Use this command to perform an HTTP RESTful HEAD command. Run to retrieve header data from the passed in path.

Syntax

Pass in the path to point the HTTP RESTful HEAD command.

Including the help flag on this command will display help on the usage of this command.

Include the filename to perform the current operation.

If you are not logged in yet, including this flag along with the password and URL flags can be used to log into a server in the same command.

If you are not logged in yet, use this flag along with the user and URL flags to login. Use the provided iLO password corresponding to the username you gave to login.

If you are not logged in yet, use the provided iLO URL along with the user and password flags to login to the server in the same command.

Use this flag to silence responses.

Optionally include this flag if you would prefer to connect using a session id instead of a normal login.

Use the provided filename to perform operations.

Use this flag to enable service mode and increase the function speed.

Inputs

None

Outputs

File

If you specify the filename flag, the rawhead command will output a file containing the information retrieved when performing the rawhead command.

Use case Examples and Macro Commands

The command catalog provided by the RESTful Interface Tool enables a wide variety of options to manipulate and work with the server. Multiple commands chained together have the potential to provide higher-level functionality and meet any needs that arise depending on the task at hand. Some of the more common commands, such as the bootorder command, have already been built into the command catalog. The bootorder example below shows how the available commands in the command catalog can be combined to manipulate the order of boot devices.

Changing Bootorder example

The bootorder command is made up of a list of select, get, and set commands. In order to demonstrate the order of these events, the bootorder command is manually stepped through one step at a time to show that it only uses other provided commands to perform its task.

Bootorder Example 1

First the server is logged into, and the select and get commands are performed on the Bios type and the BootMode property, respectively.

Bootorder Example 2

Next the select and get commands are used to retrieve the BootSourceOverrideSupported property of the ComputerSystem type.

Bootorder Example 3

If the bootmode retrieved earlier is UEFI, then the UefiTargetBootSourceOverrideSupported property (one time boot settings) is retrieved with the get command. If the bootmode is not UEFI, then the one time boot settings would have been set to None.

Bootorder Example 4

If this is not a one time boot or a continuous boot, and the disable boot flag has not been set, then the HpServerBootSettings type is selected with the select command, and the PersistentBootConfigOrder property is retrieved with the get command.

Bootorder Example 5

Then, using this information along with the specified boot order provided in the command, the new boot order is updated using the set command.

Bootorder Example 6

After making all the changes to the boot order, the changes are finally committed with the commit command.

All of the commands shown here are executed the same way in the actual bootorder command, and are called in the same order to execute the bootorder command. You can write your own scripts to combine commands just like bootorder did, to use the provided commands in the RESTful Interface Tool for higher level functionality.

Changing BIOS Administrator Password example

This example shows how the set password command on a Gen9 system is just a few set commands.

The Bios type has two properties that both need to be used to change the administrator password, AdminPassword and OldAdminPassword. AdminPassword is the new password you want to change to, and OldAdminPassword is the current password you have.

BIOS Password Example 1

If you perform a get command to find the current AdminPassword and OldAdminPassword values, you will notice that their values are listed as None, regardless of what their actual values are, as seen above.

BIOS Password Example 2

In order to change the administrator password, you need to set the AdminPassword (the new value you want) and the OldAdminPassword (what the admin password was before), as well as include the –biospassword flag if the system is iLO 4.

BIOS Password Example 3

After you’ve set the values for AdminPassword and OldAdminPassword, you need to commit your changes and reboot your server:

BIOS Password Example 4

Then when you log into the server again, the BIOS password will have been updated to the new value. However, you cannot see the values for AdminPassword or OldAdminPassword.

Disabling the Trusted Platform Module (TPM) on servers example

TPM Example

Above: When the server is rebooted, the TpmState is changed from PresentEnabled to PresentDisabled.

If you need to disable TPM on a group of servers, you can use a set of commands in RESTful Interface Tool. For example, if you are installing SPPs and OSs on bare-metal servers, and you need to disable TPM prior to starting installation.

Enable the TPM on servers

TPM Example

To enable the TPM, you can set the TpmState to PresentEnabled. See side example.

Finding iLO MAC address

Finding the iLO MAC address is not implemented in the RESTful Interface Tool, but is easily reached by a set of select and list commands

MAC Address Example 1

First login to the server. Then select the EthernetInterfaces. type.

MAC Address Example 2

Now using the list command, list the name, macaddress, and status values with the filter of the value Name starting with Manager.

Setting Active iLO NIC

Use this for gen10 servers.

{
    "path": "/redfish/v1/Managers/1/EthernetInterfaces/1",
    "body": {
        "Oem": { 
            "Hpe": { 
                "NICEnabled": true
            }
        }
     }
}

Use this for gen9 servers.

{
    "path": "/redfish/v1/Managers/1/EthernetInterfaces/1",
    "body": {
        "Oem": { 
            "Hp": { 
                "NICEnabled": true
            }
        }
     }
}

To set the iLO NIC, First login to the server. Then use a rawpatch command

NIC Example 1

To set the NIC, first login to the server. Then we will be using a rawpatch command

Setting iLO Timezone

In setting the iLO Timezone, we will be using both a rawpost and commands.

Timezone Example 1

First we login and select the HpeiLODateTime. type. If using Gen9, select the HpiLODateTime type instead. We then list the TimeZoneList.

Now scroll around looking for the timezone that is wanted. In the case of the example, we will be using US/Hawaii. Take note of the index associated with the Name.(2 in the case of US/Hawaii)

Timezone Example 2

Finally, we set the Index to 2. Check the status to make sure the change is queued and finally make sure to commit to finalize the changes.

Getting Powermetric Average

First login to the server.

Power Example 1

Next select the Power. type. Finally list powercontrol. The powermetric average is represented by the AverageConsumedWatts value.

Getting Encryption Settings

To get the encryption settings, first login to the server

Encryption Setting Example 1

Then select the HpeSmartStorageArrayControllerCollection type. If on a Gen9 server select HpSmartStorageArrayControllerCollection instead.

In the provided example, many of the resources for the encryption setting are not available. If available there will be values of Name, Model, SerialNumber, EncryptionBootPasswordSet, EncryptionCryptoOfficerPasswordSet, EncrpytionLocalKeyCacheEnabled, EncryptionMixedVolumesEnabled,EncryptionPhyiscalDriveCount,EncryptionRecoveryParamsSet,EncryptionStandaloneModeEnabled, and/or EncryptionUserPasswordSet.

Updating the HPE iLO license key

{
    "path": "/rest/v1/Managers/1/LicenseService",
    "body": {
        "LicenseKey": "license key"
    }
}

To update an iLO license key, use the rawpost command. For more information, see RawPost command.

The following is an example of the JSON to include when using the rawpost command.

To delete an iLO license, use the rawdelete command. For more information, see RawDelete command. The following is an example of the JSON to include when using the rawdelete command:

rawdelete /rest/v1/Managers/1/LicenseService

Deploying a Service Pack for ProLiant (SPP)

{
    "path": "/rest/v1/Managers/1/VirtualMedia/2",
    "body": {
        "Action": "InsertVirtualMedia",
        "Target": "/OEM/Hp",
        "Image": "http://xx.xxx.xxx.xxx:xx/spp.iso
    }
}

To deploy a SPP, use the rawpost command. For more information, see RawPost command.

ilorest -v --nologo rawpost virtualmedia.json --url=xx.xx.xx.xxx --user=Admin --password=password

The following is an example of the JSON to include when using the rawpost command.

Script Examples

Selecting and getting properties from a type.

:: selectget.bat [URI] [USERNAME] [PASSWORD] 
@echo off

set argC=0
for %%x in (%*) do Set /A argC+=1
if %argC% LSS 3 goto :failCondition
goto :main

:failCondition
@echo Usage:
@echo selectget.bat [URI] [USERNAME] [PASSWORD]
goto :EOF

:main
@echo *****************************************
@echo ************* Logging in... *************
@echo *****************************************
ilorest.exe login %1 -u %2 -p %3
@echo *****************************************
@echo ******* selecting Bios type... ********
@echo *****************************************
ilorest.exe select Bios.
@echo *****************************************
@echo ********** getting BootMode... **********
@echo *****************************************
ilorest.exe get 
pause

This is a batch file that logs into a remote server, selects the Bios type, and gets the BootMode value.

Saving and Loading a File Using File-Based Editing Mode

:: saveload.bat [SELECTOR] [FILENAME]
:: Specify a type with the SELECTOR tag, and
:: save to a file called FILENAME
@echo off
set argC=0
for %%x in (%*) do Set /A argC+=1
if %argC% LSS 2 goto :failCondition
goto :main

:failCondition
@echo Usage:
@echo saveload.bat [SELECTOR] [FILENAME]
@echo specify a type with the SELECTOR tag, and
@echo save to a file called FILENAME
goto :EOF

:main
ilorest.exe login
ilorest.exe save --selector=%1 --json -f %2
@echo Edit the file, then:
pause
ilorest.exe load -f %2

This is a file-based edit mode helper for RESTful Interface Tool.

  1. Run to download selected type to a file called ilorest.json.

  2. Edit the ilorest.json file to make changes.

  3. Press any key running batch program to continue with program, uploading the newly edited program to the server.

Change secureboot settings

@echo off

if "%1"=="True" goto passcondition
if "%1"=="False" goto passcondition
if "%1"=="true" goto passcondition
if "%1"=="false" goto passcondition
goto :failcondition

:passCondition
set argC=0
for %%x in (%*) do Set /A argC+=1

if %argC% == 0 goto :failcondition
if %argC% == 1 goto :local
if %argC% == 4 goto :remote
goto :failcondition

:failcondition
@echo Usage:
@echo Param 1: True or False
@echo.
@echo Remote Only Parameters:
@echo    (optional) Param 2: IP Address for ILO
@echo    (optional) Param 3: ILO Username
@echo    (optional) Param 4: ILO Password
goto :EOF

:local
@echo.
@echo *******************************************
@echo *********** Initiating script *************
@echo *******************************************
@echo.
ilorest.exe login
ilorest.exe set SecureBootEnable=%1 --selector HpSecureBoot. --commit
goto :finalcomment

:remote
@echo.
@echo *******************************************
@echo *********** Initiating script *************
@echo *******************************************
@echo.
ilorest.exe set SecureBootEnable=%1 --url %2 -u %3 -p %4 --selector HpSecureBoot. --commit

:finalcomment
@echo.
@echo ********************************************
@echo ********** Done applying changes ***********
@echo ********************************************

pause

This is a batch file that enables you to change the secure boot settings quickly.

Usage:

Support and other resources

Accessing Hewlett Packard Enterprise Support

http://www.hpe.com/assistance

http://www.hpe.com/support/hpesc

Information to collect

Accessing updates

Websites and documents

Tutorial Videos

Creating iLO REST Extensions

An Introduction to the RESTful Interface Tool

Benefits of RESTful Interface Tool vs. CONREP

Websites

Website Link
Hewlett Packard Enterprise Information Library www.hpe.com/info/enterprise/docs
Hewlett Packard Enterprise Support Center www.hpe.com/support/hpesc
Contact Hewlett Packard Enterprise Worldwide www.hpe.com/assistance
Subscription Service/Support Alerts www.hpe.com/support/e-updates
Software Depot www.hpe.com/support/softwaredepot
Customer Self Repair www.hpe.com/support/selfrepair
Insight Remote Support www.hpe.com/info/insightremotesupport/docs
Serviceguard Solutions for HP-UX www.hpe.com/info/hpux-serviceguard-docs
Single Point of Connectivity Knowledge (SPOCK) Storage compatibility matrix www.hpe.com/storage/spock
Storage white papers and analyst reports www.hpe.com/storage/whitepapers
iLO RESTful API www.hpe.com/info/restfulapi
HPE ProLiant Gen9 Server Management www.hpe.com/servers/proliantgen9/docs
HPE Intelligent Provisioning www.hpe.com/info/intelligentprovisioning/docs
UEFI System Utilities www.hpe.com/info/ProLiantUEFI/docs
SUM www.hpe.com/info/hpsum
Service Pack for ProLiant (SPP) www.hpe.com/servers/spp
HPE iLO 4 www.hpe.com/info/ilo/docs
HPE iLO University videos www.hpe.com/info/ilo/videos
HPE Systems Insight Manager www.hpe.com/info/hpsim
U.S. Authorized Resellers www.hpe.com/support/service_locator

Documents

Customer self-repair

Hewlett Packard Enterprise customer self repair (CSR) programs allow you to repair your product. If a CSR part needs to be replaced, it will be shipped directly to you so that you can install it at your convenience. Some parts do not qualify for CSR. Your Hewlett Packard Enterprise authorized service provider will determine whether a repair can be accomplished by CSR.

For more information about CSR, contact your local service provider or go to the CSR website.

www.hpe.com/support/selfrepair

Remote Support

Remote support is available with supported devices as part of your warranty or contractual support agreement. It provides intelligent event diagnosis, and automatic, secure submission of hardware event notifications to Hewlett Packard Enterprise, which will initiate a fast and accurate resolution based on your product’s service level. Hewlett Packard Enterprise strongly recommends that you register your device for remote support.

For more information and device support details, go to the following website.

www.hpe.com/info/insightremotesupport/docs

Documentation feedback

Hewlett Packard Enterprise is committed to providing documentation that meets your needs. To help us improve the documentation, send any errors, suggestions, or comments to Documentation Feedback, docsfeedback@hpe.com. When submitting your feedback, include the document title, part number, edition, and publication date located on the front cover of the document. For online help content, include the product name, product version, help edition, and publication date located on the legal notices page.

Error Codes

The RESTful Interface Tool uses the following error codes:

Error Code Description
1 Error occurred while reading the configuration file. See the error message for details.
2 Error occurred when user tried to invoke a command that isn’t enabled.
3 Invalid iLOrest command line syntax. Use the -h parameter for complete command line parameters.
4 The input JSON file is in an invalid format.
5 Windows User not admin.
6 No contents found for operation.
7 Invalid File input error.
8 No changes made or found.
9 No Valid info error.
10 Error occurred while parsing user command line inputs. See the error message for details.
11 Warning occurred during command line inputs parsing. See the error message for details.
12 Invalid individual command usage. Use the -h parameter for individual command line parameters.
13 Error occurred when user tries to invoke a command that doesn’t exist.
21 Occurs when there are no clients active (usually when user hasn’t logged in).
22 Error occurred when attempting to operate on another instance while logged in.
23 Error occurred when attempting to select an instance that does not exist.
24 Error occurred when attempting to access an object type without first selecting it.
25 Error occurred when attempting to access an object type without first selecting it while using filters.
26 Error occurred when attempting to set an object type without first selecting it.
27 Error occurred when selection argument fails to match anything.
28 Error occurred when validating user input against schema files.
29 RIS Missing ID token.
30 RIS session expired.
31 Error occurred when retry attempts to reach the selected server have been exhausted.
32 Occurs when invalid iLO credentials have been provided.
33 Error occurred when correct credentials have been provided and server is unresponsive.
34 CHIF driver missing.
35 CHIF missing DLL.
36 Error occurred due to an unexpected response.
37 Error occurred due to iLO error.
38 Error occurred while trying to create BLOB.
39 Error occurred while trying to read BLOB.
40 Same settings error.
41 Firmware update error.
42 Boot order entry error.
43 NIC missing or invalid error.
44 No current session established.
45 Failure during commit operation
51 Multiple server configuration failure
52 Multiple server input file error.
53 Load skip setting error.
54 Incompatible iLO version error.
55 Invalid command list file error.
56 Unable to mount BB error.
57 Birthcertificate parse error.
58 Incompatible server type.
59 iLO license error.
60 Account exists error.
61 Error occurred when trying to change a value.
62 Reference path not found error.
63 iLO response error.
64 Unable to open a channel with iLO error.
65 Error parsing schema. Try running with the “–latestschema flag”.
70 Error occurred while trying to write BLOB.
71 Error occurred while trying to delete BLOB.
72 Error occurred while trying to finalize BLOB.
73 BLOB could not be found.
74 JSON decoder error.
75 Security state error.
76 iLO RESTful API BLOB override error.
77 Error occurred during the blob operation after maximum retries.
80 Resource allocation errors.
81 Error occured during encryption.
82 The drive is missing.
83 The requested path is unavailable.
100 BIOS provider is unregistered. Please refer to the documentation for details on this issue.
101 Failed to download component.
102 Update service busy.
104 Error occured in the order of task queue items.
103 Failed to upload component.
255 A general error occurred while manipulating server settings. See the error message for details.