Database mirroring test

  • Hi All,

    I was reading about database mirroring in sql server 2008.

    let say i have configure database mirroring, now i want to test my front end application with my database.

    my application get configured with database with some ini and xml files.

    all my setting directs to primary database server, now if it gets down due to any reason, how could my application get database on FAIL OVER ??

    can you please help me out here.

    do i have to make changes in my ini and xml files ??

  • I am not a developer, however, I understand that you need to provide the name of your mirror instance in your configuration file. If you are connection with ADO.NET, I think it will take the failover instance (mirror instance) name in the configuration file.

    Check in Client-side Redirect in the following link .

    Hope, this may help.

    Thanks & Regards,
    Sudeepta.
    http://twitter.com/skganguly

  • You enter the mirror server in the connection string.

    Data Source=myServerAddress;Failover Partner=myMirrorServerAddress;Initial Catalog=myDataBase;Integrated Security=True;

  • If u want ur Application to be redirected automatically onto the Failover Database, Google it... There r some pseudo codes available... it works like.. it checks the connectivity of the Application to the database.. if the database is not available.. it try connecting to the Failover database... Although u have to mention ur Failover database in that pseudo code...

  • thanks for your interest.

    well, guys we do connection with database using ODBC Named DSN.

    now Information file (ini) have information like this

    CustomInit=Provider=MSDASQL; Driver={SQL Server}; Server=(local); Database=Ctrack; UID=fawwad; PWD=****;

    should i add

    Data Source=myServerAddress;Failover Partner=myMirrorServerAddress;Initial Catalog=myDataBase;Integrated Security=True;

    now tell me how can i use the said string in my ini file.

  • Each item in the connection string is a separate entry. You just add the failover partner part.

    The Integrated Security clause is an either/or with the uid/pwd section.

  • ok i will try adding failover patner section.

Viewing 7 posts - 1 through 6 (of 6 total)

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