2012-12-24 77 views
3

當運行狀態命令我碰到下面的錯誤: -Celeryd時間約束錯誤

Am using rabbitmq as the messaging broker 

我下面這個blog

sudo /etc/init.d/celeryd status 
Error: No nodes replied within time constraint 

如何調試這個錯誤?

我也檢查了這個問題。那裏的答案沒有幫助。

django/celery - celery status: Error: No nodes replied within time constraint

編輯: -

檢查芹菜拍的記錄後,我發現了以下錯誤

celerybeat raised exception <class 'gdbm.error'>: error(13, 'Permission denied') 
+0

你使用了什麼後端? –

+0

@ bradley.ayers rabbitmq作爲消息傳遞代理... –

+0

也許你沒有足夠的可用磁盤空間,並且RabbitMQ阻止消息,導致超時? –

回答

2

也許這是由不具有用於celerybeat-schedule文件的寫權限芹菜造成的。您鏈接的文檔顯示配置爲使用/var/run/celerybeat-schedule作爲芹菜節拍時間表文件的芹菜。

您的進程是否具有對該文件的寫入權限?如果該目錄由root(應該是)擁有,並且您的進程正在以除root用戶以外的其他任何方式運行,那麼可能會導致權限被拒絕的錯誤。

檢查您的權限是否正確,然後嘗試刪除該文件,然後重新啓動所有內容。

+0

感謝會嘗試,立即 –

+0

所以最終的問題是,所有的日誌,運行和調度文件力具有寫權限正確分配。 –

1

使用下面的命令來查找問題:

C_FAKEFORK=1 sh -x /etc/init.d/celeryd start 

這通常是因爲有您的開源項目的問題(權限問題,語法錯誤等)

如芹菜文檔中提到: -

If the worker starts with 「OK」 but exits almost immediately afterwards and there is nothing in the log file, then there is probably an error but as the daemons standard outputs are already closed you’ll not be able to see them anywhere. For this situation you can use the C_FAKEFORK environment variable to skip the daemonization step

好運

來源:Celery Docs

0

我遇到同樣的問題。 重新啓動RabbitMQ的固定它:

sudo systemctl restart rabbitmq-server 

和奇怪的是,我需要等待至少100秒。 對我而言,我認爲存在磁盤問題。