SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Double queue reader or is it still busy?


Double queue reader or is it still busy?

Author
Message
Dennis Post
Dennis Post
Ten Centuries
Ten Centuries (1K reputation)Ten Centuries (1K reputation)Ten Centuries (1K reputation)Ten Centuries (1K reputation)Ten Centuries (1K reputation)Ten Centuries (1K reputation)Ten Centuries (1K reputation)Ten Centuries (1K reputation)

Group: General Forum Members
Points: 1013 Visits: 547
I came across this line in the verbose log on replication QueueReader Agent job startup.

The Queue Reader Agent has encountered the error 'Another queuereader agent for the subscription or subscriptions is running, or the server is working on a previous request by the same agent.' when connecting to 'distribution' on 'Svr01\Inst01'. Ensure that the publication and subscription are defined properly and that both servers are running.

The first clue I had that something was wrong was the vague replication message:

The replication agent has not logged a progress message in 10 minutes. This might indicate an unresponsive agent or high system activity. Verify that records are being replicated to the destination and that connections to the Subscriber, Publisher, and Distributor are still active.

Replication IS working but Replication Monitor is showing red X's. This second error has shown up from time to time and sometimes goes away. For a while now I though this was a bug as it has been reported a few times on Connect.

Assuming the first quoted error is correct, how can I find the double QueueReader or previous request?
tasklist /FI "imagename eq qreader.exe"
Returns nothing.

SELECT job_id, name, enabled FROM msdb..sysjobs WHERE category_id = 19 ORDER BY date_created;
Returns 1 row on each distributor.

Setup:
Svr01 = Publisher, Distributor, SQL 2005
Svr02 = Publisher, Distributor, SQL 2005, Subscribor (Svr01)
Svr03 = SQL 2005, Subscribor (Svr01, Svr02)

Both Svr01 and Svr02 are reporting these errors.

This is being recorded in the error logs every minute:
[181] Step 2 of job [Svr01\Inst01].11 failed but will be retried in 1 minute(s)

Step 2:
Name : Run Agent
Type : Replication Queue Reader
Run as : SQL Server Agent Service Account
Database : Distribution
Command : -Distributor [Svr01\Inst01] -DistributionDB [distribution] -DistributorSecurityMode 1 -Continuous



For better, quicker answers on T-SQL questions, read Jeff Moden's suggestions.

"Million-to-one chances crop up nine times out of ten." ― Terry Pratchett, Mort
Dennis Post
Dennis Post
Ten Centuries
Ten Centuries (1K reputation)Ten Centuries (1K reputation)Ten Centuries (1K reputation)Ten Centuries (1K reputation)Ten Centuries (1K reputation)Ten Centuries (1K reputation)Ten Centuries (1K reputation)Ten Centuries (1K reputation)

Group: General Forum Members
Points: 1013 Visits: 547
Solved it.

The Queue Reader agent is only used in snapshot or updatable transactional replications.

I just deleted the job and emptied tables MSqreader_agents & MSqreader_history from the distribution database. Finally I killed the qrdrsvc.exe process.

Helpful links:
MSDN
BOL



For better, quicker answers on T-SQL questions, read Jeff Moden's suggestions.

"Million-to-one chances crop up nine times out of ten." ― Terry Pratchett, Mort
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search