Queries the status of the CloudMonitor agent.

This topic describes how to query the status of the CloudMonitor agent that is installed on the i-hp3dunahluwajv6f**** instance. The result indicates that the CloudMonitor agent is in the running state.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

ParameterTypeRequiredExampleDescription
ActionStringYesDescribeMonitoringAgentStatuses

The operation that you want to perform. Set the value to DescribeMonitoringAgentStatuses.

InstanceIdsStringYesi-hp3dunahluwajv6f****

The instance ID. Separate multiple instance IDs with commas (,).

HostAvailabilityTaskIdStringNo126****

The ID of the availability monitoring task.

For more information about common request parameters, see Common parameters.

Response parameters

ParameterTypeExampleDescription
CodeString200

The status code.

Note The status code 200 indicates that the request was successful.
MessageStringThe specified resource is not found.

The error message.

RequestIdString6F8371DF-AB81-41B8-9E1B-5493B3FF0E4F

The request ID.

SuccessBooleantrue

Indicates whether the request was successful. Valid values:

  • true
  • false
NodeStatusListArray of NodeStatus

The host status information.

NodeStatus
StatusStringrunning

The status of the CloudMonitor agent. Valid values:

  • running: The CloudMonitor agent is running.
  • stopped: The CloudMonitor agent is stopped.
  • installing: The CloudMonitor agent is being installed.
  • install_faild: The CloudMonitor agent fails to be installed.
  • abnormal: The CloudMonitor agent is not properly installed.
  • not_installed: The CloudMonitor agent is not installed.
InstanceIdStringi-hp3dunahluwajv6f****

The instance ID.

AutoInstallBooleantrue

Indicates whether the CloudMonitor agent is automatically installed. Valid values:

  • true: The CloudMonitor agent is automatically installed.
  • false: The CloudMonitor agent is not automatically installed.
OsMonitorStatusStringrunning

The status of SysOM. Valid values:

  • installing: SysOM is being installed.
  • running: SysOM is running.
  • stopped: SysOM is stopped.
  • uninstalling: SysOM is being uninstalled.
OsMonitorErrorCodeStringinstall_fail

The error status of SysOM. Valid values:

  • install_fail: SysOM fails to be installed or an unknown error occurs.
  • install_assist_invalid: SysOM fails to be installed because the status of Cloud Assistant is invalid.
  • install_assist_command_fail: SysOM fails to be installed because the installation command fails to run.
  • uninstall_fail: SysOM fails to be uninstalled or an unknown error occurs.
  • uninstall_assist_invalid: SysOM fails to be uninstalled because the status of Cloud Assistant is invalid.
  • uninstall_assist_command_fail: SysOM fails to be uninstalled because the uninstallation command fails to run.
OsMonitorErrorDetailStringCommand.ErrorCode.Fail.Downlaod.REGIN_ID

The details of the execution error. Valid values:

  • Command.ErrorCode.Fail.Downlaod.REGIN_ID: Failed to obtain the region ID.
  • Command.ErrorCode.Fail.Downlaod.SYSAK: Failed to download the .rpm package of System Analyse Kit (SysAK).
  • Command.ErrorCode.Fail.Downlaod.CMON_FILE: Failed to download the CMON file.
  • Command.ErrorCode.Fail.Downlaod.BTF: Failed to start SysAK because the BTF file is not found.
  • Command.ErrorCode.Fail.Start.SYSAK: Failed to start SysAK due to an unknown error.
OsMonitorVersionString1.3.0-12

The SysOM version.

Examples

Sample requests

http(s)://[Endpoint]/?Action=DescribeMonitoringAgentStatuses
&InstanceIds=i-hp3dunahluwajv6f****
&<Common request parameters>

Sample success responses

XML format

HTTP/1.1 200 OK
Content-Type:application/xml

<DescribeMonitoringAgentStatusesResponse>
    <RequestId>6F8371DF-AB81-41B8-9E1B-5493B3FF0E4F</RequestId>
    <NodeStatusList>
        <NodeStatus>
            <Status>running</Status>
            <AutoInstall>true</AutoInstall>
            <InstanceId>i-hp3dunahluwajv6f****</InstanceId>
        </NodeStatus>
    </NodeStatusList>
    <Code>200</Code>
    <Success>true</Success>
</DescribeMonitoringAgentStatusesResponse>

JSON format

HTTP/1.1 200 OK
Content-Type:application/json

{
  "RequestId" : "6F8371DF-AB81-41B8-9E1B-5493B3FF0E4F",
  "NodeStatusList" : {
    "NodeStatus" : [ {
      "Status" : "running",
      "AutoInstall" : true,
      "InstanceId" : "i-hp3dunahluwajv6f****"
    } ]
  },
  "Code" : 200,
  "Success" : true
}

Error codes

HTTP status codeError codeError messageDescription
404ResourceNotFoundThe specified resource is not found.The error message returned because the specified resource is not found.

For a list of error codes, see Service error codes.