Configuring Remote Agent on Microsoft Azure Virtual Machine

In order to make the Remote Agent working in an MS Azure Virtual Machine, the OS need an extra configuration and also the remote configuration. This makes the Remote Agent accessible outside the box.

Resolve Public DNS name within in Virtual Machine

Currently any MS Azure VM (out of the box) cannot resolve locally the public DNS. So it needs further setup to make this work. Get the public DNS name of the VM instance via Azure portal.

  • Linux based Virtual Machines
  • Windows based Azure VM instance
    1. Login in the OS via Remote Desktop with the right user and password.
    2. Open the Notepad application as Administrator.
    3. Once the Notepad is open, edit the file %SystemRoot%\System32\drivers\etc\hosts
    4. Add a new line with the local IP and the public DNS name, for example:
      10.0.0.6                vm-instance-name.westeurope.cloudapp.azure.com
    5. Finally, save the file.
  • Linux based Azure Vm instance
    1. Login in the OS via SSH with the right user and password (The user must have sudo rights)
    2. Edit /etc/hosts file, run "sudo vi /etc/hosts"
    3. Add a new line with the local IP and the public DNS name, for example:
      10.0.0.6                vm-instance-name.westeurope.cloudapp.azure.com

Remote Agent setup

The agent need to configured before it is started up.

  1. Go to the directory where the remote agent was expanded/installed (MV_AGENT_HOME)
  2. The edit the file midvision-remoting-agent-server.xml located in MV_AGENT_HOME/bin
  3. Change the host property to the public DNS name, for example:
  4. Save the changes and start the remote agent via the provider script under MV_AGENT_HOME/bin
    <resource type="host">vm-instance-name.westeurope.cloudapp.azure.com</resource>