- This topic is empty.
- Post
-
- December 21, 2024 at 6:13 am
Weekend WikiKeymasterRestoring your 3CX database from cloud storage like Google Cloud or Microsoft Azure involves several steps, as the backup files are stored remotely. Below is a detailed guide for restoring your 3CX backup from Google Cloud or Microsoft Azure back to your 3CX server.Restoring 3CX Database from Google Cloud Storage
Step 1: Set Up Google Cloud SDK or rclone
You need a tool to retrieve the backup from Google Cloud Storage. We’ll use rclone, which supports Google Cloud Storage and other cloud providers.
- Install rclone on your 3CX server (Ubuntu):
sudo apt install rclone
- Configure rclone with Google Cloud Storage:
- Run the following command:
rclone config
- Select
n
for a new remote. - Choose
drive
for Google Drive orgoogle cloud storage
for direct Google Cloud Storage. - Follow the prompts to authenticate using your Google Cloud account and Service Account credentials (JSON key file).
Example:
rclone config n google cloud storage
- Run the following command:
- Test rclone connection to ensure it can access your Google Cloud Storage:
rclone ls remote:3cx-backups
Step 2: Download Backup from Google Cloud Storage
- Download the Backup: After configuring rclone, you can download the backup from Google Cloud Storage to your local server directory.
Example:
rclone copy remote:3cx-backups /var/lib/3cx/backup/
Replace
remote:3cx-backups
with the path of your cloud storage bucket and/var/lib/3cx/backup/
with your desired local backup directory on the 3CX server.
Step 3: Restore the Backup in 3CX
- Stop 3CX Services: Before restoring a backup, stop the 3CX services:
sudo service 3cxpbx stop
- Restore the Backup: In the 3CX Management Console, navigate to Backup and Restore and choose the Restore option.
- Choose the Backup File: Select the downloaded backup file from the directory
/var/lib/3cx/backup/
. - Follow the prompts to restore the backup. You can choose whether to restore the entire system or specific parts (e.g., configuration, extension data).
- Choose the Backup File: Select the downloaded backup file from the directory
- Start 3CX Services: Once the restore is complete, restart the 3CX services:
sudo service 3cxpbx start
Restoring 3CX Database from Microsoft Azure Blob Storage
Step 1: Set Up Azure CLI or rclone
We will use rclone for Azure as well, similar to Google Cloud.
- Install rclone on your 3CX server (if not already installed):
sudo apt install rclone
- Configure rclone with Azure Blob Storage:
- Run the command:
rclone config
- Select
n
for a new remote. - Choose
azureblob
for Azure Blob Storage. - Follow the prompts to enter your Azure Storage Account Name and Access Key.
Example:
rclone config n azureblob
- Run the command:
- Test rclone connection to verify that it can access your Azure Blob Storage:
rclone ls azure:3cx-backups
Step 2: Download Backup from Azure Blob Storage
- Download the Backup: Use rclone to download the backup from Azure Blob Storage to your local 3CX server directory:
rclone copy azure:3cx-backups /var/lib/3cx/backup/
Replace
azure:3cx-backups
with your configured Azure Blob Storage container name and/var/lib/3cx/backup/
with your backup directory on the 3CX server.
Step 3: Restore the Backup in 3CX
- Stop 3CX Services: Before restoring the backup, stop the 3CX services:
sudo service 3cxpbx stop
- Restore the Backup: Go to Backup and Restore in the 3CX Management Console and choose the Restore option.
- Select the backup file from the
/var/lib/3cx/backup/
directory (where the backup was downloaded). - Follow the prompts to complete the restore process. You can choose to restore the entire system or specific parts.
- Select the backup file from the
- Start 3CX Services: After the restore is finished, restart the 3CX services:
sudo service 3cxpbx start
Step 4: Verify the Restoration
- Check 3CX Operation: Once the restoration is complete and the 3CX system has restarted, verify that the system is functioning properly.
- Check if all extensions, configurations, and settings are restored.
- Test basic functionalities such as making and receiving calls, and checking user settings.
- Backup Verification: Verify that the restore process didn’t encounter any issues by checking logs in the 3CX system and ensuring everything is up-to-date and functional.
Conclusion
Restoring your 3CX database from Google Cloud or Microsoft Azure involves:
- Setting up a connection to your cloud storage (using rclone).
- Downloading the backup from cloud storage to your server.
- Using the 3CX Management Console to restore the backup to the system.
By following these steps, you can easily restore your 3CX system from cloud storage, ensuring a reliable backup solution. If you run into any issues or need further clarification, feel free to ask!
- You must be logged in to reply to this topic.