How to install Odoo 20 on Ubuntu 24.04: by hand, or in a few clicks
Install Odoo 20 on Ubuntu 24.04 the way Odoo's documentation describes: Python 3.12, PostgreSQL 16, wkhtmltopdf, rtlcss, systemd, nginx and HTTPS. Or let Knova Cloud do it.
By Muhammad Salman Ali Khan, Founder, Knova Digital Solutions · Published · 8 min read · Odoo installation, Ubuntu, Odoo 20, Your own server
Odoo 20 raised its minimum requirements, and Ubuntu 24.04 LTS is the release that meets them out of the box. This guide installs Odoo 20 on a fresh Ubuntu 24.04 server following Odoo's own 20.0 documentation, with the production details that the documentation leaves to you: a service that restarts itself, sensible workers, the database manager hidden, HTTPS, and backups. At the end, you'll see how Knova Cloud does the same on your server in a few clicks.
Every requirement below comes from the official Odoo 20.0 documentation, checked on 8 October 2026; the sources are listed at the end.
Odoo is a trademark of Odoo S.A. Knova Cloud is an independent service, not affiliated with or endorsed by Odoo S.A.
What changed in Odoo 20
Three changes matter when you install Odoo 20 on a server:
- Python 3.12 or later. Odoo 20 raised the minimum from Python 3.10 to 3.12. Ubuntu 24.04 ships Python 3.12; Ubuntu 22.04 ships 3.10, which is no longer enough.
- PostgreSQL 16 or later. The minimum went from PostgreSQL 13 to 16. Ubuntu 24.04's own
postgresqlpackage is version 16. - pgvector for the AI features. Odoo's AI features need the pgvector extension in PostgreSQL. Ubuntu 24.04 packages it as
postgresql-16-pgvector.
Odoo 20's official .deb package also lists Ubuntu 24.04 (Noble) as the supported Ubuntu release. In short: use 24.04, not 22.04.
Before you start
You need:
- An Ubuntu 24.04 server you can reach as root over SSH, with at least 2 GB of memory for a small team. More users need more workers and more memory; our Odoo workers calculator applies Odoo's sizing rule to your numbers.
- A domain name (for example
erp.example.com) whose A record points to the server, if you want HTTPS. - An Odoo Enterprise subscription only if you install Enterprise. Community needs none.
There are two ways to install: Odoo's package repository, which is quick, or the source code in a virtual environment, which gives you more control and is what the rest of this guide follows.
The quick way: Odoo's package
Odoo publishes nightly Community packages for 20.0. Its packaging page gives these commands:
wget -q -O - https://nightly.odoo.com/odoo.key | sudo gpg --dearmor -o /usr/share/keyrings/odoo-archive-keyring.gpg
echo 'deb [signed-by=/usr/share/keyrings/odoo-archive-keyring.gpg] https://nightly.odoo.com/20.0/nightly/deb/ ./' | sudo tee /etc/apt/sources.list.d/odoo.list
sudo apt-get update && sudo apt-get install odooInstall PostgreSQL first (sudo apt install postgresql -y) and wkhtmltopdf separately (step 2 below). The package runs Odoo as a service, creates its PostgreSQL user and updates with apt-get upgrade. There is no nightly repository for Enterprise; Enterprise packages come from Odoo's download page. Odoo itself notes that nightly packages can be hard to keep up to date, which is one reason many teams prefer the source install below.
1. System packages and PostgreSQL 16
Update the server, then install PostgreSQL, Git, Node.js and the libraries Odoo's Python packages are built against:
apt-get update && apt-get upgrade -y
apt-get install -y postgresql postgresql-16-pgvector git nodejs npm \
python3-venv python3-dev build-essential libpq-dev libldap2-dev libsasl2-dev \
libxml2-dev libxslt1-dev libjpeg-dev zlib1g-devLeave out postgresql-16-pgvector if you won't use the AI features. Then create a system user for Odoo and a PostgreSQL role that can create databases but is not a superuser (Odoo refuses to connect as postgres):
adduser --system --group --home /opt/odoo odoo
sudo -u postgres createuser --createdb odooThe role has the same name as the system user, so Odoo connects through the local socket without a password.
2. wkhtmltopdf and rtlcss
wkhtmltopdf prints every PDF report. Odoo's documentation asks for version 0.12.6 with patched Qt, installed manually, so that headers and footers work; Ubuntu's own package is not that build. The wkhtmltopdf project's latest release (0.12.6.1-3) has no package for 24.04; the 22.04 (jammy) one installs on 24.04 with apt resolving its dependencies:
apt-get install -y ./wkhtmltox_0.12.6.1-3.jammy_amd64.debDownload the file from the project's releases page first, and print a test invoice after the install to check headers and footers.
rtlcss is required for right-to-left languages such as Arabic or Hebrew. If anyone will use Odoo in Arabic, install it now:
npm install -g rtlcss3. Odoo 20 in a virtual environment
Clone only the 20.0 branch, then install its Python requirements into a virtual environment that belongs to Odoo:
sudo -u odoo git clone --depth 1 --branch 20.0 https://github.com/odoo/odoo.git /opt/odoo/odoo
sudo -u odoo python3 -m venv /opt/odoo/venv
sudo -u odoo /opt/odoo/venv/bin/pip install -r /opt/odoo/odoo/requirements.txt
mkdir -p /opt/odoo/custom-addons /var/log/odoo && chown odoo: /opt/odoo/custom-addons /var/log/odooOdoo's documentation also offers sudo ./setup/debinstall.sh, which installs the dependencies as Ubuntu packages instead. Pick one; the virtual environment keeps Odoo's Python packages apart from the system's. For Enterprise, add the Enterprise addons from Odoo's download page (or the odoo/enterprise repository, 20.0 branch, if your account has access) and put them first on the addons path, as the documentation requires.
4. The configuration file
Create /etc/odoo/odoo.conf, owned by root:odoo and readable by the group only (chmod 640):
[options]
admin_passwd = a-long-random-master-password
db_user = odoo
addons_path = /opt/odoo/odoo/addons,/opt/odoo/custom-addons
http_interface = 127.0.0.1
proxy_mode = True
list_db = False
workers = 3
max_cron_threads = 1
limit_memory_soft = 2147483648
limit_memory_hard = 2684354560
logfile = /var/log/odoo/odoo.logThe lines that matter most:
admin_passwd: the master password of the database manager. Never keep the default.list_db = False: hides the database list and manager from the login page.http_interfaceandproxy_mode: Odoo listens locally, behind nginx, and trusts nginx for the visitor's address and HTTPS, as Odoo's deployment guide requires behind a proxy.workers: Odoo's guide estimates 1 worker per 6 concurrent users, at most (CPU cores × 2) + 1 per server, with about 150 MB for a light worker and 1 GB for a heavy one.
Add a logrotate rule for /var/log/odoo/odoo.log so the log doesn't fill the disk.
5. A systemd service
Create /etc/systemd/system/odoo.service:
[Unit]
Description=Odoo 20
After=network.target postgresql.service
[Service]
Type=simple
User=odoo
Group=odoo
ExecStart=/opt/odoo/venv/bin/python3 /opt/odoo/odoo/odoo-bin -c /etc/odoo/odoo.conf
Restart=on-failure
[Install]
WantedBy=multi-user.targetRun systemctl daemon-reload && systemctl enable --now odoo, then follow /var/log/odoo/odoo.log until it reports that the modules are loaded.
6. nginx and HTTPS
Install nginx and certbot (apt-get install -y nginx certbot python3-certbot-nginx). With workers, live chat and notifications use /websocket, served by Odoo's gevent process on port 8072, so nginx sends that path there:
upstream odoo { server 127.0.0.1:8069; }
upstream odoochat { server 127.0.0.1:8072; }
server {
listen 80;
server_name erp.example.com;
client_max_body_size 100m;
location /websocket {
proxy_pass http://odoochat;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_set_header X-Forwarded-Host $http_host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
}
location / {
proxy_pass http://odoo;
proxy_set_header X-Forwarded-Host $http_host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
}
}Check it with nginx -t, reload nginx, and run certbot --nginx -d erp.example.com for a Let's Encrypt certificate that renews itself. Allow only SSH, 80 and 443 in the firewall; never expose 8069, 8072 or PostgreSQL's 5432.
7. Create the database, then look after it
Open https://erp.example.com and create your database with the admin email, the country (it installs the right accounting localization) and the apps you need. The work that follows never ends: daily backups stored off the server and restored now and then to prove they work, security updates for Ubuntu, monitoring of Odoo, the disk and the certificate, and upgrades before your version runs out of support.
Or: let Knova Cloud install it on your server
Everything above is what Knova Cloud's installer does on your own server, plus the operations afterwards. Link the server with one command, click Install Odoo, choose 20.0 (or 17.0 to 19.0), Community or Enterprise, your domain, language and apps, and review the plan before it runs:
- Native or Docker, depending on the server's Python;
- workers and memory limits computed from the server's CPUs and memory, with the math shown;
- hardened by default: a random master password, the database list off, its own system user and log rotation;
- HTTPS as soon as your domain points to the server.
The install takes about 8 to 15 minutes and you follow it live. If it fails, the installer removes what it created and the payment is refunded in full. Then the server gets monitoring, daily backups with weekly restore tests, a security audit and a recorded web terminal. See installing Odoo on your own server and the pricing page for the current prices.
Sources
- Odoo 20.0 documentation, Source install: Python 3.12, PostgreSQL 16, pgvector,
debinstall.sh, rtlcss and wkhtmltopdf 0.12.6. - Odoo 20.0 documentation, Packaged installers: the nightly repository and Ubuntu 24.04 support.
- Odoo 20.0 documentation, System configuration: workers, memory, proxy mode and the websocket.
- wkhtmltopdf, packaging releases: release 0.12.6.1-3 and its packages.
- Ubuntu, pgvector in 24.04: the
postgresql-16-pgvectorpackage.