locked
SQL timeout expired issue while resolving cases in CRM 2011 RRS feed

  • Question

  • sometimes I am getting SQL Server Timeout issue while resolving cases in CRM 2011.

    calling close method in the Incident pre Plugin. and updating the Incident actual end date

    any help will be apperciated.

    Thursday, December 20, 2012 6:05 PM

Answers

  • Open SQL Server Profiler and check if there is anything blocking and make sure to use no-locks in your query expressions and fetchxmls.
    • Proposed as answer by VSomireddy Tuesday, December 10, 2013 7:01 PM
    • Marked as answer by Venkat_Reddy Tuesday, December 10, 2013 7:02 PM
    Tuesday, December 10, 2013 5:46 PM

All replies

  • You could try increasing timeout keys on the CRM server

    a. Click Start, click Run, type regedit, and then click OK.

    b. Locate the following registry subkey:

    HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSCRM

    c. Right-click MSCRM, point to New, and then click DWORD Value to create a new DWORD value.

    d. Rename the DWORD value to the following value:

    OLEDBTimeout

    e. Right-click the DWORD value, and then click Modify.

    f. In the Edit DWORD Value dialog box, click Decimal in the Base option, type 86400 in the Value data box,  and then click OK.

    g. Right-click MSCRM, point to New, and then click DWORD Value to create a new DWORD value.

    h. Rename the DWORD value to the following value:

    ExtendedTimeout

    i. Right-click the DWORD value, and then click Modify.

    j. In the Edit DWORD Value dialog box,click Decimal in the Base option, type 1,000,000 in the Value data box, and then click OK.


    Jackie Chen, Microsoft Online Community Support. Please remember to click “Mark as Answer” on the post that helps you. This posting is provided "AS IS" with no warranties, and confers no rights.

    Wednesday, January 2, 2013 2:37 AM
  • Thanks for your answer.

    If i increase time out as you told, users need to wait for sometime till it gets updated into the database.

    looks like If the database is updating any of the tables that the plugin is touching you will get that "Generic SQL Error" or "SQL timeout expired" which is a locking issue. Plugins lock sql.

    Please let me know if you have any idea what could be the route cause for this kind of exceptions.

    Wednesday, January 2, 2013 11:40 PM
  • The root cause of plugins locking data is that plugins execute in database transactions, and reading/writing data in a database causes locking in the database. If you are seeing locking issues you may need to revisit your logic to make sure your business logic is executing in an efficient order from a DB perspective, and that the database is tuned for the type of queries/updates you may be performing...especially watch out for any circular logic that could cause nested execution of multiple plugins.
    Thursday, January 3, 2013 4:18 AM
  • We ran into this recently and I found that IE 10 with no plugins does the same.

    Just a FYI..


    John

    Wednesday, November 6, 2013 3:34 PM
  • Open SQL Server Profiler and check if there is anything blocking and make sure to use no-locks in your query expressions and fetchxmls.
    • Proposed as answer by VSomireddy Tuesday, December 10, 2013 7:01 PM
    • Marked as answer by Venkat_Reddy Tuesday, December 10, 2013 7:02 PM
    Tuesday, December 10, 2013 5:46 PM