How To
Summary
Manage v8.1 introduced a new way to access familiar CLI tools by using the Tools API. This document discusses how to execute the tools and gather logs from the Manage Pods.
Environment
Maximo Manage 8.1 and newer.
Steps
Manage v8.1 now contains a web module deployment and extends the REST API framework to provide access to CLI tools.
To access, the Tools API, API keys are required for authentication.
The Tools API was released with Manage 8.1 onwards.
The Tools API is independent of the Maximo pods, and runs in the maxinst pod.
The application and signature option are authorized with the API Route object structure definition.
Users can stream logs once the name is known
The tools API was created to facilitate a simple way for clients to access CLI tools from outside of the Red Hat OpenShift cluster.
- icheckerreport – Run Integrity Checker in “report” mode
- icheckerrepair – Run Integrity Checker in “repair” mode
- toolslog - Get a specified tools log or get a list of all tools logs
- managestart - Start all Maximo Manage pods
- managestop – Stop all Maximo Manage pods
- submitUploadLogRequest - Upload logs from Maximo Manage UI, Cron, MEA, or Report pods to S3 Cloud Object Storage
- (Note: this tool runs against the Manage Liberty pods, where the Manage application runs, to collect and upload logs to Cloud Object Storage, unlike CLI tools that run against the MAXINST pod)
Setting up the Environment
There are three things to do before executing commands.
Set up S3 Cloud Object Storage and configure Maximo properties (used to submit upload log requests for Manage Liberty pod logs). See the link for more information:
https://www.ibm.com/docs/en/mas-cd/maximo-manage/continuous-delivery?topic=documents-sending-log-output-s3-cloud-object-storage
Configure access to the signature option:
- In the Security Groups application, search for your security group
- On the applications tab, search for the Logging application
- Grant access to the "Load log files to object store" signature option
- Save the changes and log out and in again to apply the changes
Generate an API key
In Manage 8.4 and newer versions:
- Navigate to Integration -> API Keys.
- Click "Add API Key"
- Search for the user, and click "Create"
For Manage 8.3 and earlier versions:
- Navigate to the Administration -> Administration work center
- Click the link "API Keys"
- Click "Add API Key"
- Search for the user, and click "Add"
- Copy the API key
This key will be used in the next steps.
Setting up a rest client:
- In the example shown, Postman was used as the REST client.
- Create new HTTP request
- Add a header called "apikey". Past the copied key into the value field
Executing CLI tools sending requests to the maxinst pod:
POST https://host:port/toolsapi/toolservice/icheckerreport - Generate an integrity checker log.
GET https://host:port/toolsapi/toolservice/toolslog?logfile=<name of report from icheckerreport request>
GET https://host:port/toolsapi/toolservice/toolslog - Get a list of all tools logs.
POST https://host:port/toolsapi/toolservice/icheckerrepair - Execute the integrity checker utility.
POST https://host:port/toolsapi/toolservice/managestop - Stop the Maximo Manage pods.
POST https://host:port/toolsapi/toolservice/managestart - Start the Maximo Manage pods.
Executing Logging service commands sending request to the Manage pod:
POST https://host:port/maximo/api/service/logging?action=wsmethod:submitUploadLogRequest - Upload logs from Maximo Manage pods to S3 Cloud Object Storage.
GET https://host:port/maximo/api/service/logging?action=wsmethod:streamLog - Stream the application log to the browser
Executing the integrity checker CLI
Executing Integrity Checker to write a report to logs
The URL for any of the toolsapi requests requires the url to your maxinst pod. For this report, use the POST method.
POST https://host:port/toolsapi/toolservice/icheckerreport
The body of the request is blank.
The response is shown in this screen capture:
Getting lists of tools logs
GET https://host:port/toolsapi/toolservice/toolslog Get a list of all tools logs.
A list of available logs is shown in the screen capture:
Streaming tools logs
To stream a particular log file output, add the logfile parameter along with the file name as shown:
GET https://host:port/toolsapi/toolservice/toolslog?logfile=ichecker_report1637953395961.log
Stopping and starting Manage
Executing managestop
You stop the manage pods by using the Tools API against the MAXINST pod URL:
POST https://host:port/toolsapi/toolservice/managestop
Executing managestart
POST https://host:port/toolsapi/toolservice/managestart
Submit Upload Log Request to Cloud Object Storage
Submitting upload log requests is executed on Manage pods. Upon executing this command, all logs from all Manage Liberty pods (cron, UI, MIF, RPT) are collected, compressed, and automatically uploaded to Cloud Object Storage. This allows administrators to access the logs without the need for access to the Red Hat OpenShift console.
POST https://host:port/maximo/api/service/logging?action=wsmethod:submitUploadLogRequest
Navigate to your Cloud Object Storage bucket to see the log returned in the output:
If required, the file can be downloaded and uploaded to IBM Support.
Swagger:
You can find the swagger documentation using the url shown. The swagger is available on the maxinst pod:
https://host:port/toolsapi/oas3/api.html
For additional information contact IBM Support.
Document Location
Worldwide
[{"Type":"MASTER","Line of Business":{"code":"LOB59","label":"Sustainability Software"},"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Product":{"code":"SSRHPA","label":"IBM Maximo Application Suite"},"ARM Category":[{"code":"a8m50000000CbP6AAK","label":"System Administration"}],"ARM Case Number":"","Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"8.5.0;and future releases"}]
Was this topic helpful?
Document Information
Modified date:
01 February 2024
UID
ibm16519816