At times one needs to manually remove partial or full rollbacks from Post queue in response to Post errors, reducing queue size (without inducing out of sync conditions) for better Post performance etc. This solution delves on the right command to achieve this in Windows environment.
General information.
The following is the correct way to run it in Windows environment:
A.When Shareplex is running:
1. sp_ctrl > status (make sure it is "stopped due to error" or "stopped by user" before exiting sp_ctrl for step # 3)
2. sp_ctrl>stop import
3. sp_ctrl>exit
4. $ qview -r<port#> -p($ denotes Windows OS prompt. If using named queues, answer the prompt with the appropriate queue name. The following is a sample screen shot when command is run)
$ qview -p
Queue <queue_name1> (y/n) <n>? n
Queue <queue_name2> (y/n) <n>? y
Current queue <queue_name2> user <queueuser_name>
Read release full rollback subqueue 5, seq 6580815286
5. Launch sp_ctrl and Post
B.When Shareplex is shutdown:
1. sp_ctrl > shutdown
2. $ qview -r<port#> -p($ denotes Windows OS prompt. If using named queues, answer the prompt with the appropriate queue name. The following is a sample screen shot when command is run)
$ qview -p
Queue <queue_name1> (y/n) <n>? n
Queue <queue_name2> (y/n) <n>? y
Current queue <queue_name2> user <queueuser_name>
Read release full rollback subqueue 5, seq 6580815286
3. Startup Shareplex and restart Post