How Do I Migrate from Amazon S3 to Contabo Object Storage?
TABLE OF CONTENTS
- Requirements before migrating from Amazon S3 to Contabo Object Storage
- Configuring rclone
- Configuration for Amazon S3 (Source)
- Configuration for Contabo Object Storage (Destination)
- Starting the migration process
- Verifying the migration process
Requirements before migrating from Amazon S3 to Contabo Object Storage:
In order to migrate from Amazon S3 to Contabo Object Storage a few things are required:
- An Amazon S3 Storage + Credentials (e.g. S3 URL, Access Key and Secret Key).
- A Contabo Object Storage + Credentials (e.g. S3 URL, Access Key and Secret Key).
- A Server with a Linux-based operating system.
- Rclone installed on your Linux-server.
To install rclone use this command:
apt install rclone-y
Configure rclone:
To transfer the files from Amazon S3 to Contabo Object Storage we are recommend using the tool rclone.
If you want to learn more about rclone and other tools that work with Contabo Object Storage check out the official documentation here.
After installing it on your Linux-server, you need to configure the source-server, as well as the destination server.
Although your own local PC with WSL on it or a linux workstation could be used, we recommend using a VPS (e.g. our VPS S SSD) because the migration process might take a while depending on the size of the files to copy. It’s crucial to execute the migration process uninterrupted.
Config for Amazon S3 (Source):
- Create a new config by running this command:
rclone config
- Now type in “n” to make a new remote and press enter.
- Now enter a name for this config (e.g. Amazon S3 or source).
- Now type in “4” to select “Amazon S3 Compliant Storage Providers” and press enter.
- Type “1” to select “Amazon Web Services (AWS) S3”.
- Again, type in “1” to enter your AWS Credentials.
- Now fill in your S3-Access Key ID and press enter.
- Now paste in your S3-Secret Access Key.
- Skip the next menus by pressing enter until it asks you “Edit advanced config?”.
- Now type in “n” and press enter.
- To finish the setup process, save everything by typing in “y” and hitting enter and typing in “q” to leave to configuration menu.
Config for Contabo Object Storage (Destination):
- Create a new config by running this command:
rclone config
- Now type in “n” to make a new remote and press enter.
- Now enter a name for this config (e.g. Contabo S3 or destination).
- Now type in “4” to select “Amazon S3 Compliant Storage Providers” and press enter.
- In the next menu type “2” to select “Ceph Object Storage”.
- Type in “1” to enter your AWS Credentials.
- Now enter your Access Key and hit enter.
- Now enter your Secret Key and hit enter.
- Skip the region by hitting enter.
- For the Endpoint paste in the S3-URL (e.g. https://eu2.contabostorage.com).
- Skip the next two menus by hitting enter two times.
- Now type in “n” to skip the advanced config.
- Hit “y” to save the config and exit the config menu by typing in “q”.
Start the migration process:
- Run the following command to start the migration process:
rclone copy [Name of the Source config]:[Path] [Name of the Destination Config]:[Path]
- If you want to migrate the whole content at once and not only a certain bucket, use this command instead:
rclone copy source:~ dest:~
Verify the migration process:
It is important to check the migration is complete and everything has been copied over correctly. To do this you can compare the file counts of the source-server with the destination-server. To do so, use these commands:
For Amazon S3 (Source server) run the following command:
rclone ls s3:~ --recursive | wc -l
For Contabo Object Storage (Destination Server) run the following command:
rclone ls contabo:~ --recursive | wc -l
Was this article helpful?
That’s Great!
Thank you for your feedback
Sorry! We couldn't be helpful
Thank you for your feedback
Feedback sent
We appreciate your effort and will try to fix the article