After installing the VM agent, you must also use Azure PowerShell to update the ProvisionGuestAgent property so Azure knows the VM has the agent installed. This is also documented on MSDN at Manage Extensions.

Updating the ProvisionGuestAgent property is only necessary if the VM is already running in Azure and the agent was not provisioned when the VM was created. When creating a VM from an image (including from custom image), by default the VM agent is installed and that property is updated automatically.

Note that when creating a VM from an existing, specialized VHD (sysprep was not run generalize it), selecting Install the VM Agent in the portal only sets the property and does not install the agent. In that scenario you must install the agent after the VM is provisioned in Azure.

It's annoying that there is no cmdlet to simply install the VM Agent. We are early adopters of Azure and have hundreds of machines without the agent. I cant even push it via GPO because it fails due to elevated command prompt requirements (process sits at 0 and hangs).

Hi @Craig Landis, I installed the agent for which I need to perform the backup. what could be a possible reason that when I try to set the property above, I get a no default subscription set error. I try the

command but it says that it did not find any subscription with that name.

On the other hand, another machine shows up in the discovery of the VMs. Surprisingly, I get the same errors on it as well. But it still does appear under the list of discovered VMs. What exactly am I missing on the other VM?

Update-AzureVM : Networking.DeploymentVNetAddressAllocationFailure : Unable to allocate the required address spaces for the deployment in a new or predefined subnet that is contained within the specified virtual network.

Found a solution to this using the new management portal – download the agent installer from the link provided on the new Azure Management Portal – the link will appear when you try to pick an extension to install for the first time. Install the Agent on the VM (I just right clicked install on the MSI file once downloaded logged in as administrator profile).

Then install the BGInfo extension from within the new Management Portal – this will in effect finalize the VM Agent installation rather than having to use the powershell script above. Bit of a hacky workaround but did the job.