Odoo Help


Does a cron task have a timeout ?

Emanuel Cino
on 11/5/14, 4:48 AM 6,861 views

I have a very long process of invoice generation and validation that works when I do it from the browser (even if it takes several hours to complete). I created a cron task that executes the same process. I can see that the cron successfully starts, but it seems to never finish. It must be silently killed, because I can see no error.

Do you know if there is some timeout for the cron tasks ? If so, how can I change this setting in order to increase the timeout limit ?


Atchuthan - Technical Consultant, Sodexis Inc

--Atchuthan - Technical Consultant, Sodexis Inc--
| 5 5 8
Puducherry, India
--Atchuthan - Technical Consultant, Sodexis Inc--
Passionate coder in Python/Odoo(formerly known as OpenERP).

Contact me via GMail: atchuthantu@gmail.com via Skype: atchuthan_skype
via Linkedin: http://in.linkedin.com/in/atchuthantu
Atchuthan - Technical Consultant, Sodexis Inc
On 11/5/14, 4:59 AM

no time-out is set at CRON job.

but the openerp-server has a time-out.  

1. If time-out needs to be increased, you need to configure openerp-server parameters.

These are the basic options available at OpenERP.

  Multiprocessing options:
    --workers=WORKERS   Specify the number of workers, 0 disable prefork mode.
                        Maximum allowed virtual memory per worker, when
                        reached the worker be reset after the current request
                        (default 671088640 aka 640MB).
                        Maximum allowed virtual memory per worker, when
                        reached, any memory allocation will fail (default
                        805306368 aka 768MB).
                        Maximum allowed CPU time per request (default 60).
                        Maximum allowed Real time per request (default 120).
                        Maximum number of request to be processed per worker
                        (default 8192).

2. After every update of record, if it is successful. force the cursor to commit

except Exception as e:
      Handle exception if needed

By doing this, you could avoid processing the same records if the CRON job is killed due to TIME-OUT.

Thank you very much for this complete answer. If I have no timeout when I do the request from the browser, does it mean that my issue is not a server timeout ? Why would it be different when executing by a cron ? Nice tip for the commit, I will try to use it.

Emanuel Cino
on 11/5/14, 5:24 AM
Luis Planes
On 9/15/17, 4:35 AM

Very googd. 

I solved my problem with the following values:



About This Community

This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.


Odoo Training Center

Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.

Test it now

Question tools

1 follower(s)


Asked: 11/5/14, 4:48 AM
Seen: 6861 times
Last updated: 9/15/17, 4:35 AM