İçereği Atla
Menü
Bu soru işaretlendi
4 Cevaplar
4569 Görünümler

Hello,

I am trying to enable workers for odoo 17.0 local development.

as per documentation; I added workers = 2 in the odoo.conf file. 
odoo.conf file looks like:
limit_time_cpu = 86400
limit_time_real = 86400
limit_memory_soft = 13538884000
limit_memory_hard = 140388840001
max_cron_threads = 1
workers = 2

but I get the error as:

RuntimeError: Couldn't bind the websocket. Is the connection opened on the evented port (8072)?

Please help me set it up correctly.


Avatar
Vazgeç
En İyi Yanıt

Are you Debugging? Websocket wont start if you are debugging or using --dev

Avatar
Vazgeç
En İyi Yanıt

Update your odoo.conf as follows:

limit_time_cpu = 86400
limit_time_real = 86400
limit_memory_soft = 13538884000
limit_memory_hard = 140388840001
max_cron_threads = 1
workers = 2
longpolling_port = 8072
xmlrpc_interface = 127.0.0.1
netrpc_interface = 127.0.0.1
proxy_mode = True  # If you are using a reverse proxy like Nginx

After updating your odoo.conf file, restart the Odoo service:


Avatar
Vazgeç
En İyi Yanıt

This warning occurs because you haven't specified the gevent_port number, and your server's longpolling_port is active. You have two options to resolve this:

  1. Disable Longpolling: Set longpolling_port = False in your configuration.
  2. Specify Gevent Port: Assign a value to gevent_port, for example, gevent_port = 9090.

odoo.config file

longpolling_port = False
gevent_port = 9090

Please note that if you're hosting multiple Odoo instances, the gevent_port should be different for each instance to avoid conflicts, as the longpolling_port will still be running on the server.

Let me know if you need any further assistance!

Avatar
Vazgeç
En İyi Yanıt

Port 8072 might be already in use by another application on your system.

Solution: Check if any other application is listening on port 8072. If so, either stop the conflicting application or change the port used by Odoo.

Avatar
Vazgeç
İlgili Gönderiler Cevaplar Görünümler Aktivite
2
Kas 24
1689
1
Şub 25
1545
1
Ağu 25
128
1
Ağu 25
287
4
Tem 25
1627