> For the complete documentation index, see [llms.txt](https://cortex-docs.paloaltonetworks.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://cortex-docs.paloaltonetworks.com/cortex-xdr/configure-cortex-xdr/cortex-xdr-data-sources/cloud-service-provider-csp-onboarding/ibm-cloud-cloud-onboarding/ibm-cloud-post-deployment-verification.md).

# IBM Cloud post-deployment verification

After you deploy the Terraform authentication template and manually connect the IBM Cloud cloud instance, verify that onboarding succeeded.

After you deploy the Terraform authentication template and manually connect the cloud instance, verify that onboarding succeeded.

## Verify the cloud instance

In Cortex XDR, select **Settings → Data Sources & Integrations** and open the **IBM Cloud** cloud instances. Verify the following:

* The cloud instance status is Connected. If the instance is still Pending, you haven't completed the manual connection. See [Deploy the Terraform authentication template in IBM Cloud](https://cortex-docs.paloaltonetworks.com/cortex-xdr/configure-cortex-xdr/cortex-xdr-data-sources/cloud-service-provider-csp-onboarding/ibm-cloud-cloud-onboarding/deploy-the-terraform-authentication-template-in-ibm-cloud.md).
* The permissions status of the cloud instance doesn't show errors.
* The discovery scan starts automatically.
* Assets from your IBM Cloud account appear in **Asset Inventory** as discovery progresses.

## Verify the resources in IBM Cloud

In the IBM Cloud console, verify that the Terraform template created the expected resources:

* Under **Manage → Access (IAM) → Service IDs**, the service ID `cortex-<suffix>-service-id` exists and has the `managed_by:paloaltonetworks` tag.
* On the service ID's **Access** tab, the access policies list the Viewer and Reader roles and the Cortex XDR custom roles.
* On the service ID's **API keys** tab, the API key `cortex-<suffix>-api-key` exists.

## Troubleshooting IBM Cloud onboarding

Use the following table to resolve common IBM Cloud onboarding issues.

| Issue                                                                      | Cause and resolution                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             |
| -------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| The cloud instance stays in Pending status.                                | <p>The cloud instance wasn't manually connected. IBM Cloud doesn't connect the instance automatically after you run the template.<br><br>Retrieve the Terraform outputs and <a href="https://cortex-docs.paloaltonetworks.com/cortex-xdr/configure-cortex-xdr/cortex-xdr-data-sources/cloud-service-provider-csp-onboarding/ibm-cloud-cloud-onboarding/deploy-the-terraform-authentication-template-in-ibm-cloud.md#manually-connect-the-cloud-instance">manually connect the cloud instance</a>.</p>                                                                                                                            |
| `terraform apply` fails with an authentication error.                      | <p>The <code>IC\_API\_KEY</code> environment variable isn't set, or the API key isn't valid.<br><br>Set <code>IC\_API\_KEY</code> to a valid IBM Cloud administrator API key in the same terminal session, and run <code>terraform apply</code> again.</p>                                                                                                                                                                                                                                                                                                                                                                       |
| `terraform apply` fails when it creates the tag on the service ID.         | <p>The administrator API key doesn't have the <code>global-search-tagging.tag.attach-user-tag</code> permission.<br><br>Assign the Administrator or Editor platform role to the user who owns the API key, or remove the custom tags and run <code>terraform apply</code> again.</p>                                                                                                                                                                                                                                                                                                                                             |
| `terraform apply` fails when it creates a custom role or an access policy. | <p>The user who runs the template doesn't have the required IAM access, or a custom role with the same name already exists.<br><br>Verify that you have the access described in <a href="https://cortex-docs.paloaltonetworks.com/cortex-xdr/configure-cortex-xdr/cortex-xdr-data-sources/cloud-service-provider-csp-onboarding/ibm-cloud-cloud-onboarding/prerequisites-for-onboarding-ibm-cloud.md">Prerequisites for onboarding IBM Cloud</a>. If the role name already exists, it's from an earlier onboarding attempt of the same template. Remove the earlier resources, or run Terraform from the original directory.</p> |
| The **Connect Instance** form rejects the values.                          | <p>One of the values was copied incorrectly, or it belongs to a different run of the template.<br><br>Run <code>terraform output</code> again in the same directory, and copy the values without extra spaces or quotation marks.</p>                                                                                                                                                                                                                                                                                                                                                                                            |
| The `account_id` output isn't the account you want to onboard.             | <p>The administrator API key in <code>IC\_API\_KEY</code> belongs to a different IBM Cloud account. Terraform creates the resources in the account of the key.<br><br>Don't connect the cloud instance. Run <code>terraform destroy --var-file=template\_params.tfvars</code>, set <code>IC\_API\_KEY</code> to an administrator API key from the correct account, and run the template again.</p>                                                                                                                                                                                                                               |
| The cloud instance shows a permissions error after it was connected.       | <p>The service ID API key was deleted or disabled in IBM Cloud, or an access policy was removed. Cortex XDR can't exchange the API key for an access token.<br><br>If the API key was deleted, <a href="https://cortex-docs.paloaltonetworks.com/cortex-xdr/configure-cortex-xdr/cortex-xdr-data-sources/cloud-service-provider-csp-onboarding/ibm-cloud-cloud-onboarding/rotate-the-ibm-cloud-api-key.md">rotate the API key</a> to create a new one. If an access policy was removed, run <code>terraform apply</code> again from the original directory to restore it.</p>                                                    |

For more troubleshooting information, see [Troubleshoot errors on cloud instances](https://cortex-docs.paloaltonetworks.com/cortex-xdr/configure-cortex-xdr/cortex-xdr-data-sources/cloud-service-provider-csp-onboarding/troubleshoot-errors-on-cloud-instances.md).


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://cortex-docs.paloaltonetworks.com/cortex-xdr/configure-cortex-xdr/cortex-xdr-data-sources/cloud-service-provider-csp-onboarding/ibm-cloud-cloud-onboarding/ibm-cloud-post-deployment-verification.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
