FIX: Availability group failover takes a long time if a database in the availability group contains a FileTable in SQL Server 2012

Microsoft distributes Microsoft SQL Server 2012 fixes as one downloadable file. Because the fixes are cumulative, each new release contains all the hotfixes and all the security fixes that were included with the previous SQL Server 2012 fix release.
Consider the following scenario:
  • You have an AlwaysOn availability group in Microsoft SQL Server 2012.
  • A database in the availability group contains at least one FileTable.
  • A failover occurs in the availability group.
In this scenario, it may take longer than expected for the shared FILESTREAM data to come online.

Note This issue is more likely to occur when it has been a long time since the previous failover.
This issue occurs because the truncation operation for FSLOG records in the $FSLOG folder takes a long time. When a long time has passed since the previous failover, many FSLOG records have accumulated in the FSLOG$ folder on the secondary replica without being truncated. When a failover occurs, the secondary replica becomes the new primary replica, and the FSLOG$ folder must be truncated before the files in the FileTable folder can come online. In this situation, it takes a long time to clear millions of FSLOG records.
After you apply this hotfix, the truncation operation in FSLOG$ folder is enabled on secondary replicas.

Service pack information for SQL Server 2012

To resolve this problem, obtain the latest service pack for SQL Server 2012. For more information, click the following article number to view the article in the Microsoft Knowledge Base:
2755533 How to obtain the latest service pack for SQL Server 2012
Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.
To work around this issue, plan regular availability group failovers in order to minimize the accumulation of FSLOG records on the secondary replicas. For example, plan a weekly availability group failover.
More information
For more information about how to use the FILESTREAM and FileTable features with AlwaysOn availability groups , go to the following MSDN website:For more information about the FileTables feature, go to the following MSDN website: For more information about software update terminology, click the following article number to view the article in the Microsoft Knowledge Base:
824684 Description of the standard terminology that is used to describe Microsoft software updates

Article ID: 2746012 - Last Review: 11/21/2012 19:34:00 - Revision: 3.1

  • kbtshoot kbqfe kbfix kbsurveynew kbexpertiseadvanced kbprb KB2746012