Get new DBTS for database <DBName> with physical db name <DBName> fails with too many retries


  • After migrating our environnement to SQL Server 2016 this message started to appears in our SQL event Log with associated error in our application. It occurs during night when Batch processing data occurs heavily. 

    I understand that DBTS is related to Timestamp generation. We are using a rowversion column in all our tables to identify data modifcations through the day. 

    Our system is running on SQL Server 2016 SP1 running on Windows Server 2012 R2.

    This problem never happens when we were in SQL Server 2008 R2.

    Any hint?

    Friday, April 21, 2017 3:30 PM

All replies

  • Could be server having resource contention during batch processing occurs - worth to start SQL server traces to see what queries were causing this and collect perfmon counters for resource having contention

    Friday, April 21, 2017 3:41 PM
  • Hi RamJaddus,

    First, thanks for your help on this issue. You're right, resource utilization are little high, but this has never caused any issue before and the load is exactly the same as when we were running on SQL Server 2008 R2.

    This is a VM running under VMWare with 4 vCPU and 24 Gb of RAM.

    When the issue occurs we can see:

    - CPU utilization around 50% 

    - Batch/s around 600

    - Transaction/s around 1300

    - PLE running around 800 

    - Hard disk respond time < 10 ms in READ and <2 ms in Write

    Maybe we can try to add 2 extra vCPU to the server and see if it resolves issue.

    Friday, April 21, 2017 5:30 PM
  • Is the text in the subject line the exact error message you see, or is it your own translation of a localised message in your language?

    I ask, because I cannot find that message text in sys.messages. That would indicate that this is a message from an application, and in that case you would first need to check with the vendor/developer of that system.

    However, there is a message in sys.messages which somewhat resemblent of what you posted: An internal error happened while generating a new DBTS for database "%.*ls". Please retry the operation. This messge appears to be new for SQL 2016; I don't find any message about @@DBTS in sys.messages on SQL 2014.

    Friday, April 21, 2017 9:09 PM
  • Hi Erland,

    Yes, the text in the subject is the message as it appears into SQL Server error Log. I've just replaced the real DB Name by <DBName>.

    Date 2017-04-20 00:20:19
    Log SQL Server (Archive #1 - 2017-04-21 16:10:00)

    Source spid131

    Get new DBTS for database <DBName> with physical db name <DBName> fails with too many retries.

    The error you mentionned is the one catched by the application and is a little bit different as you can see:

    An internal error happened while generating a new DBTS for database "<DBName>". Please retry the operation.

    After adding 2 more vCPU to our server last Friday, the process didn't failed this weekend. Maybe it's on the good way. We are going to wait a little before concluding.

    Monday, April 24, 2017 11:37 AM
  • Unfortunatly, it failed last night, the CPU improvement didn't help.

    Any other ideas are welcome.

    Monday, May 01, 2017 3:35 PM
  • I would try installing the latest CU and see if that helps.  I don't see anything specific to this problem, but MS is horrible at publicly documenting changes, so it is worth a try.  Otherwise, you will likely need to contact MS Support.

    I did see references to this on NAV running on SQL 2016.  Are you by chance using NAV?

    Monday, May 01, 2017 4:41 PM
  • Thanks Tom. 

    I saw that one too but unfortunatly, it doesn't apply, we are not using NAV.

    I'm gonna give it a try with the latest CU and raise a support case if it doesn't help.

    Monday, May 01, 2017 5:11 PM
  • I found an open bug report on this problem:

    Monday, May 01, 2017 5:30 PM