Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Lee Nightingale 2 posts 72 karma points
    Oct 06, 2020 @ 11:12
    Lee Nightingale
    0

    SQL lock request timeout

    Hi We are currently using Umbraco for our self service portal.

    We are currently experience lots of sql lock request errors :

    System.Data.SqlClient.SqlException (0x80131904): Lock request time out period exceeded

    Users have to register and sign in to use the site so we have a lot of read/write to Members.

    I have read various posts and we have added the following line to config and upgraded Umbraco to 8.6.5

    Umbraco.Core.MainDom.Lock = SqlMainDomLock

    Anyone sugestions?

    Cheers

  • lucuma 261 posts 563 karma points
    Nov 18, 2020 @ 15:47
    lucuma
    0

    Umbraco 8.9.

    I am seeing tons of "Lock request time out period exceeded The statement has been terminated." when using Azure Web Apps and trying to publish descendants. There are a lot of publish issues with Umbraco when trying to publish more than one thing even with all the recommended Azure Web App settings.

  • Simon steed 366 posts 677 karma points
    Jan 28, 2021 @ 11:54
    Simon steed
    0

    I've been getting this more and more since 8.9 and it's progressively getting worse (even after upgrading to 8.11 today). Setup is Dedicated server running SQL Server 2017 (so no azure).

    Always happens after doing a few publish events (updating content) - only way to fix it is to restart SQL Server which is far from ideal, god knows how i'd do this if it was Azure.

    Log entry:

    2021-01-28 11:49:02,112 [P15776/D2/T17] ERROR Umbraco.Web.Editors.ContentController - Unhandled controller exception occurred for request 'http://site.com.local/umbraco/backoffice/UmbracoApi/Content/PostSave' System.Data.SqlClient.SqlException (0x80131904): Lock request time out period exceeded. The statement has been terminated. at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action1 wrapCloseInAction) at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose) at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady) at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString, Boolean isInternal, Boolean forDescribeParameterEncryption, Boolean shouldCacheForAlwaysEncrypted) at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite, Boolean inRetry, SqlDataReader ds, Boolean describeParameterEncryptionRequest) at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletionSource1 completion, Int32 timeout, Task& task, Boolean& usedCache, Boolean asyncWrite, Boolean inRetry) at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(TaskCompletionSource1 completion, String methodName, Boolean sendToPipe, Int32 timeout, Boolean& usedCache, Boolean asyncWrite, Boolean inRetry) at System.Data.SqlClient.SqlCommand.ExecuteNonQuery() at Umbraco.Core.Persistence.FaultHandling.RetryPolicy.ExecuteAction[TResult](Func1 func) in D:\a\1\s\src\Umbraco.Core\Persistence\FaultHandling\RetryPolicy.cs:line 172 at NPoco.Database.ExecuteNonQueryHelper(DbCommand cmd) at NPoco.Database.Execute(String sql, CommandType commandType, Object[] args) at Umbraco.Core.Persistence.SqlSyntax.SqlServerSyntaxProvider.WriteLock(IDatabase db, TimeSpan timeout, Int32[] lockIds) in D:\a\1\s\src\Umbraco.Core\Persistence\SqlSyntax\SqlServerSyntaxProvider.cs:line 272 at Umbraco.Core.Services.Implement.ContentService.Save(IContent content, Int32 userId, Boolean raiseEvents) in D:\a\1\s\src\Umbraco.Core\Services\Implement\ContentService.cs:line 782 at Umbraco.Web.Editors.ContentController.SaveAndNotify(ContentItemSave contentItem, Func2 saveMethod, Int32 variantCount, Dictionary2 notifications, SimpleNotificationModel globalNotifications, String invariantSavedLocalizationKey, String variantSavedLocalizationKey, String cultureForInvariantErrors, Boolean& wasCancelled) in D:\a\1\s\src\Umbraco.Web\Editors\ContentController.cs:line 924 at Umbraco.Web.Editors.ContentController.PostSaveInternal(ContentItemSave contentItem, Func2 saveMethod, Func2 mapToDisplay) in D:\a\1\s\src\Umbraco.Web\Editors\ContentController.cs:line 712 at lambdamethod(Closure , Object , Object[] ) at System.Web.Http.Controllers.ReflectedHttpActionDescriptor.ActionExecutor.<>cDisplayClass62.

  • Tim Mather 26 posts 118 karma points
    Apr 16, 2021 @ 09:30
    Tim Mather
    0

    @Umbraco people, what is happening with this, we have started seeing this happening on a number of sites using 8.6+ Essentially it is like the database is in single user mode, so if one person is deleting a node no one can do anything else. This needs sorted as sites are going live.

  • Tim Mather 26 posts 118 karma points
    29 days ago
    Tim Mather
    0

    @Umbraco people this needs looked at asap, we are seeing several clients with this problem that are not on azure and are running 8.6+ we have upgrade to 8.12 but that has not resolved the problem.

    Similar problems: https://our.umbraco.com/forum/using-umbraco-and-getting-started/102325-lock-request-time-out-period-exceeded

  • Tim Mather 26 posts 118 karma points
    29 days ago
  • Simon steed 366 posts 677 karma points
    29 days ago
    Simon steed
    1

    Have you reviewed the fix that was applied and configured the timeout value?

    https://github.com/umbraco/Umbraco-CMS/pull/9744

  • Tim Mather 26 posts 118 karma points
    29 days ago
    Tim Mather
    0

    Thanks for pointing that out Simon. Looking at that I have added the following to our web.config:

    <add key="Umbraco.Core.SqlWriteLockTimeOut" value="5000" />
    

    Hopefully that will help.

  • Simon steed 366 posts 677 karma points
    29 days ago
    Simon steed
    0

    Cool - let us know how you get on. Since I originally reported it, i've had very few, if any recurrences of it, even though i'm still on 8.11.1 which is really bizarre!

  • Tim Mather 26 posts 118 karma points
    29 days ago
    Tim Mather
    0

    OK, we have already seen some odd results with timeout set at 5000. At one point all content on the front end of the site dissappeared and only re-appeared once republished or memory cache was reloaded.

  • Tim Mather 26 posts 118 karma points
    29 days ago
    Tim Mather
    0

    Problem has shifted some what but still recieving errors, customers reporting "impossible to use".

  • Simon steed 366 posts 677 karma points
    29 days ago
    Simon steed
    0

    What is the setup of the site? Load balanced, multi server, db, azure etc?

  • Lee Nightingale 2 posts 72 karma points
    29 days ago
    Lee Nightingale
    0

    I have tried adding the writelocktimeout line in to config in the last hour. I will let you know if it makes any difference for me.

  • Tim Mather 26 posts 118 karma points
    29 days ago
    Tim Mather
    0

    Super simple, not load balanced, single server (same server for db and iis).

  • Simon steed 366 posts 677 karma points
    29 days ago
    Simon steed
    0

    Not sure what to suggest tbh, can't get simpler than that. In my case, I'm running IIS on one server, Azure for DB and development is on another machine but shared db.

    Could be worth re-opening that github issue and tagging in Shannon to see if he can shed any light on it

  • Tim Mather 26 posts 118 karma points
    29 days ago
    Tim Mather
    0

    Thanks, the problem isn't the same, we are seeing allsorts now, all seem related to caching, we have regenerated in memory cache 3 times now as we started seeing content dissappear without warning. I will re-open the GitHub issue.

Please Sign in or register to post replies

Write your reply to:

Draft