Friday, March 30, 2012

Login failed for user NT AUTHORITY\LOCAL SERVICE

I just installed the Issue Tracker using .net 1.1 (on my computer). When I try to log in via the login page, I get:

Login failed for user 'NT AUTHORITY\LOCAL SERVICE'

Here is my stack trace info:

SqlException: Login failed for user 'NT AUTHORITY\LOCAL SERVICE'.]
System.Data.SqlClient.ConnectionPool.CreateConnection() +402
System.Data.SqlClient.ConnectionPool.UserCreateRequest() +151
System.Data.SqlClient.ConnectionPool.GetConnection(Boolean& isInTransaction) +386
System.Data.SqlClient.SqlConnectionPoolManager.GetPooledConnection(SqlConnectionString options, Boolean& isInTransaction) +372
System.Data.SqlClient.SqlConnection.Open() +384
ASPNET.StarterKit.IssueTracker.DataAccessLayer.SQLDataAccessLayer.ExecuteScalarCmd(SqlCommand sqlCmd) +129
ASPNET.StarterKit.IssueTracker.DataAccessLayer.SQLDataAccessLayer.Authenticate(String username, String password) +184
ASPNET.StarterKit.IssueTracker.BusinessLogicLayer.ITUser.Authenticate(String username, String password) +44
ASPNET.StarterKit.IssueTracker.DesktopDefault.Login(Object s, EventArgs e) +84
System.Web.UI.WebControls.Button.OnClick(EventArgs e) +108
System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +57
System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +18
System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +33
System.Web.UI.Page.ProcessRequestMain() +1292

I have added everyone, asp.net, local service, network service - all full control on the entire folder. Restarted IIS - still can't log in. Please help.

Hi, look at the exception you'll find it is from SQL. So you have to add proper permissions in SQL for the account rather than give control on the folder. Please open SQL Server Management Studio (Enterprise Manager) and go to the SQL instance which you're trying to connect, and explore Security->Logins->right click choose 'New Login'-> choose Windows Authentication and type the Windows account name. Remember to give sufficient permissions to the new added login.|||Thanks for the info. That fixed my issue.|||

What exactly should those permissions be, Read-only, owner, read/write.. what?

Thanks

|||

thelane:

What exactly should those permissions be, Read-only, owner, read/write.. what?

Thanks

The permissions I mean here is permissions in SQL, such as SELECT/INSERT/UPDATE on tables, CREATE DATABASES, EXECUTE stored procedures, and so onSmile You can take a look at this link:

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/adminsql/ad_security_94dv.asp

No comments:

Post a Comment