Kubernetes pods in completed or error state

Symptom

Kubernetes pods are in completed or error state.

Action

To recover the disk space, clean up the Kubernetes pods.

  1. Log in to the NPS toolkit VM as root user.
  2. Export the environment variables:
    export API_IP=<NPS Toolkit VM OAM/Customer Network IP address>
    export NPSADMIN=<user name of admin mentioned in the nps_secret.yaml file>
    export NPSPASSWD=<password of admin user mentioned in the nps_secret.yaml file>
    export TOPOLOGY_NAME=<value of the field "topology_name" in the input.json file>
    export VIM_TYPE=<VIM platform type like RHOCP/RHOCP/VMWARE>
  3. Clean up the Kubernetes pods using the following command:
    nps cleanup -c pods