I'm running SQL 2K SP3, and I have a query that hangs and when I check the
sysprocesses table, the process is being blocked by spid -2. Also, when I
run sp_lock, there are several locks on the table I'm querying that have a
spid of -2. There are no errors in the errorlog.
There is no process with a spid = -2, so I don't have anything to kill. How
can I get rid of this without rebooting the SQL Server?>
> I'm running SQL 2K SP3, and I have a query that hangs and when I check
the
> sysprocesses table, the process is being blocked by spid -2. Also, when
I
> run sp_lock, there are several locks on the table I'm querying that have
a
> spid of -2. There are no errors in the errorlog.
> There is no process with a spid = -2, so I don't have anything to kill.
How
> can I get rid of this without rebooting the SQL Server?
--
From SQL Server Books Online:
In SQL Server 2000, all orphaned DTC transactions are assigned the SPID
value of '-2'. Orphaned DTC transactions are distributed transactions that
are not associated with any SPID. Thus, when an orphaned transaction is
blocking another process, this orphaned distributed transaction can be
identified by its distinctive '-2' SPID value. For more information, see
KILL.
UOW
Identifies the Unit of Work ID (UOW) of the DTC transaction. UOW is a
character string that may be obtained from the syslockinfo table, which
gives the UOW for every lock held by a DTC transaction. UOW also may be
obtained from the error log or through the DTC monitor. For more
information on monitoring distributed transactions, see the MS DTC user
manual.
Use KILL UOW to terminate orphaned DTC transactions, which are not
associated with any real SPID and instead are associated artificially with
SPID = '-2'. For more information on SPID = '-2', see the Remarks section
later in this topic.
Hope this helps,
Eric Cárdenas
Senior support professional
This posting is provided "AS IS" with no warranties, and confers no rights.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment