More in this section

Forums / Set-up & Installation / Login Failed for ASPNET. What Should I Look for?

Login Failed for ASPNET. What Should I Look for?

3 posts, 0 answered
  1. Jeff
    Jeff avatar
    124 posts
    05 Aug 2007
    16 May 2008
    Link to this post
    I'm evaluating the Standard Edition and, after lots of struggle, got a blank site up and running. Suddenly, I'm getting the following error:

    Cannot open user default database. Login failed.
    Login failed for user '57CHEVY\ASPNET'.

    I'm using SQL Server 2005 Express. I played around a lot in Management Studio to get this working in the first place. I'm not sure how I managed to break it.

    Here's what my Sitefinity DB looks like:

      *  Using default connection string in web.config:
    <add name="Sitefinity" connectionString="Data Source=.\SQLExpress;Integrated Security=True;User Instance=True;AttachDBFilename=|DataDirectory|Sitefinity.mdf" providerName="System.Data.SqlClient" />

      *  Owner is ASPNET user (Windows XP/IIS 5)
      *  Created ASPNET login (Windows Authentication) with Sitefinity DB as default
      *  Checked all server roles for ASPNET login
      *  Mapped ASPNET user to Sitefinity DB with dbo as user

    Has anyone encountered this? Is there anything else I should look for?


    Exceptions and stack traces:

    [SqlException (0x80131904): Cannot open user default database. Login failed.
    Login failed for user '57CHEVY\ASPNET'.]
       Nolics.ORMapper.DataProviders.SQLDataProvider.Open() +121
       Telerik.DataAccess.NolicsHelper.SetConnection(String connectionName, String providerName) +528
       Telerik.Cms.Data.DefaultProvider.Initialize(String name, NameValueCollection config) +231
       Telerik.ManagerBase`1.InstantiateProvider(ProviderSettings providerSettings, Type providerType) +657
       Telerik.ManagerBase`1.InstantiateProvider(ProviderSettings providerSettings) +102
       Telerik.ManagerBase`1.SetProvider(String providerName) +206
       Telerik.ManagerBase`1..ctor(String providerName) +87
       Telerik.ManagerBase`1..ctor() +11
       Telerik.Cms.CmsWorkflowService..ctor() +23
       Telerik.Cms.CmsWorkflowService..cctor() +20

    [TypeInitializationException: The type initializer for 'Telerik.Cms.CmsWorkflowService' threw an exception.]
       Telerik.Cms.CmsWorkflowService.Initialize() +0
       Telerik.Cms.CmsManager.OnInitialized() +5
       Telerik.ManagerBase`1.Initialize() +455
       Telerik.ManagerBase`1..ctor(String providerName) +18
       Telerik.ManagerBase`1..ctor() +11
       Telerik.Cms.CmsManager..ctor() +5
       Telerik.Cms.Web.UrlHelper..cctor() +687

    [TypeInitializationException: The type initializer for 'Telerik.Cms.Web.UrlHelper' threw an exception.]
       Telerik.Cms.Web.CmsHttpModule.Init(HttpApplication context) +101
       System.Web.HttpApplication.InitModulesCommon() +66
       System.Web.HttpApplication.InitInternal(HttpContext context, HttpApplicationState state, MethodInfo[] handlers) +1006
       System.Web.HttpApplicationFactory.GetNormalApplicationInstance(HttpContext context) +259
       System.Web.HttpApplicationFactory.GetApplicationInstance(HttpContext context) +114
       System.Web.HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr) +350

  2. Nikifor
    Nikifor avatar
    232 posts
    18 May 2013
    17 May 2008
    Link to this post
    Hello Jeff,

    Most probably the issue is provoked by the fact that the ASPNET account does not have the popper permissions for the projects database. Sometimes they are not inherited correctly and are causing this problem. We would suggest you to double-check whether the 57CHEVY\ASPNET account has full permissions for the ~/Sitefinity/WebSites/YourProject/App_Data/Sitefinity_log.ldf  and ~/Sitefinity/WebSites/YourProject/App_Data/Sitefinity.mdf files.

    Another possible explanation of the problem could be that it occurs when running the SQL Management Studio and trying to login in your project simultaneously. The SQL Express database has a limitation of the simultaneous connections which would result in the received error. It could have only one connection at a time, which means that while accessing the Web site the connection has been already used by the SQL Management Studio.
    Hope this helps.

    Best wishes,
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  3. Jeff
    Jeff avatar
    124 posts
    05 Aug 2007
    17 May 2008
    Link to this post
    Thanks Nikifor. You're first suggestion did the trick.

    I gave the ASPNET user full control of the DB files, restarted IIS and I'm back in business!

    I also was not aware of the SQL Express limitation, so thanks for that tip as well.
Register for webinar
3 posts, 0 answered