An internal error happened while generating a new DBTS for database "test_db". Please retry the operation.
This error happens during INSERT/UPDATE queries, even simple ones, if the server is busy for example restoring another database
The SQL Server is the Enterprise version, it has the SP1 applied.
SELECT @@VERSION produces: Microsoft SQL Server 2016 (SP1) (KB3182545) - 13.0.4001.0 (X64) Oct 28 2016 18:17:30 Copyright (c) Microsoft Corporation Enterprise Edition: Core-based Licensing (64-bit) on Windows Server 2012 R2 Standard 6.3 <X64> (Build 9600: ) (Hypervisor)
It runs on VMWare 5.5 build 4180647.
The OS is Windows 2012 R2 Standard, no SP applied. The server is configured with 4 vCPUs and 80 GB of RAM. Disks are handled through VMware Virtual SCSI Disk
Heimo Hetl commented
Same issue here intermittently when loading data into MDS (executing MDS' internal procedures). Microsoft SQL Server 2016 (SP2-CU7) (KB4495256) - 13.0.5337.0 (X64) May 16 2019 02:24:21 Enterprise Edition: Core-based Licensing (64-bit) on Windows Server 2016 Standard 10.0 <X64> (Build 14393: ) (Hypervisor)
Rune Foyn commented
This does not seem to be an issue in SQL2017! As far as I can tell, that is a strong indication that Microsoft has rewritten the logic behind DBTS creation. It would be good if they would comment on this.
There is a blog which explains the underlying timestamp generation issue: https://blogs.msdn.microsoft.com/sqlmeditation/2018/06/21/an-internal-error-happened-while-generating-a-new-dbts-for-database-abc/ ..
According to the blog the issue should happen very rarely, but this is not the case, I'm intermittently seeing this issue on SQL Server 2016 SP2-CU2 in a SSIS import job, one week 80% of jobs may succeed, the next week 80% of jobs may fail. Based on the blog, which describes a race for timestamp values between multiple threads, I have tried to reduce the number threads by reducing the number of virtual CPU's (Hyper-V) from 8 to 4, and since then the problem has not occurred, however this also reduces performance and is therefore only a workaround.
Hopefully Microsoft will finally fix this issue, which did not occur in previous versions of SQL Server. Does anyone know if the issue occurs on SQL Server 2017?
My customer is also facing this issue during batch processing. (“ System.Data.SqlClient.SqlException: An internal error happened while generating a new DBTS for database "xxxxx". Please retry the operation.”).
They are looking for some confirmation on this issue asap.
Any Information/Update/RemedyOption on this would be highly appreciated. Please help !!
They are using SQL Server 2016 (SP1-CU6) (KB4037354) - 13.0.4457.0 (X64) Nov 8 2017 17:32:23 Copyright (c) Microsoft Corporation Developer Edition (64-bit) on Windows Server 2012 R2 Datacenter 6.3 <X64> (Build 9600: ) (Hypervisor)
Michael Costello commented
We are getting this issue still and have an open case with Microsoft.
Rune C. Foyn commented
SP2 released Apr 24th, but still nothing to fix this bug?!
Rune Foyn commented
This bug has gotten very old. How come it is impossible to get an official response? I am struggling with this problem on a monthly basis. As far as I can tell, it has not been addressed in any of the CUs released thus far.
Getting this error during batch processing of jobs on JohnGalt database server. Microsoft SQL Server 2016 (SP1-CU4) (KB4024305) - 13.0.4446.0 (X64) Jul 16 2017 18:08:49 Copyright (c) Microsoft Corporation Standard Edition (64-bit) on Windows Server 2012 R2 Standard 6.3 <X64> (Build 9600: ) (Hypervisor). VM with 16cps, 30GB memory. Running on Nutanix. Intermittent.