Opened 18 months ago

Last modified 13 months ago

#5520 new defect

celery has wrong broker in config files

Reported by: Bruno Santos Owned by:
Priority: major Milestone:
Component: programming Keywords:
Cc: Parent Tickets:

Description

After installing mediagoblin and used the systemd init files,
I wasn't able to transcode any files..
After checking the logs /var/log/messages
I get the following error:

ERROR/MainProcess] consumer: Cannot connect to amqp://guest:**@127.0.0.1:5672//: [Errno 111] Connection refused.
Trying again in 14.00 seconds...

[2017-07-28 17:39:06,874: ERROR/MainProcess] consumer: Cannot connect to amqp://guest:**@127.0.0.1:5672//: [Errno 111] Connection refused.
Trying again in 16.00 seconds...

[2017-07-28 17:39:22,912: ERROR/MainProcess] consumer: Cannot connect to amqp://guest:**@127.0.0.1:5672//: [Errno 111] Connection refused.
Trying again in 18.00 seconds.

After searching through the issues, I found issue #859:
https://issues.mediagoblin.org/ticket/859

somewhat related to this problem...

I've checked config_spec.ini and found this:

[celery]
# default result stuff
CELERY_RESULT_BACKEND = string(default="database")
CELERY_RESULT_DBURI = string(default="sqlite:///%(here)s/celery.db")

# default kombu stuff
BROKER_URL = string(default="amqp://")

After changing the kombu stuff to:

BROKER_TRANSPORT = string(default="sqlalchemy")
BROKER_URL = string(default="sqlite:///%(here)s/kombu.db")

now it works...

I've never touched this file, this is configuration by default and there's nothing in the easy deployment wiki page to change something in here...

Subtickets

Change History (1)

comment:1 Changed 13 months ago by Elinvention

I had the same problem, then I found out that devs made the decision to switch to RabbitMQ, instead of using a sqlite database as a queue for celery's tasks. The discussion is here: 2016-09-04 meeting and 2017-03-04 meeting.

So those lines are needed if you want to keep the deprecated sqlite middleware, or you can

apt install rabbitmq-server

and that's it.

Note: See TracTickets for help on using tickets.