Label failure

If you are having a problem using Fortress, post a message here.

Moderator: SourceGear

Post Reply
ajj3085
Posts: 228
Joined: Thu Feb 16, 2006 11:39 am

Label failure

Post by ajj3085 » Thu Sep 04, 2008 9:01 am

Hi,

I've been getting this more often lately:

Label error: A database error has occured (FailDBInsert)

Any ideas?

jeremy_sg
Posts: 1821
Joined: Thu Dec 18, 2003 11:39 am
Location: Sourcegear
Contact:

Re: Label failure

Post by jeremy_sg » Thu Sep 04, 2008 10:39 am

Do you have any interesting messages logged in your Vault server log file?
Subscribe to the Fortress/Vault blog

ajj3085
Posts: 228
Joined: Thu Feb 16, 2006 11:39 am

Re: Label failure

Post by ajj3085 » Thu Sep 04, 2008 11:04 am

It looks like the label transaction is getting deadlocked.

Code: Select all

----9/4/2008 8:55:13 AM      client--server.domain(172.18.1.191)
--SSL Enabled	System.Data.SqlClient.SqlException: Transaction (Process ID 81) was deadlocked on lock resources with another process and has been chosen as the deadlock victim. Rerun the transaction.
   at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection)
   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.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString)
   at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async)
   at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, DbAsyncResult result)
   at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe)
   at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
   at VaultServiceSQL.VaultSqlSCC.AddLabel(VaultSqlConn conn, Int32 nRepID, Int32 nUserID, VaultLabelItem vLabel, Int64& nLabelID, Int64& nObjID, String& strExistingRootPath)    at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection)
   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.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString)
   at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async)
   at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, DbAsyncResult result)
   at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe)
   at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
   at VaultServiceSQL.VaultSqlSCC.AddLabel(VaultSqlConn conn, Int32 nRepID, Int32 nUserID, VaultLabelItem vLabel, Int64& nLabelID, Int64& nObjID, String& strExistingRootPath)
----9/4/2008 8:55:13 AM      andyj--meddev.sta.medvt.us(172.18.1.191)
--SSL Enabled	AddLabel returned: FailDBInsert 

jeremy_sg
Posts: 1821
Joined: Thu Dec 18, 2003 11:39 am
Location: Sourcegear
Contact:

Re: Label failure

Post by jeremy_sg » Thu Sep 04, 2008 11:35 am

Which version are you on, and how big is the folder that you're labeling? Also, putting your server log in debug mode will probably help us track down the deadlock the next time that it happens.
Subscribe to the Fortress/Vault blog

ajj3085
Posts: 228
Joined: Thu Feb 16, 2006 11:39 am

Re: Label failure

Post by ajj3085 » Thu Sep 04, 2008 11:41 am

I'm on version 1.1.2.18185, for both client and server.

It's not always the same folder, but one of them has a tree size of 268kb, and needs 536kb of disk space. Seems like a lot of disk space to me... but maybe that includes the bin directories (which aren't in source control)?

jeremy_sg
Posts: 1821
Joined: Thu Dec 18, 2003 11:39 am
Location: Sourcegear
Contact:

Re: Label failure

Post by jeremy_sg » Thu Sep 04, 2008 1:12 pm

268kb is very small (less than a floppy (remember those?)).

Labels would be slow based on the number of files and folders in the label, not the disk size. Can you give me any hints on that? Also, the debug logging will help next time, so I would suggest pro-actively enabling that now.
Subscribe to the Fortress/Vault blog

pdeandc
Posts: 1
Joined: Mon Oct 20, 2008 3:30 pm

Re: Label failure

Post by pdeandc » Mon Oct 20, 2008 4:03 pm

I have a client having this error. How do you turn on debugging to find out how to solve the issue?

Tx,
~pdeandc

jeremy_sg
Posts: 1821
Joined: Thu Dec 18, 2003 11:39 am
Location: Sourcegear
Contact:

Re: Label failure

Post by jeremy_sg » Mon Oct 20, 2008 6:45 pm

For debug information, see the Vault server log file
Subscribe to the Fortress/Vault blog

andyHigson
Posts: 1
Joined: Mon Dec 07, 2009 11:03 am

Re: Label failure

Post by andyHigson » Mon Dec 07, 2009 11:43 am

I am getting the same error. It is on just one folder within my repository. I have managed to capture the error from the log file with debug turned on :-

Code: Select all

----07/12/2009 16:27:50      andyh--ANDREW-H(192.168.0.4)--SSL Disabled	DB: AddLabel started. 
----07/12/2009 16:27:50      andyh--ANDREW-H(192.168.0.4)--SSL Disabled	System.Data.SqlClient.SqlException: Violation of UNIQUE KEY constraint 'unique_tblfsobjectlabelviews_names'. Cannot insert duplicate key in object 'dbo.tblfsobjectlabelviews'.
The statement has been terminated.
   at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection)
   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.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString)
   at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async)
   at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, DbAsyncResult result)
   at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe)
   at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
   at VaultServiceSQL.VaultSqlSCC.AddLabel(VaultSqlConn conn, Int32 nRepID, Int32 nUserID, VaultLabelItem vLabel, Int64& nLabelID, Int64& nObjID, String& strExistingRootPath)    at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection)
   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.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString)
   at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async)
   at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, DbAsyncResult result)
   at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe)
   at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
   at VaultServiceSQL.VaultSqlSCC.AddLabel(VaultSqlConn conn, Int32 nRepID, Int32 nUserID, VaultLabelItem vLabel, Int64& nLabelID, Int64& nObjID, String& strExistingRootPath)
----07/12/2009 16:27:50      andyh--ANDREW-H(192.168.0.4)--SSL Disabled	DB: AddLabel finished. 
----07/12/2009 16:27:50      andyh--ANDREW-H(192.168.0.4)--SSL Disabled	Rolling Back a transaction   at VaultServiceSQL.VaultSqlConn.RollbackTransaction()
   at VaultServiceAPILib.VaultServiceAPI.AddLabel(Int32 nUserID, Int32 nRepID, VaultLabelItem& vLabel)
   at VaultService.VaultService.AddLabel(Int32 nRepID, VaultLabelItem& vLabel)
   at System.RuntimeMethodHandle._InvokeMethodFast(Object target, Object[] arguments, SignatureStruct& sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner)
   at System.RuntimeMethodHandle.InvokeMethodFast(Object target, Object[] arguments, Signature sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner)
   at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, Boolean skipVisibilityChecks)
   at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
   at System.Web.Services.Protocols.LogicalMethodInfo.Invoke(Object target, Object[] values)
   at System.Web.Services.Protocols.WebServiceHandler.Invoke()
   at System.Web.Services.Protocols.WebServiceHandler.CoreProcessRequest()
   at System.Web.Services.Protocols.SyncSessionlessHandler.ProcessRequest(HttpContext context)
   at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
   at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
   at System.Web.HttpApplication.ApplicationStepManager.ResumeSteps(Exception error)
   at System.Web.HttpApplication.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData)
   at System.Web.HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)
   at System.Web.HttpRuntime.ProcessRequestNoDemand(HttpWorkerRequest wr)
   at System.Web.Hosting.ISAPIRuntime.ProcessRequest(IntPtr ecb, Int32 iWRType)
 
----07/12/2009 16:27:50      andyh--ANDREW-H(192.168.0.4)--SSL Disabled	SQL transaction 16609919 successfully rolled back. 
----07/12/2009 16:27:50      andyh--ANDREW-H(192.168.0.4)--SSL Disabled	AddLabel returned: FailDBInsert 
----07/12/2009 16:27:50      andyh--ANDREW-H(192.168.0.4)--SSL Disabled	ASMX: AddLabel finished. 

also i have managed to capture the SQL command from SQL profiler

Code: Select all

declare @p8 bigint
set @p8=199
declare @p9 nvarchar(1024)
set @p9=NULL
declare @p10 bigint
set @p10=4781
declare @p11 smallint
set @p11=5
exec dbo.spaddfsobjectlabel @repid=3,@objverid=24912,@userid=3,@labeldate='2009-12-07 16:37:20:483',@label=N'test_lbl_2134',@fullpath=N'$/Inter-est 5/Client Branch (Vision DVLA & Images)/PartsGUI',@recursive=1,@labelid=@p8 output,@rootpath=@p9 output,@objid=@p10 output,@objectproperties=@p11 output
select @p8, @p9, @p10, @p11
we are using the following versions
[07/12/2009 16:34:01] Version Check: This Fortress client is version 1.1.3.18336
[07/12/2009 16:34:01] Version Check: Your Fortress server is version 1.1.3.18336

The server is using SQL 2005, does anybody know how to resolve this issue?

Thanks,

Andy

lbauer
Posts: 9736
Joined: Tue Dec 16, 2003 1:25 pm
Location: SourceGear

Re: Label failure

Post by lbauer » Tue Dec 08, 2009 12:52 pm

This looks like a database issue. You also email support -- we'll respond offline.
Linda Bauer
SourceGear
Technical Support Manager

Post Reply