BEGIN DISTRIBUTED TRANSACTION
SELECT TOP 1 * FROM Sessions
OLE DB provider "SQLNCLI" for linked server "ASILIVE" returned message "No transaction is active.".
Msg 7391, Level 16, State 2, Line 3
The operation could not be performed because OLE DB provider "SQLNCLI" for linked server "ASILIVE" was unable to begin a distributed transaction.
提供者返回了两个错误:
第一个错误:
Number: $80040E14
Source: Microsoft OLE DB Provider for SQL Server
Description: OLE DB provider "SQLNCLI" for linked server "ASILIVE" returned message "No transaction is active.".
HelpFile:
HelpContext: $00000000
SQLState: 01000
NativeError: 7412
错误 #2
Number: $80040E14
Source: Microsoft OLE DB Provider for SQL Server
Description: The operation could not be performed because OLE DB provider "SQLNCLI" for linked server "ASILIVE" was unable to begin a distributed transaction.
HelpFile:
HelpContext: $00000000
SQLState: 42000
NativeError: 7391
如何让微软更加注重功能而非安全性?
或者,我该如何让两个SQL服务器之间进行通信?
相关问题。
- 由于OLE DB提供程序“SQLNCLI10”...无法执行操作(*链接服务器名称为
(null)
) - 分布式事务错误?(使用Oracle提供程序)
- 无法在NHibernate中加入分布式事务(使用Hibernate)
- 在SQL Server 2008 R2中使用分布式事务时出错(SQL Server 2008 R2,无答案)
- 仅通过代码引起的分布式事务错误(由连接池引起)
- 在链接服务器中执行分布式事务协调器时出错(SQL Server 2008,无答案)
- 分布式事务错误?(没有被接受的答案;唯一的答案没有帮助)
- 如何在事务内使用链接服务器插入远程表?(接受的答案不能解决问题)
我所做的是无关紧要的,但我会发帖。
Cursed and swore.
Smashed things.
Checked that a
SELECT
can use the linked server:SELECT * FROM ASILive.CustomerManagementSystem.dbo.Users .... (763 row(s) affected)
Checked that client server can
ping
the remote server:C:\Documents and Settings\avatar>ping asicmstest.contoso.com Pinging asicmstest.contoso.com [10.0.0.40] with 32 bytes of data: Reply from 10.0.0.40: bytes=32 time<1ms TTL=128 Reply from 10.0.0.40: bytes=32 time<1ms TTL=128 Reply from 10.0.0.40: bytes=32 time<1ms TTL=128 Reply from 10.0.0.40: bytes=32 time<1ms TTL=128 Ping statistics for 10.0.0.40: Packets: Sent = 4, Received = 4, Lost = 0 (0% loss), Approximate round trip times in milli-seconds: Minimum = 0ms, Maximum = 0ms, Average = 0ms
Checked that the remote server can commnicate back, by name, to the initiating server:
C:\Documents and Settings\avatar>ping asitestserver.contoso.com Pinging asitestserver.contoso.com [10.0.0.22] with 32 bytes of data: Reply from 10.0.0.22: bytes=32 time<1ms TTL=128 Reply from 10.0.0.22: bytes=32 time<1ms TTL=128 Reply from 10.0.0.22: bytes=32 time<1ms TTL=128 Reply from 10.0.0.22: bytes=32 time<1ms TTL=128 Ping statistics for 10.0.0.22: Packets: Sent = 4, Received = 4, Lost = 0 (0% loss), Approximate round trip times in milli-seconds: Minimum = 0ms, Maximum = 0ms, Average = 0ms
Checked that
@@SERVERNAME
matches the server name on both servers:SELECT @@SERVERNAME, SERVERPROPERTY('MachineName') ------------- ------------- ASITESTSERVER ASITESTSERVER
and
SELECT @@SERVERNAME, SERVERPROPERTY('MachineName') ---------- ---------- ASIGROBTEST ASIGROBTEST
Screamed
Issued
SET XACT_ABORT ON
before issuing my query:SET XACT_ABORT ON GO BEGIN DISTRIBUTED TRANSACTION SELECT TOP 1 * FROM Sessions
Granted
Everyone
Full Control
to:HKEY_LOCAL_MACHINE\Software\Microsoft\MSSQLServer
on both servers.