Database connection error on installation

Topics: User Forum
Aug 19, 2006 at 12:57 AM
After installation and attempting to configure SLK I get the "...Anonymous.." logon failure. The Sharepoint site is set for windows authentication and I'm wondering why SLK is attempting to create a database using anonymous logon. Any information would be appreciated.
Aug 21, 2006 at 4:30 PM
A few questions to help figure this out:

Does this occur while going through the GettingStarted guide? What is the full error message and is the error displayed on the SLK configuration page? Also, if any information is written to the server event log when the error occurs, can you post that?

Thanks,
Mark
Aug 22, 2006 at 7:38 PM
I get a timeout attempting to connect to SQL server. I imagine that it is due to running SQL Express, yet I have not found where to change the connection string to use SQL Express.

Aug 23, 2006 at 12:58 AM
Here's the errors and entry into the Application Event Log: This occurs on the
Configure Sharepoint Learning Kit page.

1. New SLK Settings File: - click to download default SLK Settings file used in new installations -

ERROR The file '/_admin/SharepointLearningKit/DownloadSettings.aspx' does not exist

When click OK the following error displays:

Login failed for user 'NT AUTHORITY\ANONYMOUS LOGON'.

EVENT APPLICATION LOG ENTRY:

SharePoint Learning Kit Error

System.Data.SqlClient.SqlException: Login failed for user 'NT AUTHORITY\ANONYMOUS LOGON'.
at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection)
at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj)
at System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj)
at System.Data.SqlClient.SqlInternalConnectionTds.CompleteLogin(Boolean enlistOK)
at System.Data.SqlClient.SqlInternalConnectionTds.OpenLoginEnlist(SqlConnection owningObject, SqlConnectionString connectionOptions, String newPassword, Boolean redirectedUserInstance)
at System.Data.SqlClient.SqlInternalConnectionTds..ctor(DbConnectionPoolIdentity identity, SqlConnectionString connectionOptions, Object providerInfo, String newPassword, SqlConnection owningObject, Boolean redirectedUserInstance)
at System.Data.SqlClient.SqlConnectionFactory.CreateConnection(DbConnectionOptions options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningConnection)
at System.Data.ProviderBase.DbConnectionFactory.CreatePooledConnection(DbConnection owningConnection, DbConnectionPool pool, DbConnectionOptions options)
at System.Data.ProviderBase.DbConnectionPool.CreateObject(DbConnection owningObject)
at System.Data.ProviderBase.DbConnectionPool.UserCreateRequest(DbConnection owningObject)
at System.Data.ProviderBase.DbConnectionPool.GetConnection(DbConnection owningObject)
at System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection owningConnection)
at System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory)
at System.Data.SqlClient.SqlConnection.Open()
at Microsoft.SharePointLearningKit.Administration.SaveConfiguration(Guid spSiteGuid, String databaseServer, String databaseName, String schemaToCreateDatabase, String instructorPermission, String learnerPermission, Boolean createPermissions, String settingsFileContents, String defaultSettingsFileContents)
at Microsoft.SharePointLearningKit.AdminPages.ConfigurePage.BtnOk_Click(Object sender, EventArgs e)
Aug 24, 2006 at 2:34 AM
KentWA:

Are you getting a timeout when following the GettingStarted doc and installing SQL rather than SQL Express? Can you describe your server setup a bit more? We have not tested with SQLExpress and I’m not sure if anyone in the community is successfully running SLK with a SQLExpress database. SLK does not store the connection string. We store the server name and database name and create the connection string on the fly.

dslaby:

SLK Settings Download:
The download link isn’t implemented yet, but uploading a new SLK settings file does work. You can get the default SLK settings file from the SDK download (<SDK Directory>\SLK\SlkSettings.xml). http://www.codeplex.com/Project/DisplayThread.aspx?ProjectName=SLK&ForumId=189&ThreadId=451

Login failed for user ‘NT AUTHORITY\ANONYMOUS LOGON’:
Can you describe a bit more about your server setup and whether it deviates at all from the GettingStarted doc? It would help to know a bit more about the conditions of your setup. For example, how many servers do you have; what is the organization of the servers; is everything using integrated Windows authentication?

The following info includes a bit of guesswork because there hasn't been much testing beyond the GettingStarted setup, but it may be helpful in debugging your situation.

If you are accessing central administration pages on a machine that is not the server, you may want to try configuring on the server. You may be running into a “double hop” issue, see http://www.mcse.ms/archive85-2004-11-1246790.html and http://blogs.msdn.com/nunos/archive/2004/03/12/88468.aspx.

When creating the SLK database during configuration, the current user must have a Windows account and that Windows account needs access to SQL. SLK uses the Windows account that the page is running under. If you have a Windows account, and SharePoint is impersonating the account, then that account is used. If, for some reason, SharePoint isn't impersonating the account, then an anonymous account is used. If there's a "double hop" issue, then an anonymous account is used (since the "real" account can't be given to SQL Server).

-Mark
Aug 24, 2006 at 5:31 PM
KentWA:

I just installed SQLExpress on my server to run a quick test and got configuration to work by specifying the database instance name in the database server field of the configuration form.

I think typically the SQLExpress instance is named SQLEXPRESS, so try the following steps:

1. Go to the Configure SharePoint Learning Kit page.
2. Select the site collection you want to configure.
3. In the Database server field specify <server name>\SQLEXPRESS
4. Set the database name and make sure Create a new database is checked.
5. Click OK to configure.

Hope this helps,
Mark
Aug 25, 2006 at 5:31 PM
I guess I had left out some important info. I was trying to use the BasicWebPlayer in the SDK on my local machine. My work around was to use SQL Server Studio to execute the SQL script rather than use the batch file. I then set the Connection String in Web.Config for my install of SQL Express.

Thanks,
Kent
Aug 28, 2006 at 7:36 PM
Login failed for user ‘NT AUTHORITY\ANONYMOUS LOGON’:
Can you describe a bit more about your server setup and whether it deviates at all from the GettingStarted doc? It would help to know a bit more about the conditions of your setup. For example, how many servers do you have; what is the organization of the servers; is everything using integrated Windows authentication?

We are using a server farm with the application on a Windows 2003R2 and the database in a SQL 2005 server on Windows 2003 R2.

When creating the SLK database during configuration, the current user must have a Windows account and that Windows account needs access to SQL. SLK uses the Windows account that the page is running under. If you have a Windows account, and SharePoint is impersonating the account, then that account is used. If, for some reason, SharePoint isn't impersonating the account, then an anonymous account is used. If there's a "double hop" issue, then an anonymous account is used (since the "real" account can't be given to SQL Server).

If we are using a SQL on a separate server, will this cause the double-hop? We don't have the problem with SPS 2003. Do we need to configure for Kerberos?

Thanks. Dan

Aug 31, 2006 at 9:44 PM
Sorry for the delayed response...

I'm not sure if you are accessing Central Admin from a browser on a machine that is separate from the farm that would be a double hop. (Machine1 -> FE Server1 -> SQL Server). I haven't setup a farm myself yet. I know Rob has been working with a small farm, so I will check with him to see if he can post any advice for getting this up and running.

-Mark
Sep 1, 2006 at 3:50 PM
The Central Admin is on the same machine as the Office 2007 server: <Office>-><SQL> which shouldn't give us the double hop. Do you know of any issues with changing NTLM to Kerberos in Office 2007? We are using Windows 2003 R2 domain controller. Thanks.
Sep 11, 2006 at 11:31 AM
I am to having the same issue there are three servers sql,sp2007 and ad/exchg. I am testing a production deployment that we have started to develop for a customer.

If logged into the sp2007 machine under domain account keep getting this error when trying to configure slk -

"Login failed for user 'NT AUTHORITY\ANONYMOUS LOGON'."

we are using a small server farm....

can you help me at all
Sep 12, 2006 at 11:33 PM
Just wanted to let you know I haven’t forgotten about this thread. I’m checking into our server farm test plans to see if we can accelerate some testing and/or if we can test your specific configurations. If you make any progress in investigating/debugging yourself, let us know.
Sep 20, 2006 at 1:14 PM
I am also getting this error with both CTP2 and CTP3.
The CA is on Server A (Win2003) and SQL2005 is on Server B (Win2003).

I have tried creating a database manually in SQL but this doesn't work either.

Is it worth installing MOSS on server B so I can run the CA from the same server as SQL?

Hope this can be resolved for all us farmers!

Thanks

Mark
Oct 5, 2006 at 4:07 PM
Hi,
Just thought it would be worth mentioning that I have overcome this issue...
I granted ANONYMOUS_LOGON the same rights in SQL as my main MOSS account. The configure then worked fine.
Afterwards, I used spchangedbowner to set the owner back to my main MOSS account, and removed ANONYMOUSLOGON from the login list.

Now I have another problem.... but thats for another thread!

Mark