Odoo is the world's easiest all-in-one management software. It includes hundreds of business apps:
CRM | e-Commerce | Accounting | Inventory | PoS | Project management | MRP | etc.
I have a saas version of openerp and have made a backup of my database from the control centre. This produces a .zip file which extracts to a filestore folder (with sub-folders) and sql file. How can I now restore this to a local version of openerp? Do I use pgadmin as the local "manage database" option looks for a .bak file?
This issue was also raised in https://www.odoo.com/forum/help-1/question/export-setting-and-data-from-odoo-com-to-local-odoo-server-installation-54962 without a satisfactory answer.
If you are working on linux, and if it can be of your interest, I have made 2 scripts, the first to make backup, and the other one to restoring.
The backup script can be combined with cron to make schudeled backups for a default database, or whatever database you want. This backup script creates a compressed backup with a name compound by the database name and the date of the backup. Also it creates (or overwrites) a backup file called yourdb_last_backup, wich is very comfortable to use with the restore script. Using the restore script without parameters, restores the last backup, or you can restore your desired file indicating it as parameter.
Other interesting functions of these scripts are addons backup, and autodelete backups older than the days of your choice.
If you would like to try these scripts contact me. I hope it helps.
You can do what Franz says but you can also do this all in one command.
You dump the database and pipe it directly into another one.
sudo -u postgresql pg_dump -h host1 dbname | psql -h host2 dbname (pg_dump -h host1 dbname | psql -h host2 dbname is taken directly from the PostgreSQL documentation)
So Let's say you have:
host1: openerp.example.com with username openerp
dbname host1: openerp
host2 : local (so leave this blank because it will go for localhost when nothing is mentioned)
dbname host2: whatever you like.
You will use
pg_dump -h openerp.example.nl "dbname" | psql "dbname"
you have first to ask Odoo about the version running your saas service and build the same.
Then do the restoration of the sql file as explained.
If your server is compatible with the database, you should succeed in starting your server with the --update option and check the log. If this test fails,your server is likely to be uncompatible. For example, it doesn't work with a standard V8.0.
Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!
About This Community
This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.Register
Odoo Training Center
Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.Test it now
|Asked: 8/27/14, 11:58 AM|
|Seen: 5523 times|
|Last updated: 2/17/16, 2:04 PM|