FAQ 22 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742
  1. .. _faq:
  2. ============================
  3. Frequently Asked Questions
  4. ============================
  5. .. contents::
  6. :local:
  7. .. _faq-general:
  8. General
  9. =======
  10. .. _faq-when-to-use:
  11. What kinds of things should I use Celery for?
  12. ---------------------------------------------
  13. **Answer:** `Queue everything and delight everyone`_ is a good article
  14. describing why you would use a queue in a web context.
  15. .. _`Queue everything and delight everyone`:
  16. http://decafbad.com/blog/2008/07/04/queue-everything-and-delight-everyone
  17. These are some common use cases:
  18. * Running something in the background. For example, to finish the web request
  19. as soon as possible, then update the users page incrementally.
  20. This gives the user the impression of good performance and "snappiness", even
  21. though the real work might actually take some time.
  22. * Running something after the web request has finished.
  23. * Making sure something is done, by executing it asynchronously and using
  24. retries.
  25. * Scheduling periodic work.
  26. And to some degree:
  27. * Distributed computing.
  28. * Parallel execution.
  29. .. _faq-misconceptions:
  30. Misconceptions
  31. ==============
  32. .. _faq-serializion-is-a-choice:
  33. Is Celery dependent on pickle?
  34. ------------------------------
  35. **Answer:** No.
  36. Celery can support any serialization scheme and has support for JSON/YAML and
  37. Pickle by default. And as every task is associated with a content type, you
  38. can even send one task using pickle, and another using JSON.
  39. The default serialization format is pickle simply because it is
  40. convenient as it supports sending complex Python objects as task arguments.
  41. If you need to communicate with other languages you should change
  42. to a serialization format that is suitable for that.
  43. You can set a global default serializer, the default serializer for a
  44. particular Task, or even what serializer to use when sending a single task
  45. instance.
  46. .. _faq-is-celery-for-django-only:
  47. Is Celery for Django only?
  48. --------------------------
  49. **Answer:** No.
  50. Celery does not depend on Django anymore. To use Celery with Django you have
  51. to use the `django-celery`_ package.
  52. .. _`django-celery`: http://pypi.python.org/pypi/django-celery
  53. .. _faq-is-celery-for-rabbitmq-only:
  54. Do I have to use AMQP/RabbitMQ?
  55. -------------------------------
  56. **Answer**: No.
  57. You can also use Redis, Beanstalk, CouchDB, MongoDB or an SQL database,
  58. see `Using other queues`_.
  59. These "virtual transports" may have limited broadcast and event functionality.
  60. For example remote control commands only works with AMQP and Redis.
  61. .. _`Using other queues`:
  62. http://ask.github.com/celery/tutorials/otherqueues.html
  63. Redis or a database won't perform as well as
  64. an AMQP broker. If you have strict reliability requirements you are
  65. encouraged to use RabbitMQ or another AMQP broker. Redis/database also use
  66. polling, so they are likely to consume more resources. However, if you for
  67. some reason are not able to use AMQP, feel free to use these alternatives.
  68. They will probably work fine for most use cases, and note that the above
  69. points are not specific to Celery; If using Redis/database as a queue worked
  70. fine for you before, it probably will now. You can always upgrade later
  71. if you need to.
  72. .. _faq-is-celery-multilingual:
  73. Is Celery multilingual?
  74. ------------------------
  75. **Answer:** Yes.
  76. :mod:`~celery.bin.celeryd` is an implementation of Celery in python. If the
  77. language has an AMQP client, there shouldn't be much work to create a worker
  78. in your language. A Celery worker is just a program connecting to the broker
  79. to process messages.
  80. Also, there's another way to be language independent, and that is to use REST
  81. tasks, instead of your tasks being functions, they're URLs. With this
  82. information you can even create simple web servers that enable preloading of
  83. code. See: `User Guide: Remote Tasks`_.
  84. .. _`User Guide: Remote Tasks`:
  85. http://ask.github.com/celery/userguide/remote-tasks.html
  86. .. _faq-troubleshooting:
  87. Troubleshooting
  88. ===============
  89. .. _faq-mysql-deadlocks:
  90. MySQL is throwing deadlock errors, what can I do?
  91. -------------------------------------------------
  92. **Answer:** MySQL has default isolation level set to `REPEATABLE-READ`,
  93. if you don't really need that, set it to `READ-COMMITTED`.
  94. You can do that by adding the following to your :file:`my.cnf`::
  95. [mysqld]
  96. transaction-isolation = READ-COMMITTED
  97. For more information about InnoDB`s transaction model see `MySQL - The InnoDB
  98. Transaction Model and Locking`_ in the MySQL user manual.
  99. (Thanks to Honza Kral and Anton Tsigularov for this solution)
  100. .. _`MySQL - The InnoDB Transaction Model and Locking`: http://dev.mysql.com/doc/refman/5.1/en/innodb-transaction-model.html
  101. .. _faq-worker-hanging:
  102. celeryd is not doing anything, just hanging
  103. --------------------------------------------
  104. **Answer:** See `MySQL is throwing deadlock errors, what can I do?`_.
  105. or `Why is Task.delay/apply\* just hanging?`.
  106. .. _faq-publish-hanging:
  107. Why is Task.delay/apply\*/celeryd just hanging?
  108. -----------------------------------------------
  109. **Answer:** There is a bug in some AMQP clients that will make it hang if
  110. it's not able to authenticate the current user, the password doesn't match or
  111. the user does not have access to the virtual host specified. Be sure to check
  112. your broker logs (for RabbitMQ that is :file:`/var/log/rabbitmq/rabbit.log` on
  113. most systems), it usually contains a message describing the reason.
  114. .. _faq-celeryd-on-freebsd:
  115. Why won't celeryd run on FreeBSD?
  116. ---------------------------------
  117. **Answer:** The multiprocessing pool requires a working POSIX semaphore
  118. implementation which isn't enabled in FreeBSD by default. You have to enable
  119. POSIX semaphores in the kernel and manually recompile multiprocessing.
  120. Luckily, Viktor Petersson has written a tutorial to get you started with
  121. Celery on FreeBSD here:
  122. http://www.playingwithwire.com/2009/10/how-to-get-celeryd-to-work-on-freebsd/
  123. .. _faq-duplicate-key-errors:
  124. I'm having `IntegrityError: Duplicate Key` errors. Why?
  125. ---------------------------------------------------------
  126. **Answer:** See `MySQL is throwing deadlock errors, what can I do?`_.
  127. Thanks to howsthedotcom.
  128. .. _faq-worker-stops-processing:
  129. Why aren't my tasks processed?
  130. ------------------------------
  131. **Answer:** With RabbitMQ you can see how many consumers are currently
  132. receiving tasks by running the following command::
  133. $ rabbitmqctl list_queues -p <myvhost> name messages consumers
  134. Listing queues ...
  135. celery 2891 2
  136. This shows that there's 2891 messages waiting to be processed in the task
  137. queue, and there are two consumers processing them.
  138. One reason that the queue is never emptied could be that you have a stale
  139. worker process taking the messages hostage. This could happen if celeryd
  140. wasn't properly shut down.
  141. When a message is received by a worker the broker waits for it to be
  142. acknowledged before marking the message as processed. The broker will not
  143. re-send that message to another consumer until the consumer is shut down
  144. properly.
  145. If you hit this problem you have to kill all workers manually and restart
  146. them::
  147. ps auxww | grep celeryd | awk '{print $2}' | xargs kill
  148. You might have to wait a while until all workers have finished the work they're
  149. doing. If it's still hanging after a long time you can kill them by force
  150. with::
  151. ps auxww | grep celeryd | awk '{print $2}' | xargs kill -9
  152. .. _faq-task-does-not-run:
  153. Why won't my Task run?
  154. ----------------------
  155. **Answer:** There might be syntax errors preventing the tasks module being imported.
  156. You can find out if Celery is able to run the task by executing the
  157. task manually:
  158. >>> from myapp.tasks import MyPeriodicTask
  159. >>> MyPeriodicTask.delay()
  160. Watch celeryd`s log file to see if it's able to find the task, or if some
  161. other error is happening.
  162. .. _faq-periodic-task-does-not-run:
  163. Why won't my Periodic Task run?
  164. -------------------------------
  165. **Answer:** See `Why won't my Task run?`_.
  166. .. _faq-purge-the-queue:
  167. How do I discard all waiting tasks?
  168. ------------------------------------
  169. **Answer:** You can use celeryctl to purge all configured task queues::
  170. $ celeryctl purge
  171. or programatically::
  172. >>> from celery.task.control import discard_all
  173. >>> discard_all()
  174. 1753
  175. If you only want to purge messages from a specific queue
  176. you have to use the AMQP API or the :program:`camqadm` utility::
  177. $ camqadm queue.purge <queue name>
  178. The number 1753 is the number of messages deleted.
  179. You can also start :mod:`~celery.bin.celeryd` with the
  180. :option:`--purge` argument, to purge messages when the worker starts.
  181. .. _faq-messages-left-after-purge:
  182. I've discarded messages, but there are still messages left in the queue?
  183. ------------------------------------------------------------------------
  184. **Answer:** Tasks are acknowledged (removed from the queue) as soon
  185. as they are actually executed. After the worker has received a task, it will
  186. take some time until it is actually executed, especially if there are a lot
  187. of tasks already waiting for execution. Messages that are not acknowledged are
  188. held on to by the worker until it closes the connection to the broker (AMQP
  189. server). When that connection is closed (e.g. because the worker was stopped)
  190. the tasks will be re-sent by the broker to the next available worker (or the
  191. same worker when it has been restarted), so to properly purge the queue of
  192. waiting tasks you have to stop all the workers, and then discard the tasks
  193. using :func:`~celery.task.control.discard_all`.
  194. .. _faq-results:
  195. Results
  196. =======
  197. .. _faq-get-result-by-task-id:
  198. How do I get the result of a task if I have the ID that points there?
  199. ----------------------------------------------------------------------
  200. **Answer**: Use `Task.AsyncResult`::
  201. >>> result = MyTask.AsyncResult(task_id)
  202. >>> result.get()
  203. This will give you a :class:`~celery.result.BaseAsyncResult` instance
  204. using the tasks current result backend.
  205. If you need to specify a custom result backend you should use
  206. :class:`celery.result.BaseAsyncResult` directly::
  207. >>> from celery.result import BaseAsyncResult
  208. >>> result = BaseAsyncResult(task_id, backend=...)
  209. >>> result.get()
  210. .. _faq-security:
  211. Security
  212. ========
  213. Isn't using `pickle` a security concern?
  214. ----------------------------------------
  215. **Answer**: Yes, indeed it is.
  216. You are right to have a security concern, as this can indeed be a real issue.
  217. It is essential that you protect against unauthorized
  218. access to your broker, databases and other services transmitting pickled
  219. data.
  220. For the task messages you can set the :setting:`CELERY_TASK_SERIALIZER`
  221. setting to "json" or "yaml" instead of pickle. There is
  222. currently no alternative solution for task results (but writing a
  223. custom result backend using JSON is a simple task)
  224. Note that this is not just something you should be aware of with Celery, for
  225. example also Django uses pickle for its cache client.
  226. Can messages be encrypted?
  227. --------------------------
  228. **Answer**: Some AMQP brokers supports using SSL (including RabbitMQ).
  229. You can enable this using the :setting:`BROKER_USE_SSL` setting.
  230. It is also possible to add additional encryption and security to messages,
  231. if you have a need for this then you should contact the :ref:`mailing-list`.
  232. Is it safe to run :program:`celeryd` as root?
  233. ---------------------------------------------
  234. **Answer**: No!
  235. We're not currently aware of any security issues, but it would
  236. be incredibly naive to assume that they don't exist, so running
  237. the Celery services (:program:`celeryd`, :program:`celerybeat`,
  238. :program:`celeryev`, etc) as an unprivileged user is recommended.
  239. .. _faq-brokers:
  240. Brokers
  241. =======
  242. Why is RabbitMQ crashing?
  243. -------------------------
  244. **Answer:** RabbitMQ will crash if it runs out of memory. This will be fixed in a
  245. future release of RabbitMQ. please refer to the RabbitMQ FAQ:
  246. http://www.rabbitmq.com/faq.html#node-runs-out-of-memory
  247. .. note::
  248. This is no longer the case, RabbitMQ versions 2.0 and above
  249. includes a new persister, that is tolerant to out of memory
  250. errors. RabbitMQ 2.1 or higher is recommended for Celery.
  251. If you're still running an older version of RabbitMQ and experience
  252. crashes, then please upgrade!
  253. Misconfiguration of Celery can eventually lead to a crash
  254. on older version of RabbitMQ. Even if it doesn't crash, this
  255. can still consume a lot of resources, so it is very
  256. important that you are aware of the common pitfalls.
  257. * Events.
  258. Running :mod:`~celery.bin.celeryd` with the :option:`-E`/:option:`--events`
  259. option will send messages for events happening inside of the worker.
  260. Events should only be enabled if you have an active monitor consuming them,
  261. or if you purge the event queue periodically.
  262. * AMQP backend results.
  263. When running with the AMQP result backend, every task result will be sent
  264. as a message. If you don't collect these results, they will build up and
  265. RabbitMQ will eventually run out of memory.
  266. If you don't use the results for a task, make sure you set the
  267. `ignore_result` option:
  268. .. code-block python
  269. @task(ignore_result=True)
  270. def mytask():
  271. ...
  272. class MyTask(Task):
  273. ignore_result = True
  274. Results can also be disabled globally using the
  275. :setting:`CELERY_IGNORE_RESULT` setting.
  276. .. note::
  277. Celery version 2.1 added support for automatic expiration of
  278. AMQP result backend results.
  279. To use this you need to run RabbitMQ 2.1 or higher and enable
  280. the :setting:`CELERY_AMQP_TASK_RESULT_EXPIRES` setting.
  281. .. _faq-use-celery-with-stomp:
  282. Can I use Celery with ActiveMQ/STOMP?
  283. -------------------------------------
  284. **Answer**: No. It used to be supported by Carrot,
  285. but is not currently supported in Kombu.
  286. .. _faq-non-amqp-missing-features:
  287. What features are not supported when not using an AMQP broker?
  288. --------------------------------------------------------------
  289. This is an incomplete list of features not available when
  290. using the virtual transports:
  291. * Remote control commands (supported only by Redis).
  292. * Monitoring with events may not work in all virtual transports.
  293. * The `header` and `fanout` exchange types
  294. (`fanout` is supported by Redis).
  295. .. _faq-tasks:
  296. Tasks
  297. =====
  298. .. _faq-tasks-connection-reuse:
  299. How can I reuse the same connection when applying tasks?
  300. --------------------------------------------------------
  301. **Answer**: See :ref:`executing-connections`.
  302. .. _faq-execute-task-by-name:
  303. Can I execute a task by name?
  304. -----------------------------
  305. **Answer**: Yes. Use :func:`celery.execute.send_task`.
  306. You can also execute a task by name from any language
  307. that has an AMQP client.
  308. >>> from celery.execute import send_task
  309. >>> send_task("tasks.add", args=[2, 2], kwargs={})
  310. <AsyncResult: 373550e8-b9a0-4666-bc61-ace01fa4f91d>
  311. .. _faq-get-current-task-id:
  312. How can I get the task id of the current task?
  313. ----------------------------------------------
  314. **Answer**: The current id and more is available in the task request::
  315. @task
  316. def mytask():
  317. cache.set(mytask.request.id, "Running")
  318. For more information see :ref:`task-request-info`.
  319. .. _faq-custom-task-ids:
  320. Can I specify a custom task_id?
  321. -------------------------------
  322. **Answer**: Yes. Use the `task_id` argument to
  323. :meth:`~celery.execute.apply_async`::
  324. >>> task.apply_async(args, kwargs, task_id="...")
  325. Can I use decorators with tasks?
  326. --------------------------------
  327. **Answer**: Yes. But please see note at :ref:`tasks-decorating`.
  328. .. _faq-natural-task-ids:
  329. Can I use natural task ids?
  330. ---------------------------
  331. **Answer**: Yes, but make sure it is unique, as the behavior
  332. for two tasks existing with the same id is undefined.
  333. The world will probably not explode, but at the worst
  334. they can overwrite each others results.
  335. .. _faq-task-callbacks:
  336. How can I run a task once another task has finished?
  337. ----------------------------------------------------
  338. **Answer**: You can safely launch a task inside a task.
  339. Also, a common pattern is to use callback tasks:
  340. .. code-block:: python
  341. @task()
  342. def add(x, y, callback=None):
  343. result = x + y
  344. if callback:
  345. subtask(callback).delay(result)
  346. return result
  347. @task(ignore_result=True)
  348. def log_result(result, **kwargs):
  349. logger = log_result.get_logger(**kwargs)
  350. logger.info("log_result got: %s" % (result, ))
  351. Invocation::
  352. >>> add.delay(2, 2, callback=log_result.subtask())
  353. See :doc:`userguide/tasksets` for more information.
  354. .. _faq-cancel-task:
  355. Can I cancel the execution of a task?
  356. -------------------------------------
  357. **Answer**: Yes. Use `result.revoke`::
  358. >>> result = add.apply_async(args=[2, 2], countdown=120)
  359. >>> result.revoke()
  360. or if you only have the task id::
  361. >>> from celery.task.control import revoke
  362. >>> revoke(task_id)
  363. .. _faq-node-not-receiving-broadcast-commands:
  364. Why aren't my remote control commands received by all workers?
  365. --------------------------------------------------------------
  366. **Answer**: To receive broadcast remote control commands, every worker node
  367. uses its host name to create a unique queue name to listen to,
  368. so if you have more than one worker with the same host name, the
  369. control commands will be received in round-robin between them.
  370. To work around this you can explicitly set the host name for every worker
  371. using the :option:`--hostname` argument to :mod:`~celery.bin.celeryd`::
  372. $ celeryd --hostname=$(hostname).1
  373. $ celeryd --hostname=$(hostname).2
  374. etc., etc...
  375. .. _faq-task-routing:
  376. Can I send some tasks to only some servers?
  377. --------------------------------------------
  378. **Answer:** Yes. You can route tasks to an arbitrary server using AMQP,
  379. and a worker can bind to as many queues as it wants.
  380. See :doc:`userguide/routing` for more information.
  381. .. _faq-change-periodic-task-interval-at-runtime:
  382. Can I change the interval of a periodic task at runtime?
  383. --------------------------------------------------------
  384. **Answer**: Yes. You can use the Django database scheduler, or you can
  385. override `PeriodicTask.is_due` or turn `PeriodicTask.run_every` into a
  386. property:
  387. .. code-block:: python
  388. class MyPeriodic(PeriodicTask):
  389. def run(self):
  390. # ...
  391. @property
  392. def run_every(self):
  393. return get_interval_from_database(...)
  394. .. _faq-task-priorities:
  395. Does celery support task priorities?
  396. ------------------------------------
  397. **Answer**: No. In theory, yes, as AMQP supports priorities. However
  398. RabbitMQ doesn't implement them yet.
  399. The usual way to prioritize work in Celery, is to route high priority tasks
  400. to different servers. In the real world this may actually work better than per message
  401. priorities. You can use this in combination with rate limiting to achieve a
  402. highly responsive system.
  403. .. _faq-acks_late-vs-retry:
  404. Should I use retry or acks_late?
  405. --------------------------------
  406. **Answer**: Depends. It's not necessarily one or the other, you may want
  407. to use both.
  408. `Task.retry` is used to retry tasks, notably for expected errors that
  409. is catchable with the `try:` block. The AMQP transaction is not used
  410. for these errors: **if the task raises an exception it is still acknowledged!**.
  411. The `acks_late` setting would be used when you need the task to be
  412. executed again if the worker (for some reason) crashes mid-execution.
  413. It's important to note that the worker is not known to crash, and if
  414. it does it is usually an unrecoverable error that requires human
  415. intervention (bug in the worker, or task code).
  416. In an ideal world you could safely retry any task that has failed, but
  417. this is rarely the case. Imagine the following task:
  418. .. code-block:: python
  419. @task()
  420. def process_upload(filename, tmpfile):
  421. # Increment a file count stored in a database
  422. increment_file_counter()
  423. add_file_metadata_to_db(filename, tmpfile)
  424. copy_file_to_destination(filename, tmpfile)
  425. If this crashed in the middle of copying the file to its destination
  426. the world would contain incomplete state. This is not a critical
  427. scenario of course, but you can probably imagine something far more
  428. sinister. So for ease of programming we have less reliability;
  429. It's a good default, users who require it and know what they
  430. are doing can still enable acks_late (and in the future hopefully
  431. use manual acknowledgement)
  432. In addition `Task.retry` has features not available in AMQP
  433. transactions: delay between retries, max retries, etc.
  434. So use retry for Python errors, and if your task is idempotent
  435. combine that with `acks_late` if that level of reliability
  436. is required.
  437. .. _faq-schedule-at-specific-time:
  438. Can I schedule tasks to execute at a specific time?
  439. ---------------------------------------------------
  440. .. module:: celery.task.base
  441. **Answer**: Yes. You can use the `eta` argument of :meth:`Task.apply_async`.
  442. Or to schedule a periodic task at a specific time, use the
  443. :class:`celery.schedules.crontab` schedule behavior:
  444. .. code-block:: python
  445. from celery.task.schedules import crontab
  446. from celery.task import periodic_task
  447. @periodic_task(run_every=crontab(hours=7, minute=30, day_of_week="mon"))
  448. def every_monday_morning():
  449. print("This is run every Monday morning at 7:30")
  450. .. _faq-safe-worker-shutdown:
  451. How do I shut down `celeryd` safely?
  452. --------------------------------------
  453. **Answer**: Use the :sig:`TERM` signal, and the worker will finish all currently
  454. executing jobs and shut down as soon as possible. No tasks should be lost.
  455. You should never stop :mod:`~celery.bin.celeryd` with the :sig:`KILL` signal
  456. (:option:`-9`), unless you've tried :sig:`TERM` a few times and waited a few
  457. minutes to let it get a chance to shut down. As if you do tasks may be
  458. terminated mid-execution, and they will not be re-run unless you have the
  459. `acks_late` option set (`Task.acks_late` / :setting:`CELERY_ACKS_LATE`).
  460. .. seealso::
  461. :ref:`worker-stopping`
  462. .. _faq-daemonizing:
  463. How do I run celeryd in the background on [platform]?
  464. -----------------------------------------------------
  465. **Answer**: Please see :ref:`daemonizing`.
  466. .. _faq-windows:
  467. Windows
  468. =======
  469. .. _faq-windows-worker-spawn-loop:
  470. celeryd keeps spawning processes at startup
  471. -------------------------------------------
  472. **Answer**: This is a known issue on Windows.
  473. You have to start celeryd with the command::
  474. $ python -m celeryd.bin.celeryd
  475. Any additional arguments can be appended to this command.
  476. See http://bit.ly/bo9RSw
  477. .. _faq-windows-worker-embedded-beat:
  478. The `-B` / `--beat` option to celeryd doesn't work?
  479. ----------------------------------------------------------------
  480. **Answer**: That's right. Run `celerybeat` and `celeryd` as separate
  481. services instead.
  482. .. _faq-windows-django-settings:
  483. `django-celery` can't find settings?
  484. --------------------------------------
  485. **Answer**: You need to specify the :option:`--settings` argument to
  486. :program:`manage.py`::
  487. $ python manage.py celeryd start --settings=settings
  488. See http://bit.ly/bo9RSw