Virtualmin
Learn how to use Virtualmin to store data on the ScPrime distributed datacenter using the XNS Relayer
Overview
Virtualmin is a powerful and flexible open-source web hosting control panel for Linux and BSD systems with over 150,000 installations worldwide. Virtualmin has a powerful feature that provides backup and restore capabilities for all virtual hosts along with the underlying configuration and files. This feature uses the S3 protocol to communicate with the storage destination, so it makes a good match for XNS storage.
Read this guide for how to configure Virtualmin to store this backup data with XNS.
Prerequisites
- A working instance of Virtualmin
- A working instance of the XNS Relayer
- Configured XNS Relayer Endpoint Access Key and Endpoint Secret Key
Considerations
- By default, Virtualmin requires a valid SSL CA certificate to use the XNS Relayer as an HTTPS endpoint. This requirement can be bypassed as shown in this guide. Regardless of how certificates are configured, the certificate settings in the XNS Relayer need to match your Virtualmin settings. These settings can be accessed in the Relayer UI by going to Configuration > General Configuration and editing the Select Endpoint Certificate Type.
- This guide assumes that Virtualmin and the XNS Relayer are installed on the same server.
Application Version Used in Guide
Virtualmin 7.5 Professional
Setup Guide
Step 1: Change Virtualmin Default SSL Setting
Caution: Step 1 is optional only if you set up the XNS Relayer with a valid CA certificate. A self-signed certificate, or no certificate will fail.
Login to Virtualmin as the master administrator
Navigate to the Virtualmin “System Settings” menu and select Virtualmin Configuration:

From the “Server settings”, choose Backup and restore:

Find the setting “Full path to aws command for S3 operations” and select the radio button and enter “aws –no-verify-ssl” in the text box as shown:

Click Save when done.
Step 2: Virtualmin “Backup and Restore” Settings
Navigate to the Virtualmin “Backup and Restore” menu and select Cloud Storage Providers:

Step 3: Select “Amazon S3”
Select Amazon S3 from the list of provider names:

Step 4: Configure S3-compatible Storage Settings
On the next screen, there are a couple of radio buttons that need to be selected:
- For the “Default S3 login”, select the radio button “Entered below…”
- For the “S3-compatible server hostname”, select the radio button next to the text box

After the radio buttons are selected, configure the S3-compatible settings:
| Access Key: | [Your Access Key] | This is defined in the XNS Relayer setting “Endpoint Access Key (Username)” |
| Secret Key: | [Your Secret Key] | This is defined in the XNS Relayer setting “Endpoint Secret Key (Password)” |
| S3-compatible server hostname: | 192.168.1.50:9000 | Enter 192.168.1.50:9000 (port needs to match the XNS Relayer – 9000 is the default). By default, Virtualmin will attempt to make an HTTPS connection unless this requirement was bypassed as shown earlier in this guide |
| Location for new buckets: | Leave as “Default” |

Click Save when done.
Step 5: Verify the S3 Bucket in Virtualmin
Navigate to the Virtualmin “Backup and Restore” menu and select Amazon S3 Buckets:
If you created bucket(s) in XNS Relayer, they will show up in the list now. If no buckets show in the list, go back and create a bucket in XNS Relayer and double-check the “S3-compatible settings” configured earlier in this guide:

Step 6: Create a Backup
Navigate to the Virtualmin “Backup and Restore” menu and select Backup Virtual Servers:

Step 7: Configure Settings and Run Backup
Expand the “Destination and format” section
Next to “Backup Destinations”, select the drop-down menu and choose “Amazon S3 bucket”:

In the “Bucket and path” field, enter the bucket name to use for the backup, and optionally a subfolder (e.g. “bucketname/subfolder”):

Click Backup Now.
Step 8: Final Steps
Virtualmin has a rich backup feature set. Backups can be run on a schedule, and they can be full or incremental. Retention settings are fully customizable.
Note: 192.168.1.50:9000 is only an example — use the local network address of your own XNS Relayer. Port 9000 is the S3 API on a fresh install (plain HTTP, no certificate). Once you add an HTTPS certificate to your Relayer, switch to https:// and port 9443.
