Creating a Virtual Machine
We provide a virtual machine image of FileMage Gateway for Microsoft Azure. No installation is required. You just need to create a virtual machine from the Microsoft Azure Virtual Machines Marketplace. This virtual machine image is fully functional upon launch and requires no additional configuration to use. However, you may need to make certain changes depending on your specific use case.
To create a virtual machine, you must have permissions to access and manage a subscription or resource group in Azure.
First Time Login
After deploying the virtual machine make note of its IP address. The browser portal will be available at
https://<server-ip>/. A self-signed certificate is used, which you will have to accept to bypass the browser warning. See Encryption and Certificates for instructions on how to install a signed certificate.
The first time the portal is used you will be asked to register an administrator account.
By default the following ports are used. See Configuration Reference for information on how to change these ports.
When HTTPS is enabled traffic on the HTTP port will be redirected to the HTTPS port.
To use SFTP on port 22
sshd must be reconfigured to use a different port.
Increase Passive Mode FTP Port Range
By default, FileMage Gateway deployed on Azure Marketplace is configured to use ports
6000-6005 for passive mode FTP data connections. This port range may be to small in situations where multiple clients attempt to establish data connections at the same time, and may cause connecting clients to experience delays or be completely unable to connect when they request passive data transfers. The following explains how to enable a larger port range for passive mode FTP in FileMage Gateway installed on a Microsoft Azure.
Add Inbound Security Rules
Log in to Microsoft Azure portal.
Go to Virtual machines
- Click the name of the virtual machine you want to configure.
- Under Settings, click on Networking.
Click the Add inbound port rule button.
In the Add inbound security rule panel, specify the following settings:
- Service. Keep the Custom value in the drop-down list.
- Port ranges. Specify the following port range:
- Priority. This value determines the order in which firewall rules are applied. Rules with low priority are applied before rules with high priority. We recommend keeping the automatically assigned Priority value.
- Name. Give the rule a recognizable name so you can tell it apart from others.
- (Optional) Description. If desired, you can add the description to the rule.
You may use any port range, however
32768-60999 is the recommend standard port range.
- Click OK.
Set FTP Passive Mode Port Range
Log in to your server via SSH as the user you specified when launching the instance.
Open the FileMage Gateway configuration file.
sudo vi /etc/filemage/config.yml
- Add, or modify, the following settings, and then save the changes:
ftp_data_port_start: 32768 ftp_data_port_end: 60999
- Restart the server:
sudo systemctl restart filemage
FileMage Gatway is now configured to use a larger range of ports for passive mode FTP data connections.
FTP Public IP Address Auto-detection
FileMage Gateway will use the Azure instance metadata service to detect the virtual machine's public IP address for passive FTP connections. You may override this address by specifying a IP address to be used for FTP passive connections in the servers configuration file. See FTP Public Address Configuration.
Running SFTP on Port 22
To make FileMage Gateways SFTP functionality available on port 22, the OpenSSH service must to be re-configured to use a different port.
- Stop FileMage Gateway.
sudo systemctl stop filemage
- Open the OpenSSH server configuration file.
sudo vi /etc/ssh/sshd_config
- Uncomment and set the
Portdirective to the desired SSH port number.
- Restart the OpenSSH server.
sudo systemctl restart sshd
- Verify that OpenSSH was able to start correctly.
sudo systemctl status sshd
- Open the FileMage Gateway configuration file.
sudo vi /etc/filemage/config.yml
- Set the
sftp_portconfiguration to the desired SFTP port number.
- Start FileMage Gateway.
sudo systemctl start filemage
Make sure OpenSSH is running properly and can accept new SSH connections before disconnecting your current SSH session to avoid becoming locked out of the system.