Solved

script synchronize logins and permissions between principal and mirror servers

Posted on 2014-12-07
3
91 Views
Last Modified: 2014-12-09
Hello,

I search a script to synchronize logins and permissions between principal and mirror servers.

Thanks

Regards
0
Comment
Question by:bibi92
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 50

Expert Comment

by:Vitor Montalvão
ID: 40486582
The users are already in both databases, right? You just need to create the logins, correct?
You could create a script for the logins in the principal server and run it in the mirrored server and after that just run the following command for each user in the mirrored database:
EXEC sp_change_users_login 'Auto_Fix', 'UserName'
0
 

Author Comment

by:bibi92
ID: 40487609
Thanks but  I search to transfer login or synchronize them
0
 
LVL 50

Accepted Solution

by:
Vitor Montalvão earned 500 total points
ID: 40488414
This MSDN article has a script that do that.
0

Featured Post

Comparison of Amazon Drive, Google Drive, OneDrive

What is Best for Backup: Amazon Drive, Google Drive or MS OneDrive? In this free whitepaper we look at their performance, pricing, and platform availability to help you decide which cloud drive is right for your situation. Download and read the results of our testing for free!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

I have a large data set and a SSIS package. How can I load this file in multi threading?
A project that enables an administrator to perform actions within a user session context not just at the time of login but any time later on day(s) or week(s) later.
This videos aims to give the viewer a basic demonstration of how a user can query current session information by using the SYS_CONTEXT function
Via a live example, show how to shrink a transaction log file down to a reasonable size.

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question