Migration of cloud storage from Servers.ru to S3
You can migrate your data from Servers.ru (Swift) cloud storage to S3 from Selectel by yourself.
You can use different S3 tools for migration, for example:
- Rclone (recommended method) - supports direct data transfer without intermediate copying, as well as segmented download at high data transfer rates. Suitable for transferring large amounts of data;
- Cyberduck graphical client - does not support copying and direct transfer of data from Servers.ru to S3. You will need to download data from Servers.ru storage and upload to S3 manually;
- FTP protocol - does not support copying and direct transfer of data from Servers.ru to S3. You will need to download data from Servers.ru storage and upload to S3 manually. Works only with S3 bucket pools ru-1 and ru-7.
If difficulties arise during the migration process:
- on the Servers.ru side - contact Servers.ru support service;
- on the Selectel side, create a ticket.
Perform migration
- Prepare S3.
- Configure access to S3.
- Get data to connect to Servers.ru.
- Customize the tool and transfer the data.
- Check the results of the migration.
1. Prepare S3
-
If you do not already have an account in the my.selectel.ru control panel:
1.1 Register an account in the control panel.
1.2 Refill your balance.
-
Create an S3 bucket in the desired bullet. We recommend creating the bucket in pool ru-7.
2. Configure access to S3
Access can be configured by the Account Owner or a user with the role of iam.admin.
- Create a service user with role with access to S3. If you use a service user with the role s3.user, object_storage_user or
s3.bucket.user, the bucket must have a configured access policy and its rules must allow access to this user. - Issue an S3 key to the user.
3. Get data for connection to Servers.ru
-
In the Servers.ru control panel, open the Cloud Storage tab.
-
In the Access Details block, copy and save the data:
-
login and password for access via Swift API to Servers.ru;
-
domain for Keystone v3 (Swift) in the format
https://auth.files.<region>.cloud.servers.ru:5000/v3/, where you can find.files.<region>.cloud.Servers.<domain_zone>is the address of the server where:<region>- region where the Servers.ru storage is located;<domain_zone>- domain zone:ruorcom.
-
if you will use FTP, FTP host in the format
ftp.files.<region>.cloud.servers.ru, where<region>is the region where the Servers.ru repository is located.
-
4. Customize the tool and transfer the data
Rclone
Cyberduck
FTP
Learn more about working with Rclone in the Rclone manual.
-
Create a configuration to connect to Servers.ru:
2.1 Open the configuration mode:
rclone configA dialog box will appear in the console:
No remotes found, make a new one?
n) New remote
s) Set configuration password
q) Quit config2.2 Create a new configuration:
n/s/q> n2.3. Enter the name of the remote storage connection, for example
serversru:name> serversru2.4. enter the OpenStack Swift storage type:
Storage> swift2.5. Select the method for obtaining
credentialsthat is listed after theEnter AWS credentials in the next stepline:env_auth> false2.6 Enter login:
user> <login>Specify
<login>- the login you saved when receiving data to connect to Servers.ru in step 3.2.7 Enter the password:
key> <password>Specify
<password>- the password you saved when receiving data to connect to Servers.ru in step 3.2.8 Enter the URL to access the Swift API:
endpoint> <swift_domain>Specify
<swift_domain>- enter the server address that you saved when receiving data to connect to Servers.ru in step 3.2.9. In the
auth_versionparameter, enter3:auth_version> 32.10. Leave the optional parameters blank.
2.11. In the
Option domainparameter, enterdefault.2.12. Leave the
Edit advanced configparameter blank or entern.2.13. Check the configuration. If the configuration is correct, press Enter. If not, enter
eand edit the configuration.2.14. Confirm the creation of the configuration:
y/e/d> y2.15. Exit the settings dialog box:
e/n/d/r/c/s/q> q -
Optional: see the data to be copied without performing a copy:
rclone copy serversru:<container_name> selectel:<bucket_name> --dry-runSpecify:
<serversru_name>- name of connection to Servers.ru, which you specified in step 2.3;<container_name>- name of the Servers.ru container;<selectel_name>- the name of the connection to S3 that you specified when creating the configuration creating the configuration in step 4;<bucket_name>- bucket name in S3.
-
Transfer the data in one of the following ways:
-
copy all data from the Servers.ru container to the S3 bucket:
rclone copy <serversru_name>:<container_name> <selectel_name>:<bucket_name> --progressSpecify:
<serversru_name>- name of connection to Servers.ru, which you specified in step 2.3;<container_name>- name of the Servers.ru container;<selectel_name>- the name of the connection to S3 that you specified when creating the configuration creating the configuration in step 4;<bucket_name>- bucket name in S3;- optional:
--progress- option that enables displaying copy progress.
-
or synchronize data - in S3 the data that is not in Servers.ru will be deleted:
rclone sync <serversru_name>:<container_name> <selectel_name>:<bucket_name> --progress
-
Learn more about working with Cyberduck in the Cyberduck manual.
-
If a ready-made Swift Keystone v3 profile is available in the Servers.ru control panel, connect to Servers.ru through it:
2.1 Download a profile.
2.2 Open a profile. It will be applied automatically.
-
If the ready profile is not available, connect to Servers.ru manually:
3.1 Open Cyberduck.
3.2 Click New Connection.
3.3 In the top field, open the list and select Swift (OpenStack Object Storage) protocol.
3.3 Enter the server address you saved when receiving data to connect to Servers.ru in step 3.
3.4 Enter port -
5000.3.5. Enter the login you saved when receiving data to connect to Servers.ru in step 3.
3.6. Enter the password you saved when receiving data to connect to Servers.ru in step 3.
3.7 Click Connect.
-
Download data from Servers.ru storage:
5.1 Open the window with connection to Servers.ru.
5.2 Select the files and folders you want to transfer.
5.3. Right-click on the files and select Download to Computer.
-
Load the data into S3:
6.1 Open the window with connection to S3.
6.2 Open the bucket from which you want to transfer data.
6.3 Click Download and select the downloaded files.
For more information on FTP operation, see the FTP instructions.
-
Connect to Servers.ru via FTP:
1.1 Open the FTP client.
1.2 Enter the FTP host address that you saved when receiving data to connect to Servers.ru in step 3.
1.3 Enter port - 21.
1.4. Enter the login you saved when receiving data to connect to Servers.ru in step 3.
1.5. Enter the password you saved when receiving data to connect to Servers.ru in step 3.
1.6 Connect to the FTP host.
-
Download the data you want to transfer to S3.
-
Open the baquette you created when preparing S3 in step 1.
-
Load the data you downloaded in step 2 into the bucket.
5. Check the migration results
It is necessary to check the migration results before deleting data from the Servers.ru storage.
-
Verify that all data appears in the S3 binnacle.
-
Update the settings of applications that use storage data:
2.1 Specify S3 domains instead of Servers.ru domains.
2.2 Specify the S3 key you issued when setting up access to S3 in step 2 instead of the data for accessing Servers.ru.
2.3 If the name of the bucket in S3 differs from the name of the container that was in the Servers.ru repository, specify the name of the S3 bucket.
-
Check how the apps work after updating the settings.