Created
November 2, 2012 14:58
-
-
Save imtapps/4001847 to your computer and use it in GitHub Desktop.
Celery & Rabbitmq Commands
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Run celery_status.sh in a shell, this will display (real time) the current running celery processes. | |
Try to kill celery using the "rake celery:kill" task and watch to see if they go away, if they do not, you may have to resort to using "kill -9" on specific pids. | |
Use the "rake rabbitmq:qs" to see how many requests are in each queue in rabbitmq. If there are 60+ in the error queue run the "clear_rabbitmq_queue.py" file to clear them out. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
while [ 1 ]; do | |
clear | |
ps aux | grep celery | grep -v grep | |
sleep 3 | |
done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from amqplib import client_0_8 as amqp | |
conn = amqp.Connection(host="localhost:5672") | |
conn = conn.channel() | |
conn.queue_purge("error") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment