What is Rclone?
Rclone is a command-line program used to manage and synchronize files with various cloud storage services and other locations.
In this scenario, Rclone is used only for the initial configuration of the A2 object storage, and backups will be performed through the CloudPanel Interface.
Rclone configuration
To configure Rclone you first log in to the server via SSH. Once you have logged in, please run the following command:
rclone config
The command will open a prompt that looks like the following:
To configure Rclone to use A2 storage, the following information is required:
-
Bucket name
-
Storage directory
-
Bucket URL
-
Secret key
-
Access key
This information can be found in your account under "Object Storage". For more information, please review:
The easiest way to configure the destination will be to copy the below configuration into the following file:
/root/.config/rclone/rclone.conf
Note: The name must be [remote] for CloudPanel to detect the configuration:
cat /root/.config/rclone/rclone.conf
[remote]
type = s3
provider = ceph
access_key_id = $key_id
secret_access_key = $access_key
endpoint = a2-west.americancloud.com
Make sure to replace $key_id and $access_key with the ones provided under "Object Storage > Bucket > Settings", as shown in the screenshot:
Go back to CloudPanel and configure the bucket name and remote directory:
A2 storage
If you do not have A2 storage, please review the following article:
Testing Backups
Once the configuration has been completed, you can test with the following command, which shows remote directories in the bucket and confirms the connection is valid:
rclone lsf $remote_bucket_name: -R
WordPressBackup/
FullBackup/
Creating your first backup
To create a manual backup, simply click on "Create Backup" as shown in the screenshot. The backup will be started in the background.