You are currently viewing How to copy and move files in AWS S3

How to copy and move files in AWS S3

Loading

In the last blog we have seen how to create a bucket in AWS S3. In this blog, we will learn about copy and move files in AWS S3. It is a crucial task for efficient data management and backup in cloud storage.

Steps to copy files within folders in AWS S3

First of all you have to create a destination folder by clicking on “Create folder” button and named the folder as dataset_2.

Next click on the dataset folder and click on the file that you want to copy and click on the Actions. You will see various options you have to click on the Copy. Beside copying you can also do the following things like

  • Copying the S3 URI (Uniform Resource Identifier)- It will look like this s3://firstbucket0072/train.csv
  • Next you can copy the URL of the file
  • You can also download the CSV file.
  • If you click on Open it will also do the same which is downloading the file.
  • Then you can delete the file
  • After that you can do various things in Actions such as
    • You can download the file
    • Share with a presigned URL- It is a temporary URL which gives temporary access to an specific S3 object.
    • You can calculate the total size of the file.
    • Then there is option of Copy and Move options. Rest we will talk later in the specific blog.

The Copy interface will look this.

Next click on the browse s3 and choose the destination folder where you want to copy the files.

Rest leave everything as default and click on Copy.

Now you can see that you have successfully copied the files.

Now go to the dataset_2 folder in order to verify whether the file is copied or not.

Steps to move files within folder in AWS S3

Create a new destination folder named as dataset_3 by clicking on Create folder.

Go to the dataset folder select the file that you want to move and click on Action and select the option as Move.

The Move interface will look like this. There are two types of destination types is shown which are given below

  • General purpose bucket- In the general purpose bucket, when you click on browse s3 you will see all the buckets which are created inside your account.
  • Access Point- It’s an AWS feature that helps you control who can access your S3 buckets. This feature lets you make custom entry rules for certain uses or apps, which makes it easier to control who has access to a lot of data.

Click on browse S3 and select the destination as dataset_3 folder.

Now click on the Move button.

You can see that you have successfully move the file.

You can verify it by going to dataset_3 folder.

You can also do the same thing using programmatically also it means in your favorite programming language Python. But for that you need to have knowledge of AWS IAM (Identity Access Management) services. So we will discuss in the later blogs.

Conclusion

If you follow the steps above, it will be easy to copy and move files within AWS S3 folder, which will make managing your cloud storage better. If you master this process, you’ll be able to handle data more efficiently and make operational routines better.

You can tell your friends or coworkers about this blog if you like it. There are social media sites like LinkedIn, Twitter, and Instagram where you can find me.

If you like the article and would like to support me, make sure to: