Showing results for 
Search instead for 
Do you mean 
Community Home Request Access Read Blogs Share Your Ideas Search Community View My Settings
Reply
Nickel Contributor
Posts: 58
Registered: ‎05-05-2009

Error Message: DB_SEC_E_AUTH_FAILED

 

We are experiencing problems with a Web SLX installation. It is throwing this error. When the users sees the error, they only need to press the "back" button of the explorer and can continue working.

 

There are only 25 users workings, and the error is consistently at time intervals from 3 to 15 minutes. all the day.

 

Important Information: 

- DB_SEC_E_AUTH_FAILED are comming from different places on the Portal. Please, anybody have information on this? 

- Ok, the form was taking all the SLX licences. I assume, the way i'm making the connection is not the proper way. I have 3 smarthparts that loads when account is in detail mode. What's the better way to connect to the DB? 

- Is there a limit on the number of connections the SLX OLE DB Provider can accept?

 

Please Help!!!

 

The error:


Event code: 3005 

Event message: An unhandled exception has occurred. 

Event time: 4/16/2010 11:07:45 AM 

Event time (UTC): 4/16/2010 4:07:45 PM 

Event ID: 709edac0a24743129afc78c585c88d0f 

Event sequence: 30915 

Event occurrence: 62 

Event detail code: 0 


Application information: 

Application domain: /LM/W3SVC/3/Root/slxclient-1-129158513784375000 

Trust level: Full 

Application Virtual Path: /slxclient 

Application Path: C:\Inetpub\wwwroot\slxclient\ 

Machine name: SERVERCASHFLOW 


Process information: 

Process ID: 3636 

Process name: aspnet_wp.exe 

Account name: SERVERCASHFLOW\ASPNET 


Exception information: 

Exception type: OleDbException 

Exception message: No error message available, result code: DB_SEC_E_AUTH_FAILED(0x80040E4D). 


Request information: 

Request URL: http://192.168.64.133:3333/slxclient/ACCOUNT.ASPX?modeid=list 

Request path: /slxclient/ACCOUNT.ASPX 

User host address: 192.168.35.144 

User: mcalderon 

Is authenticated: True 

Authentication Type: Forms 

Thread account name: SERVERCASHFLOW\ASPNET 


Thread information: 

Thread ID: 14 

Thread account name: SERVERCASHFLOW\ASPNET 

Is impersonating: False 

Stack trace: at System.Data.OleDb.OleDbConnectionInternal..ctor(OleDbConnectionString constr, OleDbConnection connection)

at System.Data.OleDb.OleDbConnectionFactory.CreateConnection(DbConnectionOptions options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningObject)

at System.Data.ProviderBase.DbConnectionFactory.CreateNonPooledConnection(DbConnection owningConnection, DbConnectionPoolGroup poolGroup)

at System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection owningConnection)

at System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory)

at System.Data.OleDb.OleDbConnection.Open()

at System.Web.UI.WebControls.SqlDataSourceView.ExecuteSelect(DataSourceSelectArguments arguments)

at System.Web.UI.WebControls.SqlDataSource.Select(DataSourceSelectArguments arguments)

at SmartParts_Account_AccountControl.Page_PreRender(Object sender, EventArgs e) in c:\Inetpub\wwwroot\slxclient\SmartParts\Account\AccountControl.ascx.cs:line 128

at System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e)

at System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e)

at System.Web.UI.Control.OnPreRender(EventArgs e)

at Sage.Platform.WebPortal.SmartParts.EntityBoundSmartPart.OnPreRender(EventArgs e)

at System.Web.UI.Control.PreRenderRecursiveInternal()

at System.Web.UI.Control.PreRenderRecursiveInternal()

at System.Web.UI.Control.PreRenderRecursiveInternal()

at System.Web.UI.Control.PreRenderRecursiveInternal()

at System.Web.UI.Control.PreRenderRecursiveInternal()

at System.Web.UI.Control.PreRenderRecursiveInternal()

at System.Web.UI.Control.PreRenderRecursiveInternal()

at System.Web.UI.Control.PreRenderRecursiveInternal()

at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

 

===============================================================================================

The code in the page described at AccountControl.ascx.cs line 128 is ok, let me show it:


String constring = service.GetConnection().ConnectionString.ToString();

SqlDataSource dsMyD = new SqlDataSource();

dsMyD.ProviderName = "System.Data.OleDb";

dsMyDataSource.ConnectionString = constring;

string sqlCmp = "SELECT C.CAMPAIGNID,C.CAMPAIGNNAME FROM CAMPAIGN C inner join campaigntarget T on C.CAMPAIGNID=T.CAMPAIGNID INNER JOIN CONTACT O ON 

T.ENTITYID=O.CONTACTID INNER JOIN ACCOUNT A ON O.ACCOUNTID = A.ACCOUNTID INNER JOIN SECCODEJOINS SCC_JO ON (C.TARGETAUDIENCELOCATION=SCC_JO.parentseccodeid) 

INNER JOIN SECRIGHTS SCC_DE ON (SCC_DE.seccodeid= scc_jo.childseccodeid AND scc_de.accessid='" + userService.GetUser().Id.ToString().Trim() + "') WHERE C.STATUS='Active' AND C.CAMPAIGNID<>'Q6UJ9A00T4TA' AND C.CAMPAIGNID<>'Q6UJ9A003IF9' AND (A.ESTADOPROGRAMAR<>'2' OR nvl(A.ESTADOPROGRAMAR,'NUL')='NUL') GROUP BY C.CAMPAIGNID, C.CAMPAIGNNAME";

dsMyD.DataSourceMode = System.Web.UI.WebControls.SqlDataSourceMode.DataReader;

dsMyD.SelectCommand = sqlCmp;

System.Data.OleDb.OleDbDataReader readerc;

readerc = (System.Data.OleDb.OleDbDataReader)dsMyD.Select(DataSourceSelectArguments.Empty); 

if (this.dpCampaign.Items.Count == 0)

{

while (readerc.Read())

{

this.dpCampaign.Items.Add(new ListItem(readerc["CAMPAIGNNAME"].ToString(), readerc["CAMPAIGNID"].ToString()));


}

string strIDs = Request["ZCMPID"];

if (!string.IsNullOrEmpty(strIDs))

{

this.dpCampaign.SelectedValue = strIDs;

}

}

dsMyD.SelectCommand = "SELECT COUNT(T.CAMPAIGNTARGETID) ENESTA FROM CAMPAIGN C inner join campaigntarget T on C.CAMPAIGNID=T.CAMPAIGNID INNER JOIN CONTACT O ON T.ENTITYID=O.CONTACTID INNER JOIN ACCOUNT A ON O.ACCOUNTID = A.ACCOUNTID WHERE C.CAMPAIGNID='" + this.dpCampaign.SelectedValue.ToString() + "'";


readerc = (System.Data.OleDb.OleDbDataReader)dsMyD.Select(DataSourceSelectArguments.Empty); **** LINE 128


while (readerc.Read())

{

this.TextBox1.Text =readerc["ENESTA"].ToString();

}


This works fine, but when there are 10 or more users running the form with the avobe code, the asp start to fail on different lines where the page try to read from the SLX OLEDB Provider.


I think this reader losses its connectionstring between reads but only when more than 1 user is accessing the application.


I changed the code to only call the datasource 1 time and changed the connectionstring assignment to avoid problems with the " caracter:


ds.ConnectionString = service.GetConnectionString().Replace("\"","'").ToString(); 

 

======================================================================== 

 

Bronze Super Contributor
Posts: 129
Registered: ‎06-09-2009

Re: Error Message: DB_SEC_E_AUTH_FAILED

What about making sure you Close and Dispose of your Reader Objects as soon as done with them.

Do the same with any Data related objects, remember the keep non-managed resources, and it may take a while for them to be cleaned up by the GC.

 

Also, I don't believe that there is a limit on connections applied by the provider based on user Licenses, I may be mistaken, but you are hitting a limit somewhere.

 

  Have you checked the number of Open Connections you have on SQL server when this happens?

  Use PerMon and check the size of your Connection Pools.

 

  Use Netstat and see how your connections look as well.

Raul A. Chavez
http://raul.chavez.com
http://www.crmbi.com
Employee
Posts: 191
Registered: ‎03-13-2009

Re: Error Message: DB_SEC_E_AUTH_FAILED

DB_SEC_E_AUTH_FAILED seems to me like an issue associated to the windows user integration, have you by chance associated a slx user to a windows user check box but have not actually linked it to any windows user?

 

Try checking for the 25 user's profiles and their connection to AD

Nickel Elite Contributor
Posts: 81
Registered: ‎04-13-2009

Re: Error Message: DB_SEC_E_AUTH_FAILED

Looking at the code, I suspect that he should be using OleDbConnection, OleDbCommand, ... objects. I am expecting a provider error is occurring since they are using a SQLDataSource.

 

DataTable table = new DataTable();

using(OleDbDataAdapter adapter = new OleDbDataAdapter(query, connectionString)) {

   adapter.Fill(table)

}

 

....

 

Also note that the ConnectionString property on the IDataService service is already as string so the extra .ToString() is unnessacary.

 

Mark

Nickel Contributor
Posts: 58
Registered: ‎05-05-2009

Re: Error Message: DB_SEC_E_AUTH_FAILED

Sorry for bothering you.  Let me explain a little more the situation:

 

Facts:

 

1-We are using SLX 7.2 SP2.

 

2-We are using Named Users.

 

Questions:

 

1-What is the recommended method for doing a custom query to the database, creating a new, or using the connection?

 

2-Is there a limit on the direct connections to the database? 

 

3-Is there a way to log something (not using slxprofiler) to track down connection issues?

 

Anything you can give us to try is deeply welcome.