Installing HVR on Azure Manually
This section describes the steps to manually install an HVR Agent on Azure virtual machine when using Azure SQL Database for replication. Another way to install an HVR Agent on Azure virtual machine is to use a pre-configured HVR for Azure image available on the Azure Marketplace.
Follow the steps to create HVR instance on Azure virtual machine (VM):
On the Azure portal home page, click Virtual Machines and then click Add to create a new virtual machine. Complete the corresponding steps to configure the virtual machine as required (Basics, Disks, Networking, Management, Advanced, Tags). For example, under the Basics tab, select Windows Server 2012 as a VM image and A1 for the VM size. Please note that the size of the VM depends on the workload that you want to run.
Install the HVR software on the virtual machine following the steps of the HVR Setup wizard. On step Additional Configuration, select Add HVR_HOME, HVR_CONFIG and HVR_TMP option. Note that the HVR user needs the privilege Log on as a service on Windows.
Create and start the HVR Remote Listener service as described in section Creating and Starting HVR Remote Listener Service from GUI.
In the virtual machine, install the SQL Server 2012 Native Client (sqlncli.msi) and configure Windows Firewall for allowing connections both local and remote for hvrremotelistener.exe.
Finally, in the Azure portal, create an endpoint for the HVR Remote Listener with the same port number you have specified in step 3. Go to the Networking settings of your virtual machine, click Add inbound security rule and type the port number (e.g. 4343) in the Destination port ranges.
Optional step - when the Azure SQL database is not accessible from the virtual machine (e.g. in different subscriptions or zones), add its IP address to the Azure SQL firewall. On the Azure Portal, go to SQL databases and select the database you want to give access to. In the database, select Set server firewall, this will open the Firewall settings dialog, where the IP address can be added by clicking Add client IP.
Note that the VM in Azure can also be a Linux server. For the steps to install HVR on Linux, refer to section Installing HVR on Unix or Linux. Additionally, a relevant ODBC driver for the database you use need to be installed on the Linux VM.