All Products
Search
Document Center

Application Real-Time Monitoring Service:Why is monitoring data not displayed after an ARMS agent is installed for a Java application in an ACK cluster?

最終更新日:Sep 03, 2024

Causes

  1. Application monitoring is suspended.

  2. The ARMS agent is not loaded as expected at the pod where the application resides.

Solution

Step 1: Check whether application monitoring is suspended

  1. Log on to the ARMS console. In the left-side navigation pane, choose Application Monitoring > Application List.

  2. On the Application List page, select a region in the top navigation bar and click the name of the application.

    If the application is not found, proceed to Step 2: Check whether the ARMS agent is loaded as expected.

  3. If you are using the new Application Real-Time Monitoring Service (ARMS) console, choose Configuration > Custom Configurations in the top navigation bar of the application details page. In the Probe switch settings section, check whether application monitoring is suspended.

  4. If you are using the old ARMS console, click Application Settings in the left-side navigation pane of the application details page. On the page that appears, click the Custom Configuration tab. In the Agent Switch Settings section, check whether Probe Master Switch is turned on.

Step 2: Check whether the ARMS agent is loaded as expected

  1. Log on to the ACK console. In the left-side navigation pane, click Clusters. On the Clusters page, click the name of the cluster to go to the cluster details page.

  2. In the left-side navigation pane, choose Workloads > Pods.

  3. On the Pods page, select the namespace in which your application resides, find the application, and then click Edit in the Actions column.

  4. In the Edit YAML dialog box, check whether the YAML file contains initContainers.

    db_am_ack_apppod_yaml

    • If the YAML file does not contain initContainers, the pod has not been injected into one-pilot-initcontainer. Perform Step 5.

    • If the YAML file contains initContainers, the pod has been injected into one-pilot-initcontainer. Perform Step 8.

  5. In the left-side navigation pane of the cluster details page, choose Workloads > Pods. On the page that appears, set the Namespace parameter to ack-onepilot. Check whether a pod whose name is prefixed with ack-onepilot exists in the pod list.

  6. In the left-side navigation pane of the cluster details page, choose Workloads > Deployments or StatefulSets. On the page that appears, find the application and choose More > View in YAML in the Actions column. In the Edit YAML dialog box, check whether the YAML file contains the following labels in the spec.template.metadata section:

    labels:
      armsPilotAutoEnable: "on"
      armsPilotCreateAppName: "<your-deployment-name>"    # Replace <your-deployment-name> with the actual application name. 
      armsSecAutoEnable: "on"    # If you want to connect the application to Application Security, you must configure this parameter.
    • If the YAML file contains the labels, perform Step 7.

    • If the YAML file does not contain the labels, perform the following operations: In the Edit YAML dialog box, add the labels to the spec > template > metadata section and replace <your-deployment-name> with the actual application name. Then, click Update.

  7. In the left-side navigation pane of the cluster details page, choose Workloads > Pods. On the page that appears, find the pod and click Logs in the Actions column to check whether the pod logs of ack-onepilot report a Security Token Service (STS) error in the "Message":"STS error" format.

  8. In the left-side navigation pane of the cluster details page, choose Workloads > Pods, find the pod and click Edit in the Actions column. In the Edit YAML dialog box, check whether the YAML file contains the following javaagent parameter:

    -javaagent:/home/admin/.opt/ArmsAgent/aliyun-java-agent.jar
    Note

    If you use an ARMS agent earlier than 2.7.3.5, replace aliyun-java-agent.jar in the preceding code with arms-bootstrap-1.7.0-SNAPSHOT.jar. We recommend that you upgrade the agent to the latest version at the earliest opportunity.

    • If the YAML file contains the parameter, find the pod on the Pods page and click Terminal in the Actions column to go to the command line page. Run the following command to check whether the logs file contains a log file with the .log file extension. Then, submit a ticket.

      cd /home/admin/.opt/ArmsAgent/logs
    • If the YAML file does not contain the parameter, submit a ticket.

References

Network configurations required by the ARMS agent for Java