Invalid argument client error when doing COS operations

You might encounter issues while performing IBM Cloud Object Storage operations.

Problem

While performing Cloud Object Storage operations, you might see the following Invalid argument error when calling the ListBuckets operation error.

ibm_botocore.exceptions.ClientError: An error occurred (InvalidArgument) when calling the ListBuckets operation: Invalid Argument

Resolution

Verify that the correct cos_resource_crn is set for the Cloud Object Storage in PowerVC. The cos_resource_crn value must be the resource_instance_id value from the IBM Cloud Object Storage Service credentials and not the iam_service_crn value. To update this value, the service credentials for the Cloud Object Storage can be updated from PowerVC.