Upgrading Odoo
The Upgrade tab on a production or staging branch runs Odoo’s official database upgrade and switches the instance to the new version in one operation. It uses the upgrade service at upgrade.odoo.com, so it requires an Odoo Enterprise subscription.Requirements
- Odoo Enterprise. Your project must have an Enterprise subscription code saved in Project Settings. Without it the tab shows “Odoo Enterprise required”. See Odoo Enterprise.
- Backup storage. The pre-flight check verifies backup storage is configured. A production upgrade will not start without a pre-upgrade backup.
- Role. You need the owner, administrator or developer role on the project.
- A production or staging branch. Development branches do not have the Upgrade tab.
- The feature enabled on your project. Upgrades are rolled out per project. If you do not see the tab, contact support@doploy.io.
Test mode and production mode
Test mode asks Odoo to upgrade a copy of your database. When the copy comes back, doploy replaces the instance’s database with the upgraded copy and switches the instance to the new version. Your original data is kept in the pre-upgrade backup. On staging branches test mode is the only mode. Production mode upgrades the database in place. The instance goes offline for the whole run. On production branches you choose between the two, and production mode asks you to confirm that you have already tested the upgrade on staging. Run the upgrade in test mode on a staging branch as many times as you need. That is where you find out which custom modules break and fix them.What happens
- Preparing. doploy creates a backup of the database. In production mode the upgrade is cancelled if this backup fails. When the target is 20.0 or newer and the instance’s PostgreSQL container is not yet PostgreSQL 17 with pgvector (instances created on 15.0 to 18.0), doploy first moves the database to a new PostgreSQL 17 with pgvector container. The pre-flight check tells you when this will happen. The old data directory stays on the server until you delete it.
- Upgrading. The Odoo container is stopped so nothing writes to the database. doploy downloads the official upgrade script and runs it against your PostgreSQL container. Odoo receives a dump, upgrades it, and returns it. This step can take from minutes to several hours depending on database size.
- Switching version. doploy rebuilds the instance container from the target version’s base image, updates the Odoo source and Enterprise addons to the target version, and starts the instance. The branch’s Odoo version is updated to match.
If it fails
Failed upgrades appear in Upgrade History with a message explaining where they stopped. If a pre-upgrade backup exists, a Rollback button restores it. Test-mode runs with a failed backup show a warning and have no rollback point. Custom modules that do not install on the new version are the usual cause of a failed switch. Fix the module on a development branch, merge, and run the upgrade again.Before upgrading to 20.0
Odoo 20.0 has larger framework changes than the last few releases. Work through this list on staging before touching production:- Read the 20.0 section of Supported Odoo Versions for the API changes.
- Search your modules for
security/ir.model.access.csvfiles andmodel="ir.rule"records. Each one needs converting tosecurity/ir.access.csv. - Search your JavaScript for
this.props,t-ref,onWillUpdatePropsandstatic defaultProps. These are OWL 3 changes. - Search your Python for
api.Self,registry.clear_cacheand list-valued_rec_names_search. - Check whether any module you depend on was folded into core or renamed in 20.0 (for example
base_vatandbase_ibanare now part ofbase,stock_picking_batchis part ofstock). - Run the upgrade in test mode on staging, install your modules, and click through the workflows your users rely on.
- Only then run the production upgrade, with a maintenance window sized for the time the staging run took.

