Deleting an object from a cloud storage bucket.

0 votes
How do I delete an object from the cloud storage bucket?
Oct 24 in GCP by anonymous
• 6,650 points
20 views

1 answer to this question.

0 votes

Use the gsutil rm command:

gsutil rm gs://[BUCKET_NAME]/[OBJECT_NAME]

Where:

  • [BUCKET_NAME] is the name of the bucket containing the object you want to delete. For example, my-bucket.

  • [OBJECT_NAME] is the name of the object you want to delete. For example, pets/dog.png.

If successful, the response looks like the following example:

Operation completed over 1 objects.
answered Oct 24 by Sirajul
• 40,980 points

Related Questions In GCP

0 votes
1 answer
0 votes
1 answer
0 votes
1 answer

GCP Error: 403: Access Denied

Check that your credentials are correct. For ...READ MORE

answered Oct 9 in GCP by Sirajul
• 40,980 points
30 views
0 votes
1 answer

Permissions issue with Google Cloud Storage Bucket.

You can regain access to the object by assigning an applicable role, like roles/storage.objectAdmin, to ...READ MORE

answered Oct 10 in GCP by Sirajul
• 40,980 points
87 views
0 votes
1 answer