Skip to content

Commit b958cc6

Browse files
authored
Merge pull request #2378 from hpe-dev-incubator/cms/blog/how-to-change-the-factory-generated-ilo-administrator-password
Update Blog “how-to-change-the-factory-generated-ilo-administrator-password”
2 parents b028e7f + d311825 commit b958cc6

File tree

3 files changed

+33
-22
lines changed

3 files changed

+33
-22
lines changed
Lines changed: 33 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,53 +1,64 @@
11
---
2-
title: "How to change the factory generated iLO Administrator password"
2+
title: How to change the factory generated iLO Administrator password
33
date: 2018-03-29T15:34:24.958Z
4-
author: François Donzé
5-
tags: ["iLO","Redfish","ilorest"]
6-
authorimage: "/img/blogs/Avatar6.svg"
74
featuredBlog: false
8-
priority:
9-
thumbnailimage:
5+
priority: null
6+
author: François Donzé
7+
authorimage: /img/fdz-photoprofile.png
8+
thumbnailimage: null
9+
tags:
10+
- iLO
11+
- Redfish
12+
- ilorest
13+
- ilo-restful-api
1014
---
11-
# Boosting your server deployment: How to change the factory generated iLO administrator password
15+
<style> li { font-size: 27px; line-height: 33px; max-width: none; } </style>
1216

17+
Updated March 6, 2024
1318

1419
You receive a bunch of brand new rack-mount ProLiant servers and want to get them up and running as soon as possible. Ansible, Chef, Puppet, Ironic, Python, PowerShell are your friends but, before being able to use those powerful and flexible tools to fully deploy the servers, you need one little thing: An access to the iLO to configure low level system parameters (i.e. iLO network, BIOS, storage…).
1520

16-
This blog proposes a simple, quick and modern method to modify the factory randomly generated Administrator iLO password without knowing it. It can be used on one or several thousands of rack-mount ProLiant servers starting at Gen9 models. This problem does not exist for blades or Synergy compute modules because their embedded management modules (respectively OA and Composer) have the ability to perform those tasks without any credentials.
21+
This blog post proposes a simple, quick and modern method to modify the factory randomly generated Administrator iLO password without knowing it. It can be used on one or several thousands of rack-mount ProLiant servers starting at Gen9 models. This problem does not exist for blades or Synergy compute modules because their embedded management modules (respectively OA and Composer) have the ability to perform those tasks without any credentials.
1722

18-
## In-band management with `ilorest` does the trick
23+
## In-band management with HPE iLOrest does the trick
1924

20-
HPE rack-mount servers, unless they have been customized by the [HPE Factory Express integration service](https://www.hpe.com/us/en/services/factory-express.html) comes with a randomly generated factory password visible on a physical paper/plastic tag located somewhere on the front side of the servers. To speed-up the collection of the passwords it is possible to scan and export them in a .csv formatted file, using a smartphone bar-code application. However, this method has its limits when it comes to processing several hundreds or thousands of servers.
25+
HPE rack-mount servers, unless they have been customized by the <a href="https://www.hpe.com/us/en/services/factory-express.html" target="_blank">HPE Factory Express integration service</a> comes with a randomly generated factory password visible on a physical paper/plastic tag located somewhere on the front side of the servers. To speed-up the collection of the passwords it is possible to scan and export them in a `.csv` formatted file, using a smartphone bar-code application. However, this method has its limits when it comes to processing several hundreds or thousands of servers.
2126

22-
Instead, I will use an in-band management access method with the [ilorest(8)](http://www.hpe.com/info/resttool) tool. This [RESTful Interface tool](http://www.hpe.com/info/resttool) can talk to iLO 4/5 either from remote (out-of-band) or from the Operating System (Linux or Windows) running on the server itself (In-band management).
27+
Instead, I will use an in-band management access method with the <a href="https://github.com/HewlettPackard/python-redfish-utility/releases/latest" target="_blank">HPE iLOrest</a> tool. This RESTful Interface tool can talk to iLO 4/5/6 either from remote (out-of-band) or from the Operating System (Linux or Windows) running on the server itself (In-band management).
2328

24-
To set the iLO 4/5 Administrator password, when logged in to the OS as a privileged user (root or Administrator), I just need to create a text file (i.e. `MyPassword.txt`) with the following content:
29+
> **NOTE**: The method presented below works only if the iLO security state is `Production`. In higher security states, it is required to supply credentials. Use the following command to retrieve the `SecurityState` property of an iLO:
30+
>
31+
> `ilorest get SecurityState --select HpeSecurityService. --url <ilo-ip> --user <ilo-user> --password password --logout`
2532
33+
To set the iLO Administrator password, when logged in to the OS as a privileged user (root or Administrator), I just need to create a text file (i.e. `MyPassword.txt`) with the following content:
2634

27-
~~~
35+
```
2836
{
2937
"path": "/redfish/v1/AccountService/Accounts/1/",
3038
"body": {
3139
"Password": "MyPassword"
3240
}
3341
}
34-
~~~
42+
```
3543

36-
Then, using the `ilorest` tool, I connect to the iLO via an internal path (no credential required here) and send the password request modification:
44+
Then, using the HPE iLOrest tool, I connect to the iLO via the <a href="https://developer.hpe.com/blog/chif-driver-not-found/" target="_blank">Channel Interface</a> (CHIF). Again, when logged as a privileged user, when the iLO is in `Production` security state, you don't need to supply any credential, and you can send the password request modification:
3745

38-
![Changing the iLO factory generated Administrator password with ilorest](https://redfish-lab.sourceforge.io/media/redfish-wiki/how-to-change-factory-generated-password/1-change-password-with-ilorest.png)
46+
![Changing the iLO factory generated Administrator password with iLOrest](/img/1-change-password-with-ilorest.png "Changing the iLO factory generated Administrator password with iLOrest")
3947

40-
# Data model clean crawling
48+
## Data model clean crawling
4149

4250
But are you sure you changed the Administrator password and not another password account? What if the Administrator account is not located at position “1” in this collection of object?
4351

44-
`ilorest` can help you isolate the exact location of the Administrator account. The following command returns in JSON format what you need:
52+
HPE iLOrest can help you isolate the exact location of the Administrator account. The following command returns in JSON format what you need:
4553

46-
![List iLO user account 1 with ilorest](https://redfish-lab.sourceforge.io/media/redfish-wiki/how-to-change-factory-generated-password/2-ilorest-list-manager-account.png)
54+
![Retrieve URI of iLO user account 1 with iLOrest](/img/2-ilorest-list-manager-account.png "Retrieve URI of iLO user account 1 with iLOrest")
4755

4856
With a simple parsing of the output of this command, you can create an error prone script to change the desired password.
4957

50-
Should you need to perform more complex digging to retrieve objects from this data model, the [Managing HP Servers Using the HP RESTful API](http://h20564.www2.hpe.com/hpsc/doc/public/display?docId=c04423967) manual explains very well with pseudo code examples how to crawl the data model without making bad assumptions.
58+
Should you need to perform more complex digging to retrieve objects from this data model, the <a href="https://servermanagementportal.ext.hpe.com/docs/redfishclients/ilorest-userguide/" target="_blank">HPE iLOrest user guide</a> contains a lot of useful examples.
5159

52-
# Building the complete solution
53-
Using this in-band management feature you can easily foresee an entire solution starting with a PXE boot of the servers on a minimal WinPE or PE-Linux operating system containing the `ilorest(8)` tool and an automatic trigger of a script performing the iLO password change and other tasks if desired.
60+
## Building the complete solution
61+
62+
Using this in-band management feature you can easily foresee an entire solution starting with a PXE boot of the servers on a minimal WinPE or PE-Linux operating system containing the iLOrest tool and an automatic trigger of a script performing the iLO password change and other tasks if desired.
63+
64+
Don't forget to check out some of my other <a href="https://developer.hpe.com/search/?term=donze" target="_blank">blog posts</a> on the HPE Developer portal to learn more about Redfish tips and tricks.
19.7 KB
Loading
9.81 KB
Loading

0 commit comments

Comments
 (0)