i download a module like purchasing, but when i clicked print and choose Purchase Order, i got that error:
Wkhtmltopdf failed (error code: -11). Memory limit too low or maximum file number of subprocess reached. Message :
I'm using odoo14 and MacOS
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- CRM
- e-Commerce
- Accounting
- Inventory
- PoS
- Project management
- MRP
This question has been flagged
i made it like this on odoo.conf:
limit_memory_hard = 900000000000000
limit_memory_soft = 2147483648
limit_request = 8192
limit_time_cpu = 60
limit_time_real = 120
limit_time_real_cron = -1
but still error, and i already check my Wkhtmltopdf:
wkhtmltopdf --help
Name:
wkhtmltopdf 0.12.6 (with patched qt)
The error you’re encountering with Wkhtmltopdf and Odoo 14 on MacOS suggests that the memory limit is too low or the maximum number of files that can be opened by a subprocess has been reached. Here are a few steps you can try to resolve this issue:
Increase the Memory Limit: You might need to increase the limit_memory_hard parameter in your Odoo configuration file. This sets the maximum allowed memory per worker1.
Increase File Descriptors Limit: The error could also be due to the limitation of max handle file per process. You can increase this limit by running the command ulimit -n 10000 in your terminal.
Check Wkhtmltopdf Installation: Ensure that Wkhtmltopdf is installed correctly on your system. You can test it by running wkhtmltopdf --help from the command line to see if it works.
Modify the Report Template: If the error occurs when generating large PDFs or when empty content is drawn on the last page, you might need to adjust the report template. For instance, setting the table width to 99% can sometimes prevent the error by ensuring there’s content on the last page.