Billing in GCD: finding the sku ID in the vm instance

Viewed 1039

I have checked the billing in GCD and i just find as reference service ID and a sku ID. I can't even click on the sku ID. Is there a more "direct" way to get to the product i used, if it's still running? I know there is a billing api for this, but this does not direct me to the actual product.

If there is no link in the billing report, where can i see the skuID in my for example VM instance?

1 Answers

You can try to use labels to break down your billing charges per resources (per VM instance for example). Have a look at the documentation Creating and managing labels:

A label is a key-value pair that helps you organize your Google Cloud instances. You can attach a label to each resource, then filter the resources based on their labels. Information about labels is forwarded to the billing system, so you can break down your billing charges by label.

You can create labels by using Resource Manager API, Cloud Console or gcloud command. For GCE resources you should follow the documentation Labeling resources, for example:

$ gcloud compute instances create example-instance --image-family=rhel-8 --image-project=rhel-cloud --zone=us-central1-a --labels=k0=value1,k1=value2
$ gcloud compute instances add-labels example-instance --labels=k0=value1,k1=value2
$ gcloud compute instances update example-instance --zone=us-central1-a --update-labels=k0=value1,k1=value2 --remove-labels=k3
$ gcloud compute instances remove-labels example-instance --labels=k0,k1

In addition, have a look at the documentation View your billing reports and cost trends and Export Cloud Billing data to BigQuery.

Related