Manually reinstall SCVMM Agent (2012 R2) on Hyper-V cluster node

Background

I was recently exposed to a troubleshooting scenario where it was necessary to manually uninstall and reinstall the SCVMM agent from a node in a Hyper-V cluster.  Since the node is clustered and managed by SCVMM, there is no option presented in the SCVMM console to be able to gracefully uninstall and reinstall the SCVMM agent.  Therefore, manual removal and re-installation is necessary.

Uninstall

Removal of the SCVMM agent is straightforward provided that you are not running Server Core on the parent partition.  Just use the Uninstall option in Add/Remove programs.  Remotely, or locally while running Server Core, you could use something like

(Get-WmiObject -Class Win32_product -Filter “Name=’Microsoft System Center Virtual Machine Manager Agent (x64)'”).uninstall()

Reinstall

Conventional instruction would have you locate the agent installation via the System Center Virtual Machine Manager original installation media.  If you have installed no Update Rollups in your SCVMM environment, then follow this link for guidance.  If you have installed Update Rollups in the SCVMM infrastructure, you will need to install the latest version of the agent, which can be located on your SCVMM Management role server(s) under “%systemdrive%\Program Files\Microsoft System Center 2012 R2\Virtual Machine Manager\agents”.  From here, select the server architecture and then select the latest agent version directory.  If you simply run vmmagent.msi, you will get an error stating that the Microsoft System Center Virtual Machine Manager Agent (x64) Setup Wizard ended prematurely.

SCVMM Agent Installation Error

Instead, copy the latest agent version directory from the remote location to a local directory.  Run a command prompt as Administrator, and change directory to the latest agent version directory that you have copied locally.  Execute

msiexec /I vmmAgent.msi

The SCVMM Agent should reinstall successfully.  In SCVMM, refesh the Hyper-V cluster and verify that there are no outstanding WMI issues on the (Host) > Properties > Status screen.

Reference

http://www.ivobeerens.nl/2015/01/14/scvmm-2012-r2-agent-update-error/

https://danielthomasclarke.wordpress.com/2014/09/09/vmm-2012-r2-uninstall-vmm-agent-from-windows-server-2012-r2-core/

2 thoughts on “Manually reinstall SCVMM Agent (2012 R2) on Hyper-V cluster node

  1. This saved my day. After rollup 12 one of the cluster nodes BSODed during Agent update. The agent was removed and could not be added from VMM. Now it works again!
    Thx again!
    Kind regards, Erwin.

    Like

Leave a comment