Uninstall ASR mobility service

AdamTyler-3590 310 Reputation points

Hello, I've followed a few articles for installing the mobility service and registering a given machine with the replication appliance, but what about uninstalling? Is this msiexec command from the following post sufficient to unregister from the replication appliance and remove all componets from the replicated VM?

https://learn.microsoft.com/en-us/azure/site-recovery/vmware-physical-manage-mobility-service#uninstall-mobility-service

MsiExec.exe /qn /x {275197FC-14FD-4560-A5EB-38217F80CBD1} /L+*V "C:\ProgramData\ASRSetupLogs\UnifiedAgentMSIUninstall.log"

I attempted this on a test system and removal of all components from Add/Remove programs looks good.

This folder still exists however and contains quite a few files.

C:\Program Files (x86)\Microsoft Azure Site Recovery

I also noticed this certificate installed in the personal store of the computer account. Sort of a mess. Wondering what other components are still hanging out on this system and if there is anything that needs to be done to unregister it from the replication appliance?

👁 User's image

0 comments No comments

Sign in to comment

Answer accepted by question author

Sadiqh Ahmed 49,571 Reputation points Microsoft External Staff Moderator

@AdamTyler-3590 Thank you for reaching out to us. Happy to assist!

The MsiExec.exe command that you mentioned is used to uninstall the Mobility Service from a Windows machine. This command removes the Mobility Service components from the machine, including the Mobility Service agent, the Mobility Service extension, and the Mobility Service certificate.

After running this command, you should no longer see the Mobility Service listed in the Add/Remove Programs list. However, some files and folders related to the Mobility Service may still exist on the machine, such as the C:\Program Files (x86)\Microsoft Azure Site Recovery folder that you mentioned. These files and folders can be safely deleted if you are sure that you no longer need them.

To unregister the machine from the replication appliance, you can remove the machine from the replication configuration in the Azure Site Recovery portal. To do this, go to Replication > Replicated Items, select the machine that you want to remove, and click Remove.

Doc reference: https://learn.microsoft.com/en-us/azure/site-recovery/site-recovery-manage-registration-and-protection#disable-protection-for-a-vmware-vm-or-physical-server-vmware-to-azure

Hope this helps. Let Us know if you have any further questions.


If the response helped, do "Accept Answer" and up-vote it

  1. AdamTyler-3590 310 Reputation points

    Hello @Sadiqh Ahmed . In this case of testing I actually manually installed the mobility service and registered it to the replication appliance using the cmd option referenced here...

    https://learn.microsoft.com/en-us/azure/site-recovery/vmware-physical-mobility-service-overview#install-the-mobility-service-using-command-prompt-modernized

    This was just a test as I had never been through the process of installing the agent in this manner. I only did so to validate that basic disks could be excluded from replication which worked, but I never saved the replication config. Just got far enough into the Azure ASR wizard to confirm that yes I could exclude disks if the agent was manually installed.

    So replication was never setup and there is no Azure ASR replication config to remove. However, the agent was manually registered via the cmd process. Is there no need to unregister? The msiexec command to uninstall will take care of this?

    Also, the certificate did not get removed using the msiexec uninstall. Should this be done manually then? Would it cause problems down the line if I wanted to setup replication on this system again?

    Regards,
    Adam Tyler

  2. Sadiqh Ahmed 49,571 Reputation points Microsoft External Staff Moderator

    @AdamTyler-3590 If you manually installed the Mobility Service on a machine and registered it with the replication appliance using the command prompt, but did not save the replication configuration, then there is no need to unregister the machine from the replication appliance. The MsiExec.exe command to uninstall the Mobility Service will remove all the components of the Mobility Service from the machine, including the Mobility Service agent, the Mobility Service extension, and the Mobility Service certificate.

    Regarding the Mobility Service certificate, it is not necessary to remove it manually. When you uninstall the Mobility Service using the MsiExec.exe command, the certificate is removed along with the other components of the Mobility Service. If you want to set up replication on the machine again in the future, you can simply install the Mobility Service again and register it with the replication appliance.

    Let us know if you have any questions!

  3. AdamTyler-3590 310 Reputation points

    @Sadiqh Ahmed , thank you. I was able to manually delete the leftover directories. Only difference I am seeing is that the msiexec uninstall process did not remove the certificate from the computer personal store. I had to delete that manually. At least in this test case.

    Regards,
    Adam Tyler

  4. Sadiqh Ahmed 49,571 Reputation points Microsoft External Staff Moderator

    @AdamTyler-3590 Thanks for the update.

  5. KrupaVani Gundraju 25 Reputation points

    Do we have to restart the server once we uninstalled the mobility service?


Sign in to comment

0 additional answers

Sign in to answer

Your answer