8 Replies Latest reply on Oct 17, 2019 1:27 PM by wreedMH

    Cannot remove protection

    krowczynski1980 Novice

      Hello all,


      unfortunately a VM was removed from Cluster before the protection of SRM was removed.

      Now the VM has the status "Invalid: Protected VM deleted".

      Any ideas or hints how this one can be removed?



      Thanks for some help here.

        • 1. Re: Cannot remove protection
          yezdi Master



          Please go through the following KB. Hope it will resolve the problem.


          To resolve this issue:

          1. Manually identify and remove the managedBy tag from the virtual machines using the Power CLI script
          2. Perform a manual cleanup of the incorrect entries in the vCenter Server database.

          VMs are reported as managed by Site Recovery Manager (2032366) | VMware KB

          -SD [vExpert 14-20, VCIX6-NV&DCV,RHCE,AWS-SAA]

          1 person found this helpful
          • 2. Re: Cannot remove protection
            LittleCrow Novice

            We have the same issue.  However, the KB linked doesn't apply as we're running SRM 6.5 using the bundled postgres DB.

            I've not been able to find a document that applies, so barring a call to VMWare the only option is to delete the protection group and recreate it.



            #### Edit ####

            Just tried removing the Protection group and can't, get the error 'Cannot remove a protection group with protected VMs'

            Also changed the Datastore Group assigned to the protection group - The deleted VM still stays in the Protection group, despite never having been on the Datastore now protected.


            Looks like a call to get the equivalent Postgres commands is needed.

            • 3. Re: Cannot remove protection
              jameseydoyle Hot Shot
              VMware Employees

              I'm afraid a call to VMware is probably the best thing to do in this situation. There will be reference to this deleted VM in the SRM DB in the pdh_protectedvm, pdr_protectedvm or pdr_protectedvmpeer tables and other references in other DB tables that will need to be cleaned up. Make sure that you take a full backup of the DB before you do anything though.

              • 4. Re: Cannot remove protection
                rshenoy Enthusiast



                I would suggest to unprotect the remaining virtual machines that are currently residing on the impacted protection group making it only the stale VM placed on the PG. The only way to clean it up would be by removing the VM entries from the SRM DB (we have 8 such tables which holds the references to this VM. If you have a large VM inventory protected under SRM then easiest way would be to remove the protection group itself from SRM DB on both the sites.

                • 5. Re: Cannot remove protection
                  LittleCrow Novice

                  We just updated to vSphere 6.5U1 and SRM 6.5.1 - it looks like this can now be done through the GUI without having to resort to editing Database tables, etc.

                  • 6. Re: Cannot remove protection
                    JsikesAW Lurker

                    Just a follow up question to this.. Is it possible to perform the deletion of Invalid (due to deletion) VMs inside of protection group using PowerCLI? Since we've moved to a CI/CD model the manual cleanup of deleted VMs is painful thru the GUI. I've worked with Ben Meadowcroft's SRM PowerCLI cmdlets but it doesn't seem to allow protection removal on deleted/invalid VMs.

                    • 7. Re: Cannot remove protection
                      Jitu211003 Hot Shot



                      Here in my scenario, we face same kind of issue wherein VMs is decommissioned from the Vcenter but not from the SRM console.


                      Later we used to remove the protection from the SRM console for those VMs clears the error in SRM Console.


                      Just right click on those VMs under protection group and select remove/delete .

                      • 8. Re: Cannot remove protection
                        wreedMH Enthusiast

                        Is there a way to force delete a protection group or site pair?


                        My remove/delete VM from SRM is greyed out.