Database Auto Backup (filestore)

by
Odoo
v 14.0 Third Party 1957
Download for v 14.0 Deploy on Odoo.sh
Availability
Odoo Online
Odoo.sh
On Premise
Lines of code 178
Technical Name database_autobackup
LicenseOPL-1
Versions 10.0 14.0 12.0 13.0
You bought this module and need support? Click here!
Availability
Odoo Online
Odoo.sh
On Premise
Lines of code 178
Technical Name database_autobackup
LicenseOPL-1
Versions 10.0 14.0 12.0 13.0

Automate your database backup process easily

Prerequisites

- Make sure odoo user has write permission on the Backup Directory
- This module uses 'cURL' to backup database, so make sure that the 'cURL' is installed.
 The procedure to install cURL on Ubuntu is as follows:
   1- Update your Ubuntu, run: sudo apt update && sudo apt upgrade.
   2- Next, install cURL, execute: sudo apt install curl.
   3- Verify install of cURL on Ubuntu by running: curl --version.

Simple Configuration

- Click on the 'Database Auto Backup' menu
- Open 'Database Auto Backup' settings
- Enable auto backup and fill the settings form
- If your site is SSL secured please make sure SSL Enabled? toggle is active (Special thanks to Ricky for his note!)

Control Backup Duration

- Activate Developer Mode and go to 'Settings' -> 'Technical' and 'Open Scheduled Actions'
- Search for 'Database Auto Backup Cron'
- Update the duration by set 'Execute Every'

Contact Us

Algazali M. hamid

https://www.linkedin.com/in/algazali-hamid/

Khubab Shams

https://www.linkedin.com/in/kshamse

OR

Send us a whatsapp 'Hi!'

https://wa.me/message/NSTPT24R7LMUG1

Odoo Proprietary License v1.0

This software and associated files (the "Software") may only be used (executed,
modified, executed after modifications) if you have purchased a valid license
from the authors, typically via Odoo Apps, or if you have received a written
agreement from the authors of the Software (see the COPYRIGHT file).

You may develop Odoo modules that use the Software as a library (typically
by depending on it, importing it and using its resources), but without copying
any source code or material from the Software. You may distribute those
modules under the license of your choice, provided that this license is
compatible with the terms of the Odoo Proprietary License (For example:
LGPL, MIT, or proprietary licenses similar to this one).

It is forbidden to publish, distribute, sublicense, or sell copies of the Software
or modified copies of the Software.

The above copyright notice and this permission notice must be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.

Please log in to comment on this module

  • The author can leave a single reply to each comment.
  • This section is meant to ask simple questions or leave a rating. Every report of a problem experienced while using the module should be addressed to the author directly (refer to the following point).
  • If you want to start a discussion with the author, please use the developer contact information. They can usually be found in the description.
Please choose a rating from 1 to 5 for this module.
Can't run in docker, I don't know which user's password is master password
by
gavinguo
on 2/25/22, 2:48 AM
2022-02-25 07:43:21,905 35 INFO odoo14 odoo.addons.database_autobackup.models.autobackup_scheduler: :::: Autobackup Cron Started ::::
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0curl: (7) Failed to connect to erp14.localhost.com port 80: Connection refused
2022-02-25 07:43:21,933 35 INFO odoo14 odoo.addons.database_autobackup.models.autobackup_scheduler: :::: Autobackup Cron Feedback Unix Code (Backup): 1792 ::::curl --insecure -X POST -F "master_pwd=odoo" -F "name=odoo14" -F "backup_format=zip" -o /mnt/backups/odoo14_2022-02-25_07:43:21_db.zip http://odoo14.*****.com/web/database/backup
2022-02-25 07:43:21,933 35 INFO odoo14 odoo.addons.database_autobackup.models.autobackup_scheduler: :::: Autobackup Cron Finished ::::

database backup error
by
crocodile
on 2/11/22, 6:11 AM

2022-02-11 11:06:47,955 990235 ERROR ? odoo.addons.web.controllers.main: Database.backup 

Traceback (most recent call last):

  File "/opt/odoo/odoo/addons/web/controllers/main.py", line 1168, in backup

    dump_stream = odoo.service.db.dump_db(name, None, backup_format)

  File "<decorator-gen-19>", line 2, in dump_db

  File "/opt/odoo/odoo/odoo/service/db.py", line 41, in if_db_mgt_enabled

    return method(self, *args, **kwargs)

  File "/opt/odoo/odoo/odoo/service/db.py", line 241, in dump_db

    odoo.tools.exec_pg_command(*cmd)

  File "/opt/odoo/odoo/odoo/tools/misc.py", line 128, in exec_pg_command

    raise Exception('Postgres subprocess %s error %s' % (args2, rc))

Exception: Postgres subprocess ('/usr/lib/postgresql/12/bin/pg_dump', '--no-owner', '--file=/tmp/tmp89v98na4/dump.sql', 'odoo14web') error 1



setting
by
Ferreteria ERO
on 3/11/21, 8:10 AM

Hi, install and configure but it doesn't work. Is there a way to configure how long the backup takes?

Re: setting
by
Khubab Shams
on 3/11/21, 10:26 AM Author

Hi, I had just added screenshots to describe how to use the module, hope this will help, thanks for asking.


by
crocodile
on 2/11/22, 6:10 AM

2022-02-11 11:06:47,955 990235 ERROR ? odoo.addons.web.controllers.main: Database.backup 

Traceback (most recent call last):

  File "/opt/odoo/odoo/addons/web/controllers/main.py", line 1168, in backup

    dump_stream = odoo.service.db.dump_db(name, None, backup_format)

  File "<decorator-gen-19>", line 2, in dump_db

  File "/opt/odoo/odoo/odoo/service/db.py", line 41, in if_db_mgt_enabled

    return method(self, *args, **kwargs)

  File "/opt/odoo/odoo/odoo/service/db.py", line 241, in dump_db

    odoo.tools.exec_pg_command(*cmd)

  File "/opt/odoo/odoo/odoo/tools/misc.py", line 128, in exec_pg_command

    raise Exception('Postgres subprocess %s error %s' % (args2, rc))

Exception: Postgres subprocess ('/usr/lib/postgresql/12/bin/pg_dump', '--no-owner', '--file=/tmp/tmp89v98na4/dump.sql', 'webodoo14') error 1



Thanks for developing how to use the module,
by
gavinguo
on 10/27/21, 10:57 PM
    • Thanks for developing how to use the module, 

  • Add an option to backup the database directly for recovery,

  • Even better, it can be supported in docker environments  


by
Mohamed Adel
on 10/19/21, 4:23 AM

Hello,

Good effort.

how can I use this module on windows server?

Thanks


by
Muhammad Imtiaz Alam
on 6/3/21, 4:57 AM

Hi, 

Does this module works for Windows environment too?


Any schedule on deploying for Odoo v11 version users?
by
Andy
on 3/26/21, 2:53 AM



by
Andy
on 3/23/21, 11:14 PM

Is this module have Odoo v11?

Andy

Re:
by
Khubab Shams
on 3/24/21, 7:44 AM Author

Hi Andy, unfortunately, this module isn't available for odoo v11.


by
haris jiwani
on 3/16/21, 2:50 AM

in the given screenshot you have pass the path but when i pass the same path it does not download backup to the same directory please guide regarding this

Re:
by
Khubab Shams
on 3/16/21, 10:46 AM Author

Hi, just make sure to give the write permission on this directory to the odoo user. thank you