Managing an Odoo instance effectively starts with mastering the odoo.conf file. With the release of Odoo 19, the framework continues its trend of streamlining parameters and enhancing performance defaults.
Whether you are migrating from Odoo 18 or setting up a fresh environment, understanding these configuration nuances is critical for system stability and security.
The Shift: Key Changes from Odoo 18 to 19
The most notable change in recent versions is the finalization of the "HTTP-first" naming convention. Odoo has moved away from legacy "xmlrpc" terminology to better reflect modern web standards.
Feature | Odoo 18 Parameter | Odoo 19 Parameter | Notes |
Primary Port | xmlrpc_port | http_port | The main port for web traffic (Default: 8069). |
Interface Binding | xmlrpc_interface | http_interface | Defines which IP the server listens on. |
Longpolling | longpolling_port | gevent_port | Often renamed or integrated further into the gevent stack. |
Essential Configuration Parameters
Below is a breakdown of a standard odoo.conf structure for Odoo 19.
1. Database Connectivity
These settings tell Odoo how to talk to your PostgreSQL server.
- db_host: Usually False if Postgres is on the same machine, or the IP address of your DB server.
- db_port: Default is 5432.
- db_user & db_password: The credentials for your Odoo database user.
2. Performance Tuning (Workers)
Odoo 19 thrives on a Multi-Processing mode.
- workers: Set this to $(CPU \times 2) + 1$. For a 2-core server, use 5.
- limit_memory_hard & limit_memory_soft: Prevents a single worker from consuming all system RAM.
3. Paths and Security
- addons_path: A comma-separated list of paths. Always include your custom enterprise or community modules here.
- admin_passwd: The "Master Password" used to create, drop, or backup databases via the UI. Change this immediately.
- list_db: Set to False in production to prevent unauthorized users from seeing your database names.
Sample Odoo 19 Configuration File
You can copy and adapt this template for your /etc/odoo.conf:
[options]
; Database settings
db_host = False
db_port = False
db_user = odoo
db_password = your_strong_password
; Updated Port Naming for Odoo 19
http_port = 8069
http_interface = 0.0.0.0
; Performance Tuning
workers = 3
limit_memory_hard = 2684354560
limit_memory_soft = 2147483648
limit_time_cpu = 600
limit_time_real = 1200
; Paths
addons_path = /opt/odoo/addons,/opt/odoo/custom_addons
; Security
admin_passwd = your_admin_secret_key
proxy_mode = True
list_db = False
Summary of Best Practices
- Use http_port: Stop using the legacy xmlrpc prefix to align with Odoo 19 standards.
- Enable proxy_mode: If you are using Nginx (which you should for SSL), this is mandatory to retrieve the correct user IP.
- Log Management: Set log_level = info and define a logfile path to troubleshoot issues without scrolling through the terminal.
