how to failback using database mirroring

  • We have database mirror configured between source and destination SQL 2008 servers with no safety and no witness.

    Suddenly if primary server is intentionally shutdown or it goes down, I think only option we have is to manually failover to destination server by running below command.

    ALTER DATABASE <databasename> SET PARTNER FORCE_SERVICE_ALLOW_DATA_LOSS

    What would happen to mirror status if primary (old source) server comes online? Will it become the destination mirror automatically and will it start receiving transactions from current primary (old destination)? OR do we lose all the changes that happened after failover?

    Is there any way to failback to original primary (source) and reversing the direction of mirror so that source will start replicating data to target without rebuilding mirror.

    We are fine to lose the changes that happened during failover.

  • praveen_vejandla (10/16/2010)


    We have database mirror configured between source and destination SQL 2008 servers with no safety and no witness.

    Suddenly if primary server is intentionally shutdown or it goes down, I think only option we have is to manually failover to destination server by running below command.

    ALTER DATABASE <databasename> SET PARTNER FORCE_SERVICE_ALLOW_DATA_LOSS

    What would happen to mirror status if primary (old source) server comes online? Will it become the destination mirror automatically and will it start receiving transactions from current primary (old destination)? OR do we lose all the changes that happened after failover?

    Is there any way to failback to original primary (source) and reversing the direction of mirror so that source will start replicating data to target without rebuilding mirror.

    We are fine to lose the changes that happened during failover.

    With your present configuration, if primary server goes down, you simply need to run the following:

    ALTER DATABASE dbname SET PARTNER OFF;

    RESTORE DATABASE dbname WITH RECOVERY;

    If you want the primary (old source) server to assume mirror status when it comes online, you will need to configure a witness server and set mirroring to high safety mode.

    __________________________________________________________________________________
    SQL Server 2016 Columnstore Index Enhancements - System Views for Disk-Based Tables[/url]
    Persisting SQL Server Index-Usage Statistics with MERGE[/url]
    Turbocharge Your Database Maintenance With Service Broker: Part 2[/url]

  • Thanks for the reply. Here is what we want to do.

    We want to failover to mirror server and then run applications against mirror server for 2-3 hours

    and failback to original server.

    Most important thing is we want to ignore the changes happened on mirror server for 2-3 hours

    but we want the mirror to be intact.

    Is it possible to do such failover, failback testing ignoring the changes after failover and before failback without re-establishing the mirror?

    Thanks.

  • praveen_vejandla (10/28/2010)


    Thanks for the reply. Here is what we want to do.

    We want to failover to mirror server and then run applications against mirror server for 2-3 hours

    and failback to original server.

    Most important thing is we want to ignore the changes happened on mirror server for 2-3 hours

    but we want the mirror to be intact.

    Is it possible to do such failover, failback testing ignoring the changes after failover and before failback without re-establishing the mirror?

    Thanks.

    That's not possible, you will need to re-establish the mirroring session in that case.

    __________________________________________________________________________________
    SQL Server 2016 Columnstore Index Enhancements - System Views for Disk-Based Tables[/url]
    Persisting SQL Server Index-Usage Statistics with MERGE[/url]
    Turbocharge Your Database Maintenance With Service Broker: Part 2[/url]

  • Hi,

    In your case you have to reconfigure mirroring.

    Ram
    MSSQL DBA

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

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