Deleting an object from a cloud storage bucket

0 votes
How do I delete an object from the cloud storage bucket?
Oct 25, 2019 in GCP by anonymous
• 19,610 points
1,958 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.


Hope this helps!!

If you need to know more about Google Cloud, It's recommended to go for Google Cloud architect certification course.

Thanks!

answered Oct 25, 2019 by Sirajul
• 59,230 points

Related Questions In GCP

0 votes
1 answer

Delete a cloud storage object that is in the locked, retention-enabled bucket.

No, you can't delete a cloud storage object ...READ MORE

answered Nov 18, 2019 in GCP by Sirajul
• 59,230 points

edited Sep 21, 2021 by Sarfaraz 3,295 views
0 votes
1 answer

Mounting a Google cloud storage bucket to a GKE pod as a persistent disk.

Yes, its possible. There's a similar project,follow ...READ MORE

answered Oct 16, 2019 in GCP by Sirajul
• 59,230 points
9,904 views
0 votes
1 answer

GCP Error: 403: Access Denied

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

answered Oct 9, 2019 in GCP by Sirajul
• 59,230 points
3,984 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, 2019 in GCP by Sirajul
• 59,230 points
4,916 views
0 votes
1 answer
0 votes
1 answer

uploading an object into the cloud storage bucket.

Suppose you want to upload an image ...READ MORE

answered Oct 24, 2019 in GCP by Sirajul
• 59,230 points
1,559 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP