none
Hyper-V Replica: Hyper-V failed to enable replication .. the handle is in the wrong state .. (0x00002EF3)

    Question

  • Hello,

    i am trying to get HV Replica on 2 servers with Hyper-V Server 2012 in a workgroup, based on certificates.
    All configuration works well until i actually try to activate replication for a vm. No matter which vm, which direction, what options, i always get the following errormessage:

    Hyper-V failed to enable replication.

    Hyper-V failed to enable replication for virtual machine 'xxx': The handle is in the wrong state for the requested operation (0x00002EF3). (Virtual Machine ID ...)

    I do not find any information in the net about any "handle" or it's "state" and what i can do about this.
    Has anyone seen this error and knows more about it?

     tm
    Monday, October 22, 2012 1:12 PM

Answers

  • Hello,

    i finally solved it, with re-installing and tests after each step while setting up the systems again:

    On both server the proxy-setting was set (to get Microsoft updates, using "netsh winhttp set proxy server.company.com") - just the proxy-server, but no bypass-list, what worked well enough in regards to Microsoft Updates. Apparently HV-Replica (with certificates relying on http/s) uses those proxy-settings to communicate with the Replica-Server but can of course no longer connect directly to the Replica-Server.
    Resetting/Removing the proxy-settings (or adding a bypass-list like "<local>;*.company.com") helped, HV-Replica is working now.

    Looking at the solution it seems obvious now but I would have really appreciated if there was a more descriptive error-message ("could not connect", "HTTP(S) failed" ..)  then just the mysterious "handle is in wrong state" ..

    But anyway, hopefully this helps someone else ..

    br,tm

    • Marked as answer by tzuiop Monday, October 29, 2012 10:24 AM
    Monday, October 29, 2012 10:23 AM

All replies

  • Hi,

    To help narrow down this issue, you may configure Replica to use only Kerberos authentication, do not use certificate-based authentication.

    Please refer to this article to check whether you have finished all preparation works for Hyper-V Replica.

    Prepare to Deploy Hyper-V Replica
    http://technet.microsoft.com/en-us/library/jj134153.aspx

    The information you provided is not enough to troubleshoot this issue, please check event log and post more related event logs.

    For more information please refer to following MS articles:

    Hyper-V Replica - Prerequisites for certificate based deployments
    http://blogs.technet.com/b/virtualization/archive/2012/03/13/hyper-v-replica-certificate-requirements.aspx
    Hyper-V Replica Feature Overview
    http://technet.microsoft.com/en-us/library/hh831716.aspx


    Lawrence

    TechNet Community Support

    Tuesday, October 23, 2012 7:15 AM
    Moderator
  • Hello,

    unfortunately Kerberos Authentication is afaik not available in a workgroup-scenario, otherwise i would have tested this.
    Or is there a workaround for that requirement?

    Additional informations (while reading your first link about "Prepare to Deploy Hyper-V Replica"):
    - same subnet, Firewall is completely disabled in the moment on both systems
    - no clustering
    - i tried several vms, excluded vhds,  tried different initial replication methods, every option ..
    .. nothing helped, every time i click "finish" after setting up the "enable replication"-screen the error-message appears.

    For your second link ("Prerequisites for certificate based deployments"):
    Root-Certificates are created using makecert, copied, imported. Client-certificates (with FQDN) are created as well.
    Certutil shows me the certificates are valid with "Encryption test passed" on both systems.
    Registry changed for allowing the self-certified certificates without Revocation-check.

    There is no difference if i use the GUI from a Win8-Client or using powershell ("Enable-VMReplication ...") directly on any of the
    2 servers, the errormessage is the same. Systems and vms are rebooted several times after all the changes.

    I have no other problems with any VM on any of those 2 systems. I can export and import vms between each other, they run without any
    issue .. just the "Replica" is not working.

    The eventlog has only the errormessage from the first post, no other related event:
    Source: Hyper-V-VMMS
    Event ID: 32000
    Level: Error
    User: System

    Do you need other logs? Can i enable more detailled logging anywhere?

    br, tm

     

    Tuesday, October 23, 2012 8:48 AM
  • Hello,

    i finally solved it, with re-installing and tests after each step while setting up the systems again:

    On both server the proxy-setting was set (to get Microsoft updates, using "netsh winhttp set proxy server.company.com") - just the proxy-server, but no bypass-list, what worked well enough in regards to Microsoft Updates. Apparently HV-Replica (with certificates relying on http/s) uses those proxy-settings to communicate with the Replica-Server but can of course no longer connect directly to the Replica-Server.
    Resetting/Removing the proxy-settings (or adding a bypass-list like "<local>;*.company.com") helped, HV-Replica is working now.

    Looking at the solution it seems obvious now but I would have really appreciated if there was a more descriptive error-message ("could not connect", "HTTP(S) failed" ..)  then just the mysterious "handle is in wrong state" ..

    But anyway, hopefully this helps someone else ..

    br,tm

    • Marked as answer by tzuiop Monday, October 29, 2012 10:24 AM
    Monday, October 29, 2012 10:23 AM
  • Hi Race,

    As per your explanation it seems that all the replica setting has been done properly as your are able to replicate vm.

    As you have confiured the Hyper-V broker you don have any problem to replicate from cluster to standalone hyper-v

    Only existing VM are not able to take part on replication.

    can you please post the properties of the existing virtual machine replica setting / New virtual machine settings ?

    Thanks & Regards

    Ashish Gaur
    Thursday, November 14, 2013 3:54 AM
  • I know this is old, but for the love of everything, thank you... been banging my head on this for days.  I had setup the proxy for Cluster Aware Updating which broke replication.  I added my domain for the bypass-list and all is well.
    Friday, September 21, 2018 6:25 PM