0

I have problem using IIS 7 and SQL Server 2008. When I trying to show my website using IIS as webserver I get the message "[SqlException (0x80131904): Login failed for user..."

When I using the webserver included in Visual Studio 2010 to show same website there is no problem to access the database.

Why is it working with VS2010 webserver but not with IIS?

1
  • Are you using integrated authentication or SQL Server authentication? Commented May 26, 2010 at 18:56

2 Answers 2

1

I will try to guess:

You're using windows authentication to access the SQL SERVER and the user of the site's application pool (if you're not impersonating) doesn't have necessary permissions.

If I'm not wrong, the default application user for application pools on IIS7 is NETWORKSERVICE so 2 valid options would be

  • You give necessary permissions to this user
  • You change the app pool's user to any with necessary permissions
Sign up to request clarification or add additional context in comments.

Comments

0

Add the IIS Group in the SQL SERVER "IIS_WPG" to have access to the DataBase.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.