When a request lasts longer than 100 seconds I get an error message Connection Lost and Connection Restored after 100 seconds.
When uploading I get the following error message after 100 seconds.
An unknown issue occurred during import (possibly lost connection, data limit exceeded or memory limits exceeded). Please retry in case the issue is transient. If the issue still occurs, try to split the file rather than import it at once.
This only happens when I enable the Nginx reverse proxy, My Nginx Config File
# Odoo servers
upstream odoo {
server 127.0.0.1:8069;
}
upstream odoochat {
server 127.0.0.1:8072;
}
# HTTP -> HTTPS
server {
listen 80;
server_name example.com;
add_header Strict-Transport-Security max-age=2592000;
include snippets/letsencrypt.conf;
return 301 https://example.com$request_uri;
}
server {
listen 443 ssl http2;
server_name example.com;
if ($host != "example.com") {
return 404;
}
# increase proxy buffer to handle some OpenERP web requests
proxy_buffers 16 64k;
proxy_buffer_size 128k;
proxy_read_timeout 7200s;
proxy_connect_timeout 7200s;
proxy_send_timeout 7200s;
send_timeout 7200s;
# Proxy headers
proxy_set_header X-Forwarded-Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header X-Real-IP $remote_addr;
# SSL parameters
ssl_certificate /etc/letsencrypt/live/example.com/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/example.com/privkey.pem;
ssl_trusted_certificate /etc/letsencrypt/live/example.com/chain.pem;
include snippets/ssl.conf;
include snippets/letsencrypt.conf;
keepalive_timeout 90;
# log files
access_log /var/log/nginx/odoo.access.log;
error_log /var/log/nginx/odoo.error.log;
# Handle longpoll requests
location /longpolling {
proxy_pass http://odoochat;
}
# Handle / requests
location / {
proxy_redirect off;
proxy_pass http://odoo;
}
# Cache static files
location ~* /web/static/ {
proxy_cache_valid 200 90m;
proxy_buffering on;
expires 864000;
proxy_pass http://odoo;
}
# Gzip
gzip_types text/css text/less text/plain text/xml application/xml application/json application/javascript;
gzip on;
}
My Odoo Config File
; This is the password that allows database operations:
admin_passwd =password
db_host = False
db_port = False
db_user = odoo14
db_password = False
addons_path = /opt/odoo14/odoo/addons,/opt/odoo14/odoo-custom-addons,/opt/odoo14/enterprise
proxy_mode = True
xmlrpc_interface = 127.0.0.1
netrpc_interface = 127.0.0.1
limit_memory_hard = 68451041280
limit_memory_soft = 57042534400
limit_request = 8192
limit_time_cpu = 1800
limit_time_real = 3600
max_cron_threads = 1
workers = 5
db_maxconn = 3
logfile = /var/log/odoo14/odoo.log
dbfilter = ^production.*$
If I disable the Nginx reverse proxy and just go directly to odoo I dont have the issues
Any ideas...
Thank you
P.S. I there is no clues in the odoo log or nginx error / access logs
Environment Odoo 14 on Ubuntu 20.04
Hello,
Did you find a solution for this? I'm also have the same issue
Hi,
Yes the problem was cloudflare timeout, as its not possible to increase this on cloudflare I just created a subdomain for my staff to use and set cloudflare to dns only instead of proxied
https://stackoverflow.com/questions/38536167/is-it-possible-to-increase-cloudflare-time-out