I have two Production Database Servers
1. SQLServer2008 (2 Nodes Cluster)
2. SQLServer2012 with 2 read only replica (3 Nodes Cluster)
I would like to draw a line here, We have routing table and URL working perfectly fine.
We have tested LINKED Server from 2012 Box to production Server by Specifying APPLICATIONINTENT = ReadOnly; it works perfectly fine, the routing is being used.
When we create linked server from SQL Server 2008 Box (Please note we have installed SQL Server 2012 Client tools on this box) using the below script
USE [master] EXEC master.dbo.sp_dropserver @server=N'AGL1', @droplogins='droplogins' GO EXEC master.dbo.sp_addlinkedserver
@server = N'AGL1' ,@datasrc='AGL1' ,@provider='SQLNCLI11' ,@provstr='ApplicationIntent=ReadOnly;Database=AdventureWorks2012'
Linked Server is created, Now when I run the Query
exec ('select @@servername') at AGL1
It always brings the Primary READ/WRITE node name only, after lots of research I found that, this linked Server is always using SQL Native Client 10.0 only, even after creating Linked Server using SNC 11, That is the reason it is not going to routing table. Its always connecting to Primary node.
Below is the way I found it, on 2012 Production Server I executed below Query
SELECT session_id, protocol_type, driver_version =
CASE SUBSTRING(CAST(protocol_version AS BINARY(4)), 1,1)
WHEN 0x70 THEN 'SQL Server 7.0'
WHEN 0x71 THEN 'SQL Server 2000'
WHEN 0x72 THEN 'SQL Server 2005'
WHEN 0x73 THEN 'SQL Server 2008'
ELSE 'SQL Server 2012'
END,client_net_address ,client_tcp_port,local_tcp_port ,T.text
FROM sys.dm_exec_connections
CROSS APPLY sys.dm_exec_sql_text(most_recent_sql_handle) AS T
The help is taken from msdn (Link Provided below) for the above Query
https://msdn.microsoft.com/en-us/library/dd339982.aspx
and I found it always uses SQL Server 2008 SNC.
My Question is, is there a way to force SQL Server to use SQL Server Native Client 11, without restart since it is production.
Thank you in advance.