Removing an instance
You can remove an IBM Cloud Logs instance by using the IBM Cloud UI, by using the command line, or by using a Terraform script.
Before you remove your instance
Before you remove an IBM Cloud Logs instance from the IBM Cloud, clean up resources associated with the instance:
-
Make note of the sources that forwarded logs to the IBM Cloud Logs instance that you removed and, if appropriate, remove the logging agent from each source.
-
Remove permissions that are granted to users to work with the instane being deleted.
If you manage access by using dedicated access groups to work with a specific instance, you must remove these access groups.
If you manage access to multiple logging instances by using access groups, you must remove the policies that grant permissions to the instance you are deleting.
If you grant individual policies to users, you must gather the list of users that had permissions to work with the deleted instance. Then, for each user, you must remove the policies that relate to the instance that you are deleting.
Removing an instance through the IBM Cloud UI
To remove an instance of IBM Cloud Logs by using the IBM Cloud UI, complete the following steps:
-
Log in to your IBM Cloud account.
After you log in, the IBM Cloud UI opens.
-
Go to the menu icon > Observability to access the Observability Dashboard.
-
Click Logging. The list of logging instances is displayed. You might need to click the Cloud Logs tab to see your IBM Cloud Logs instances.
-
Click the Actions icon next to the instance that you want to delete.
-
Type the name of instance to confirm.
-
Click Delete.
Removing an instance through the CLI
To remove an instance of IBM Cloud Logs through the command line, complete the following steps:
-
[Pre-requisite] Install the IBM Cloud CLI.
For more information, see Installing the IBM Cloud CLI.
-
Log in to IBM Cloud. Run the following command: ibmcloud login
-
Get information about the instance that you plan to delete.
ibmcloud resource service-instance INSTANCE-NAME --output JSON
-
Remove any service key associated with the instance.
Find the service keys that are associated with an instance:
ibmcloud resource service-keys --instance-id INSTANCE-GUID
Run the following command to delete 1 service key. You must delete all keys associated with the instance to be deleted.
ibmcloud resource service-key-delete SERVICE-KEY-NAME
-
Remove the instance. Run the ibmcloud resource service-instance-delete command:
ibmcloud resource service-instance-delete NAME
Where NAME is the name of the instance.
For example, to remove the
logging-instance-01
instance, run the following command:ibmcloud resource service-instance-delete logging-instance-01
Removing an instance using Terraform
See Setting up Terraform for information on removing instances using Terraform.