All Products
Search
Document Center

Application Real-Time Monitoring Service:What do I do if the error message "rendered manifests contain a resource that already exists" appears?

Last Updated:Jul 23, 2024

Issue

When you uninstall and reinstall the Prometheus agent, the following error message appears:

rendered manifests contain a resource that already exists. Unable to continue with install: existing resource conflict: kind: ClusterRole, namespace: , name: arms-pilot-prom-k8s

image..png

Cause

After you run commands to manually uninstall the Prometheus agent, resources such as roles may fail to be deleted.

Solution

To resolve the issue, perform the following steps:

  1. Run the following command to find the ClusterRoles of the Prometheus agent:

    kubectl get ClusterRoles --all-namespaces | grep prom

  2. Run the following command to delete the ClusterRoles that are queried in the previous step:

     kubectl delete ClusterRole [$Cluster_Roles] -n arms-prom
    Note

    The [$Cluster_Roles] parameter specifies the ClusterRoles that are queried in the previous step.

  3. If the issue persists after you delete the ClusterRoles, view the value of kind in the error message to check whether resources other than ClusterRoles exist. Perform the preceding operations to delete them in sequence.

Applicable scope

  • Application Real-Time Monitoring Service (ARMS)

  • Managed Service for Prometheus