21

I have Celery running with RabbitMQ broker. Today, I have a failure of a Celery node, it doesn't execute tasks and doesn't respond on service celeryd stop command. After few repeats, the node stopped, but on start I get this message:

[WARNING/MainProcess] celery@nodename ready.
[WARNING/MainProcess] /home/ubuntu/virtualenv/project_1/local/lib/python2.7/site-packages/kombu/pidbox.py:73: UserWarning: A node named u'nodename' is already using this process mailbox!

Maybe you forgot to shutdown the other node or did not do so properly?
Or if you meant to start multiple nodes on the same host please make sure
you give each node a unique node name!

  warnings.warn(W_PIDBOX_IN_USE % {'hostname': self.hostname})

Can anyone suggest how to unlock process mailbox?

Mark Rotteveel
  • 100,966
  • 191
  • 140
  • 197
Jamal
  • 365
  • 2
  • 3
  • 10

2 Answers2

44

From here http://celery.readthedocs.org/en/latest/userguide/workers.html#starting-the-worker you might need to name each node uniquely. Example:

$ celery -A proj worker --loglevel=INFO --concurrency=10 -n worker1.%h

In supervisor escape by using %%h.

Paolo
  • 20,112
  • 21
  • 72
  • 113
f01
  • 1,738
  • 1
  • 18
  • 21
  • 5
    Note, if you don't use `--concurrency`, and instead rely on another service like `supervisor` to handle concurrency, this will still result in conflicting node names. – Cerin Jul 17 '17 at 21:38
-2

Large log file or not enough free space was a reason, i think. After deletion all is ok

Jamal
  • 365
  • 2
  • 3
  • 10
  • I can confirm Jamal's answer. It seems that RabbitMQ requires as much free disk space as RAM. We got very low on disk space on the box -- when we cleared up lots of space, this message stopped occurring – Chris Curvey Nov 15 '13 at 14:33
  • I have the same problem, and deleted all the logs and checked the space on disk. It seems all good, but I keep getting the same error... – Francesco Della Vedova Nov 28 '13 at 15:16
  • 4
    This answer is incorrect. See @f01 answer for correct explanation. I was also having the same problem and was solved using the explanation given in the link in the that answer. – Debanshu Kundu May 06 '15 at 11:32
  • 1
    @Jamal, you are probably confusing different issues because your tests were not isolated. You probably had an already-running process when you started another one, got your error. You stopped the original one and you also deleted for new "space", and it got fixed, making you think it was due to the free space. – Zoran Pavlovic Mar 24 '16 at 09:36
  • This actually worked for me as well. I think he should've specified that you should be freeing space in the rabbitmq server (I was using amqp) – jrhee17 Jan 10 '18 at 16:15
  • Where would this log file be located? – sattva_venu Oct 06 '20 at 12:10