Disabling the Odoo database manager and securing the master password

Odoo's database manager lets anyone with the master password create, copy, drop or back up databases. This page explains how to turn it off in production, protect the master password and recover from a lost one.

On this page

Why the Odoo database manager and master password need hardening before go-live

A self-hosted Odoo server with the /web/database screens still reachable is a serious exposure, and it should be closed before the server is reachable from the internet. The database manager is the built-in interface for creating, duplicating, dropping, backing up and restoring Odoo databases. Anyone who can reach those screens and knows the master password can act on every database the server hosts, including copying live business data out of it or deleting it. The master password is the admin_passwd setting in the Odoo configuration file. It protects those database manager operations, so it is separate from the login password of any Odoo user, and a weak or default value turns the screens into an open door.

Teams usually need this hardening at two points. The first is before any public exposure, when the server, its reverse proxy and its DNS record go live and the database manager becomes reachable by anyone scanning the address. The second is during staging work, when a production database is duplicated for testing or an upgrade rehearsal. Duplicated databases often carry real customer and employee records, and the screens that make those copies are the same ones an outsider would target. Before go-live, the operator should decide who is allowed to create or restore databases, where those operations are performed, and whether the screens are needed at all. Confirm the exact behavior of the database manager, the list_db setting and the master password handling for your Odoo version in the Odoo on-premise documentation and in your own test environment before you change production.

Which configuration option fits each production situation

This table compares the ways to close or limit the Odoo database manager and protect the master password, with the situation each option suits. Read each row against your hosting model: a single-company server with one database has different needs from a shared host that creates databases on request. The main takeaway is that most production servers should combine a fixed database name, list_db set to False and a random admin_passwd, and only keep the manager reachable when an operator workflow truly needs it.

OptionWhen it fitsWhat it breaksWhat to confirm in your version
list_db set to FalseProduction servers with one database that users reach by a fixed URLDatabase selector and manager screens disappear, so operators cannot create or switch databases from the browserConfirm the key name and behavior in the config reference for the Odoo version you run
db_name set to a fixed database nameSingle-database deployments where the server should always open the same databaseMulti-database hosting and any workflow that expects the server to pick a database from the requestConfirm how db_name interacts with dbfilter and whether your version still reads it at startup
dbfilter limiting visible databasesShared PostgreSQL servers hosting several Odoo databases behind one domain or subdomain patternRequests whose host name does not match the pattern, and databases that do not follow your naming conventionConfirm the dbfilter regex against each hostname your proxy forwards, including test and staging names
Proxy blocking of /web/databaseEnvironments where the database manager must stay enabled for operators but should not be reachable from the internetRemote backup, restore and duplication from the browser if the proxy blocks the path for all clientsConfirm the exact paths your version serves for database screens and test the block from outside your network
Randomly generated admin_passwdEvery production server, as the master password that guards database create, drop, backup and restoreAny script or runbook that relies on the old master password, which must be stored in your secrets vaultConfirm that the value is set in the config file or environment and that the server restarts to apply it
Lost master password resetRecovery when the password is unknown and no one on the team has it recordedRequires shell access to the server and a config change, so it should be done under change controlConfirm the procedure with your Odoo version's documentation and record who approved the change

Steps to turn off the database manager and set the master password

This sequence removes the public database selector from a self-hosted Odoo server and replaces the master password with a long random value, so only the one production database is reachable and the password that controls database operations is protected.

  1. Confirm the current database manager exposure

    Before changing anything, the server administrator requests /web/database/selector and /web/database/manager from a machine outside the office network and records the responses. Note whether the page lists databases and whether a master password prompt appears. Keep the output with the change record so you can compare it after the restart. If the page answers without a prompt or lists databases, treat the server as exposed and continue with this sequence before any other hardening work.

  2. Generate and vault a random admin password

    Generate a long random value with a cryptographically secure generator on a trusted workstation, then store it in your secrets vault with restricted read access for the two or three administrators who need it. The value becomes the admin_passwd setting. Do not reuse a password from another system, and do not write it into a ticket, wiki page or chat. Done means the vault entry exists, its access list is recorded, and nobody on the team holds the value in a personal note.

  3. Set admin_passwd and list_db in the configuration file

    Edit the Odoo configuration file, typically named odoo.conf, and set admin_passwd to the vaulted value and list_db to False. Odoo reads these keys from the file at startup, so the change takes effect only after a restart. Keep the password out of shell history, process arguments and version control. Done means both keys appear in the file and a test read of the file shows the expected values without printing the password to a log.

  4. Pin the production database with db_name or dbfilter

    Set db_name to the name of the single production database, or use dbfilter with a pattern that matches only that database. This tells Odoo which database to serve for each incoming hostname. Test the pattern against every hostname that reaches the server, including internal names and health checks, because a pattern that matches nothing will break login. Done means each expected hostname resolves to the production database in a test request and no other database name is served.

  5. Check configuration file permissions

    Confirm that the configuration file is readable by the Odoo service account and by no other local user. Run a listing of the file with its owner, group and mode, and restrict it to the service account and the administrators who maintain the server. The file holds the master password hash or value and database connection details, so group or world read access is a finding. Done means the listing shows owner-only or owner and a single admin group access, and the change is recorded with the date and person.

  6. Restart the Odoo service

    Restart the Odoo service with your service manager so the new settings load. Watch the startup log for errors about the configuration file, the database name or the connection to PostgreSQL. A failed start with a bad dbfilter pattern is common, so have the previous configuration available to restore. Done means the service reports running, the web client loads for a normal user session, and the log shows no configuration warnings.

  7. Confirm the database manager no longer answers

    Repeat the requests from the first step from outside the network. /web/database/selector and /web/database/manager should no longer list databases or accept the master password. Also confirm that the production login page still loads through the proxy. Record both results next to the baseline. Done means the database manager returns a refusal or redirects away, and the production site works for a test user.

  8. Verify the proxy rule blocks database manager paths

    Where the proxy is in front of Odoo, confirm that a rule denies requests to /web/database paths, or that the rule was deliberately kept and is limited to trusted addresses. Send a request through the proxy from an untrusted address and check the status code. If the database manager must stay reachable for a migration, restrict it to an administrative network and record the owner and removal date. Done means the proxy test returns a denial and the rule is in version control or the change record.

Blocking /web/database at the reverse proxy when the screens must stay

Blocking /web/database at the reverse proxy is the fallback when the database manager must remain reachable, for example under a managed multi-database hosting model or during a controlled administration window. Keep the application's own setting as the primary control and treat the proxy rule as a second layer. Limit the path to a named source network, a VPN address range or a bastion host, and deny everything else with a 403 or 404 response. Cover both the path and the URL-encoded and trailing-slash variants that the proxy matches, and confirm the rule with your proxy's own configuration test before reloading.

The main risk is bypass. A proxy rule only protects the screens if clients can reach Odoo only through that proxy. If the application server port is open on the network, an attacker or a misconfigured internal host can request /web/database directly and skip the rule entirely. Confirm that the Odoo port is bound to localhost or a private interface and that the firewall allows only the proxy to reach it. Also check that no second virtual host, load balancer or health check route forwards to the application server without the same rule.

Test the rule from two vantage points. From outside the network, requests to /web/database from an address not on the allow list should fail, and the same request should fail when it is sent directly to the application port. From inside the allowed network or VPN, the screens should load. Record the results, repeat the tests after every proxy change, and ask your team to confirm which source ranges are permitted and who approves changes to that list.

Security and operational risks of the master password and database screens

The database manager gives anyone holding the master password the power to create, drop, back up and restore whole databases. The cards below cover the most common ways that power leaks out of the team that should hold it, and the control and owner role that keep it contained.

Master password stored in plain text

The admin_passwd value often ends up in a shared configuration file, a wiki page or a chat thread during installation. Anyone who can read that file can create, drop or restore any database on the server. Keep the value in a secrets manager, restrict read access on odoo.conf to the service account, and have the platform owner confirm where the value is stored. Check the file permissions on every server.

Database screens reachable from the internet

When /web/database answers on a public hostname, any visitor who guesses or steals the master password can manage databases without signing in to Odoo. Set list_db to off, define db_name so Odoo does not have to guess the database, and block the database paths at the reverse proxy if the screens must stay reachable. The network or security engineer should test this from outside the network.

Source installation docs

Master password in shared tickets

Installers often paste the master password into a support ticket, a deployment request or a chat so a colleague can finish setup. Those copies persist in tool histories, exports and backups of the ticketing system, and they outlive the people who wrote them. Store the value once in an approved vault, share access by role, and have the IT service owner remove any copies found in ticket history.

Rotation that lags staff changes

The master password is shared by everyone who ever operated the server, so a departure leaves a working credential behind. Rotation rarely happens because no one owns the change and it breaks scripts that rely on the old value. Assign one named owner, record the rotation date, and rotate after any administrator leaves or any copy may have been exposed. The head of platform engineering should own the schedule.

Duplicated databases carrying live data

Copying a production database to create a test or staging environment gives the test system real customer, employee and financial records, often with the same integrations and outbound email still active. Odoo documents database duplication with neutralization for test copies, which is designed to disable live connections in the copy. The compliance lead should decide who may request a copy, and the QA lead should confirm neutralization ran before anyone logs in.

On-premise docs

Lost access after a change

If the master password is changed without a recorded copy, or if the only person who knows it leaves, the team may be unable to duplicate, back up or restore databases during an incident. Keep a sealed, access-controlled copy in the vault, test the recovery path on a non-production server, and document the steps to reset the value by editing the configuration file on the server. The platform owner should sign off the procedure before the first production change.

Resetting a lost master password without losing data

This sequence restores administrative access to the database manager by setting a new admin_passwd in the server configuration, while leaving every user's password and every database untouched.

  1. Confirm who controls the configuration file

    Identify the people and service accounts that can read and write the Odoo configuration file on the server, and confirm that the change will be made by someone already authorized to administer that host. Record the file path for your install method, whether that is a packaged installer, a Docker deployment or a source install, and confirm the exact location against the on-premise documentation before touching anything. The step is done when you have a named owner and a confirmed file path in the change ticket.

  2. Open a change request and agree the rollback

    Raise the master password reset under your change control process, stating the host, the reason, the expected impact (a service restart) and who approves it. Agree how you will restore the previous configuration if the restart fails, for example by keeping a dated copy of the file. The step is done when the change is approved and the rollback copy is stored with the ticket.

  3. Generate a new random master password

    Create a long, random value for admin_passwd using a generator approved by your security team, and do not reuse a password from another system. Store the new value in your organization's secrets vault before editing any file, so that it is never lost again and only authorized staff can retrieve it. The step is done when the vault entry exists and a second authorized person can see that it was saved.

  4. Update admin_passwd in the configuration

    Edit the admin_passwd key in the Odoo configuration file so it holds the new value, keeping the file permissions restricted to the service account and administrators. Do not change database names, user records or any other key in the same edit. The step is done when a diff of the file shows only the admin_passwd line changed.

  5. Restart the Odoo service

    Restart the Odoo service using the mechanism your install method uses, such as the system service manager, the container orchestrator or the process supervisor for a source install. Watch the startup log for errors about the configuration file and confirm the service reports healthy. The step is done when the service is running and the log shows no configuration errors.

  6. Verify access to the database manager

    Sign in to the database manager with the new master password from the vault, and confirm that the list of databases appears only if listing is still enabled as intended. Then confirm that a regular user can still sign in to an existing database, which shows that user passwords were not affected. The step is done when both checks pass and the results are noted in the change ticket.

  7. Close the change and review exposure

    Close the change request with the time of the restart, the vault entry reference and the verification results, and confirm that the master password is not written into tickets, chat or shell history. Check whether the database manager should be disabled now that access is restored, and schedule that change if it is still needed. The step is done when the ticket is closed with evidence and the follow-up is assigned.

Limits to confirm in your environment before relying on these settings

The database manager and master password settings take effect differently depending on your Odoo version, install method and who manages your databases. Work through these checks before you treat a configuration change as a control, because a setting that works on a self-hosted server may not apply where a platform or provider controls the database layer.

Version and install method

Confirm which Odoo version and install method your servers run, whether packaged installer, source installation or Docker, and read the matching documentation for that version. The configuration keys and their defaults are the part most likely to differ between releases, so do not copy settings from a blog post or an older install guide without checking them against your version's docs.

On-premise docs

Hosting provider access needs

Ask your hosting or managed service provider whether their support or operations processes depend on the database manager. If they create, restore or duplicate databases through the web screens, disabling them can break their runbook. Get that dependency written down, and agree how they will create databases once the screens are off, such as through a controlled administrative procedure on the server.

Odoo.sh and Odoo Online behavior

On platforms where Odoo or a partner manages the database layer, the list_db and admin_passwd settings may not be yours to change. Confirm with the platform provider which controls you can access, which database operations you can perform yourself, and whether the master password applies to your instance at all. Do not assume a setting you change on a self-hosted server has the same effect on a managed environment.

Staging copies and test databases

Confirm whether your team creates staging or test copies through the database manager. Duplicating a database from the web screen is a common workflow, and blocking it can stop the copy process your testers rely on. Plan an alternative, such as a command-line duplication with neutralization of outgoing email, payment and integration settings, before you disable the screens in a shared environment.

On-premise docs

Proxy and network path rules

If you block /web/database at a reverse proxy instead of, or in addition to, disabling the screens in Odoo, confirm every path that reaches the manager, including any alternate hostnames, internal load balancers and health checks. Test the blocked path from outside your network and from any admin jump host you use, so you know the block holds where you expect it to.

Configuration file deployment

Confirm how your automation writes the Odoo configuration file, including whether it templates admin_passwd from a secrets store, whether a configuration management run can overwrite the file, and whether the running service reloads it. A correct setting in the repository does not protect a server if the deployed file differs, so verify the live file on each host after every deployment.

Questions teams ask about the Odoo database manager and master password

How long does it take to disable the Odoo database manager?

The change itself is small: setting list_db to False and db_name in the server configuration, then restarting the service. The effort comes from everything around it. Someone has to confirm every database name, check which proxy routes reach /web/database, schedule a restart window, and test each public hostname afterward. A single-instance install with one database and a known proxy setup is quick to verify. A host serving several databases, multiple proxies or load balancers, or unclear ownership of the configuration file takes longer. Ask any partner to base the quote on the number of databases, hostnames and servers in scope.

Can an internal team disable the database manager and set the master password alone?

Yes, if the team has shell access to the Odoo server, can edit the configuration file, and can restart the service. The steps are documented and low risk when done carefully. Teams usually struggle in three places: finding every route that exposes the database screens across the reverse proxy, generating and storing a new random admin_passwd in a vault instead of a wiki, and confirming that no automation still depends on creating or listing databases through the web. An outside partner adds value mainly when the environment is complex or when an independent check of the result is required for a compliance file.

What does the work need from our team before it starts?

It needs four things: SSH or console access to each Odoo server with rights to edit the configuration and restart the service, a change window agreed with the owners of the affected applications, a password vault where the new master password will be stored, and a list of hostnames and proxy configurations that reach the Odoo instance. Someone should also confirm which databases are in use and whether any integration, backup job or script calls the database manager. Without that list, the work tends to stop at the first unexpected dependency. Put these prerequisites into the written scope before work begins.

What changes for database duplication and test copies?

Once the database manager is off, staff can no longer duplicate or create databases from the browser, so copies for testing must be made from the command line or through the team's documented process. Odoo's on-premise documentation describes duplicating a database with neutralization, which disables features such as outgoing mail and scheduled actions on the copy so it cannot affect production. Confirm that every copy is neutralized, stored on a non-production host, and given its own credentials. Treat a copy that still has production mail or payment connections as an incident.

What should we do if the master password was leaked?

Treat it as a compromise. Change admin_passwd in the configuration file to a new random value, restart the service, and then review who could have used the old password. Anyone holding the master password can create, drop, back up, restore or duplicate databases, so check the database list, recent backups and any unexpected databases against your records. Review the web server and proxy logs for requests to /web/database from unfamiliar addresses. If you suspect data was taken or altered, involve your incident response process and retain logs before making other changes. Rotate any credentials stored on the same host.

How does this fit with the production security checklist and penetration testing?

Disabling the database manager and setting a strong master password is one item on the production security checklist for internet-facing Odoo servers, alongside the database name filter, a non-superuser PostgreSQL role, HTTPS, proxy limits and off-server backups. Penetration testing checks whether those controls work from the outside, so it will test whether /web/database still responds through any route. Complete the checklist first, record the configuration as evidence, and then ask the tester to retest the same paths. A pen test report alone does not prove the setting is in place on every server.

Does disabling the database manager affect Odoo upgrades or backups?

It can, if your process relies on the web screens. Upgrades, restores and backups done through the database manager will need a command line or documented alternative after the change. Odoo's upgrade documentation describes an upgraded test database that must be tested before production, so plan that test copy into the upgrade process. Check your backup jobs, which may call the same endpoints, and update the runbook so that staff know how to restore a database once the screens are off.

Every request to the database manager passes two checks before it opens

The diagram starts with a request to /web/database reaching the reverse proxy, which either blocks the path or passes it to the Odoo server. Odoo then checks whether list_db is enabled. If it is off, the database screens are not offered. If it is on, the master password decides whether the request is rejected or the database manager opens. The internal admin path is drawn separately, so administrators can still reach the screens without exposing them to the internet.

Request flow through the proxy, list_db setting and master password check.

How DeployOpen scopes and delivers Odoo database manager hardening

DeployOpen scopes database manager hardening as a fixed piece of work agreed in writing before any server is changed. The first step is a review of the current state: the Odoo server configuration file, the reverse proxy rules that front /web/database, the list of databases on the PostgreSQL server, and whether demo data or a shared admin password is still present. The output of that review is an inventory of every route and setting that exposes database management, along with the owner of each item. Where the client runs more than one Odoo instance, each one is listed separately, because proxy rules and configuration files often differ between them.

Once the inventory is agreed, the written scope sets out the change and the retest. The change covers the settings that turn off database listing and pin db_name or dbfilter, the replacement of the admin_passwd value with a random secret held in the client's secrets store, and any proxy block on /web/database where the screens must stay for a short period. The retest covers requests sent from outside the client's network, confirming that the database manager is unreachable and that the master password can no longer be used. DeployOpen implements the settings with the client's infrastructure and security team, so that the people who will restart services and rotate the secret know the new procedure. Ongoing checks after go-live, such as re-testing after an upgrade, are available under a retainer.

Sources and further reading

Talk to our team.

Tell us what you're working on, whether it's a deployment, an audit, a security test or a cyber range. You'll speak with an engineer who can help you scope it.

  • 30-minute call: free, with no obligation.
  • NDA on request: we can sign before you share details.
  • Clear next steps: a scope and plan after the call.