SQL Server Performance

Database mirroring - Logins

Discussion in 'SQL Server 2005 Database Mirroring' started by priyaram, Jul 17, 2007.

  1. priyaram New Member

    In the database mirroring, once we setup the mirroring the database level logins are created in the mirror server. But for the loging to get access to the databsae they have to be in the server level also.

    when i try to create them @ the server level , it's giving me an error sayin the SID is already in use...

    how about the user setup , in case of database mirroring...
  2. satya Moderator

    http://mssqltips.com/tip.asp?tip1166 fyi.

    Satya SKJ
    Microsoft SQL Server MVP
    Writer, Contributing Editor & Moderator
    http://www.SQL-Server-Performance.Com
    @http://www.askasqlguru.com/

    This posting is provided AS IS with no rights for the sake of knowledge sharing. Knowledge is of two kinds. We know a subject ourselves or we know where we can find information on it.
  3. priyaram New Member

    Sathya,

    If in the principal server , if i am adding any new login means how it'll be added to the mirror server.So that in the case of failover, the newly added login in the principal will have access to the mirrored server database

    Or each time once we create the new login in the princiapl, we have to add that login to the mirror server also.

    Because we are not mirroring the system databases , so if any changes to the login in the principal , how it'll be reflected to the mirror

    thanks
  4. MohammedU New Member

    Yes, check the link Satya provided which has the script...


    MohammedU.
    Microsoft SQL Server MVP
    Moderator
    SQL-Server-Performance.com

    All postings are provided “AS IS” with no warranties for accuracy.
  5. satya Moderator

    DB mirroring is only for user databases and in this case you have to deploy such manual procedure to recreate the logins on mirror server.

    Satya SKJ
    Microsoft SQL Server MVP
    Writer, Contributing Editor & Moderator
    http://www.SQL-Server-Performance.Com
    @http://www.askasqlguru.com/

    This posting is provided AS IS with no rights for the sake of knowledge sharing. Knowledge is of two kinds. We know a subject ourselves or we know where we can find information on it.

Share This Page