Data Transfer in GCS Buckets


Transferring data across the GCS Buckets


There are multiple ways of dealing with the data transfer in and out of the bucket. Please go through the previous post for getting the background of Google cloud storage buckets and its concepts. 

Uploading files through the web console


Select the specific bucket and click on the upload file option.

Select the desired file/files and upload them.





Uploading files through command-line


Copying the file to the bucket


gsutil cp README-cloudshell.txt gs://datacloudies-bucket1/


Listing the files from GCS bucket


gsutil ls -l gs://datacloudies-bucket1/


Copying/Moving data from one bucket to another using web console


Go to the bucket and select the particular file, select option to copy/move the file


Select the permissions accordingly, select the destination bucket  and copy the file






Copying files from one bucket to another through command-line 


Sometimes, if you have a different class in the destination bucket, it only allows through the command line. 


gsutil cp -p gs://"datacloudies-bucket1/Copy of e41959-rac.pdf" gs://"datacloudies-bkt-gsutil/Copy of Copy of e41959-rac.pdf"


Verify the copied file in the target bucket.


Below command for moving the file between the buckets. 

gsutil mv -p gs://"datacloudies-bucket1/Copy of e41959-rac.pdf" gs://"datacloudies-bkt-gsutil/Copy of Copy of e41959-rac.pdf"

-p denotes to keep the previous permissions of the files. 





To summarize this, we have successfully completed the data transfer operations across various scenarios, like one bucket to another bucket, copy/move from on-premise to cloud GCS using web console and command-line utility. Thank you for reading it. Please do follow the next posts for learning more GCS topics. 





Recent Posts

  • Cloud SQL
    What is Cloud SQL  It is a fully managed relational database service for PostgreSQL and MySQL database in the GCP. MySQL instance can be...
    May 17 2020 | Read more
  • Deploy an application to Google Kubernetes Engine
    Welcome back, this is the continuation post of the previous article, where we have discussed the Kubernetes and its concepts in detail. In this...
    May 13 2020 | Read more
  • Google Kubernetes Engine
    What is GKE? GKE is a managed, production-ready environment for deploying containerized applications. It is like a managed cargo container in...
    May 13 2020 | Read more
  • Google App Engine – Flexible
    In the previous article, we have discussed what is google app engine and how to deploy the application in the Google app engine – Standard. In...
    May 10 2020 | Read more