Failover on 2 servers AlwaysOn AG with read-only secondary replica

  • Hi there!

    What happens when an automatic failover occurs, in a two server AlwaysOn Availability Group configuration, where the secondary replica is configured as read-only?

    Will it only allow read-only connections, or will it become read-write and can accept INSERT, UPDATES and DELETES when assigned the new role as Primary?

    Is it correct that adding a third server/node, that just acts as passive and should be used for automatic failover, to support true HADR, would NOT need another license .. and that licenses would only be required for the previous Primary and Secondary (Read-Only) replicas?

    Thanks,

    gord

  • GordonLiddy (3/28/2014)


    Hi there!

    What happens when an automatic failover occurs, in a two server AlwaysOn Availability Group configuration where the secondary replica is configured as read-only?

    If both replicas are configured for synchronous mode with automatic failover, the Primary role will transfer during a failure as usual.

    The ReadOnly clause defines the secondary role mode only.

    GordonLiddy (3/28/2014)


    Will it only allow read-only connections, or will it become read-write and can accept INSERT, UPDATES and DELETES when assigned the new role as Primary?

    Depending on how you set the replica in the AO group properties it will either become Primary Read\Write or Primary All connections, which did you configure?

    GordonLiddy (3/28/2014)


    Is it correct that adding a third server/node, that just acts as passive and should be used for automatic failover, to support true HADR, would NOT need another license .. and that licenses would only be required for the previous Primary and Secondary (Read-Only) replicas?

    Thanks,

    gord

    According to the SQL2012 license guide you may run a passive AlwaysOn secondary replica, but if the secondary starts to perform any AlwaysOn offload tasks such as readonly routed connections or backup operations you must license it accordingly.

    There are options you may specify on the replica to ensure that it does not receive any read connections or backup operations

    -----------------------------------------------------------------------------------------------------------

    "Ya can't make an omelette without breaking just a few eggs" 😉

  • Seems like our future configuration (which we haven't set up yet) will work just fine, if we used RO secondary replica with the primary configured for Read/write.

    Thank you very much for your answer and have a nice day!

  • GordonLiddy (3/28/2014)


    with the primary configured for Read/write.

    This means that connections with the application intent set to ReadOnly will not be granted in the Primary role

    -----------------------------------------------------------------------------------------------------------

    "Ya can't make an omelette without breaking just a few eggs" 😉

Viewing 4 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply