Skip to main content
Odoo Community Association

Database Size

Beta License: AGPL-3 OCA/server-tools Translate me on Weblate Try me on Runboat

Monitor the size of your Odoo instance.

Table of contents

Configuration

To configure this module, you can review the scheduled action called ‘Take model size measurements’ and check the time at which you want it to run. It should only run once a day. If it runs more often, it just updates the existing set of sizes for the day.

You may also review the Database Size settings in Odoo’s general settings and enable ‘Purge Older Model Size Measurements’. This task will by default delete most daily data older than a year except for the data captured on the first day of each month. These retention periods can be configured here as well.

Usage

You can use this module to keep an eye on the development of the size of your Odoo instance over time. Every day, a snapshot will be taken with the full size of the database and the attachments. You can query these daily snapshots, and you can compare the current size with a size at any date of the past for which there is data.

Enable debug mode, then go to menu Settings -> Technical -> Database Size.

image1

The data that is gathered and that is displayed are:

  • Model Name - The name of the model to which the data is related

  • Estimated Rows - The number of estimated rows according to the Postgresql query planner. For performance reasons, taking the data from the planner is preferred over doing an actual count, although the results may be imprecise.

  • Bare Table Size - The disk usage of the model table without indexes etc.

  • Index Size - The disk usage of the indexes in the model table.

  • Many2many Tables Size - The disk usage of related many2many tables, including their indexes. To prevent double counts, many2many tables are only correlated with one of their tables (the largest of the two).

  • Attachment Size - The disk usage of the attachments linked to the model records. Because Odoo will deduplicate attachments by content, attachments with the same content may be counted double in the attachment size of other models, but will not be counted double when linked to records of the same model more than once.

  • Total Table Size - Bare Table Size + Index Size

  • Total Database Size - Total Table Size + Many2many Tables Size

  • Total Model Size - Total Database Size + Attachment Size

If you click on individual records, you can inspect the sizes of each index and many2many table.

All sizes are in megabytes.

In the ‘Compare Size per Model’ report view, you can find these data twice: once for the selected measurement date (default: today), and once for the selected comparison date (default: one month ago).

image2

If you want to compare arbitrary dates, you can start typing the date in the search box. Be sure to enter the dates in the right format for your localization.

image3

Bug Tracker

Bugs are tracked on GitHub Issues. In case of trouble, please check there if your issue has already been reported. If you spotted it first, help us to smash it by providing a detailed and welcomed feedback.

Do not contact contributors directly about support or help with technical issues.

Credits

Authors

  • Opener B.V.

Contributors

Maintainers

This module is maintained by the OCA.

Odoo Community Association

OCA, or the Odoo Community Association, is a nonprofit organization whose mission is to support the collaborative development of Odoo features and promote its widespread use.

This module is part of the OCA/server-tools project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.

Release files for odoo-addon-database-size 18.0.1.0.2.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distribution (wheel)

Table of built distributions (wheels) for odoo-addon-database-size 18.0.1.0.2.2
File Interpreter ABI Platform
odoo_addon_database_size-18.0.1.0.2.2-py3-none-any.whl Python 3 none any Details

Release files / odoo_addon_database_size-18.0.1.0.2.2-py3-none-any.whl

Download URL odoo_addon_database_size-18.0.1.0.2.2-py3-none-any.whl
Size 242.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b26a79dcf9309ad2a035ce47ce459f05d3b35888b2f2e650afe6054764165dcb
BLAKE2b-256 checksum
How to use checksums
6bba4eaf32fe6b8e7e905182c6408c2bc020a5ea5f874d5a1244c41afa0b8bfc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.3
Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page