Friday, February 24, 2012

Login problem after restoring DB

Dear Masters;

I have a classical aspnetdb Login DB; When I backup the DB and make some changes and then restore again; users can't login anymore...

I can see this is good for security but what should I do to do it in a propar way?

Thanks...

Hi Kaan,

In the SQL Server, the logins are not contained in the database. So when you backup the DB, you just backup the users.

However the mapping from a login to user is lost. This is by design. In this case, you have to re-map the logins and users after restoring.

HTH. If this does not answer your question, please feel free to mark the post as Not Answered and we will look into it again. Thanks!

|||

Hi Kevin,

Thank you very much this is actually the answer:) but also a trigger of another question:) How can I re-map the logins?Embarrassed

Thanks...

|||

Hi Kaan,

Here are the steps for User Mapping.

1. In the Management Studio, Open Security/Logins and double click on a login to open the Login Properties dialog box.
2. Select User Mapping from the left tree, and you will see mapping on the right.

|||

Hi Kevin,

Thank you very much... Sorry I'm too lamerEmbarrassed

I've seen that my database's mapping check box was unchecked; so re-mapping should be simply checking it:)

I think it'll work or at least I'll dicover..

Thanks a lot again.

|||

Q: "I have a classical aspnetdb Login DB; When I backup the DB and make some changes and then restore again; users can't login anymore..."

A: "In the SQL Server, the logins are not contained in the database. So when you backup the DB, you just backup the users.

However the mapping from a login to user is lost. This is by design. In this case, you have to re-map the logins and users after restoring.

Here are the steps for User Mapping.

1. In the Management Studio, Open Security/Logins and double click on a login to open the Login Properties dialog box.
2. Select User Mapping from the left tree, and you will see mapping on the right." (Kevin Yu)

No comments:

Post a Comment