Skip to Content
Odoo Menu
  • Sign in
  • Try it free
  • Apps
    Finance
    • Accounting
    • Invoicing
    • Expenses
    • Spreadsheet (BI)
    • Documents
    • Sign
    Sales
    • CRM
    • Sales
    • POS Shop
    • POS Restaurant
    • Subscriptions
    • Rental
    Websites
    • Website Builder
    • eCommerce
    • Blog
    • Forum
    • Live Chat
    • eLearning
    Supply Chain
    • Inventory
    • Manufacturing
    • PLM
    • Purchase
    • Maintenance
    • Quality
    Human Resources
    • Employees
    • Recruitment
    • Time Off
    • Appraisals
    • Referrals
    • Fleet
    Marketing
    • Social Marketing
    • Email Marketing
    • SMS Marketing
    • Events
    • Marketing Automation
    • Surveys
    Services
    • Project
    • Timesheets
    • Field Service
    • Helpdesk
    • Planning
    • Appointments
    Productivity
    • Discuss
    • Approvals
    • IoT
    • VoIP
    • Knowledge
    • WhatsApp
    Third party apps Odoo Studio Odoo Cloud Platform
  • Industries
    Retail
    • Book Store
    • Clothing Store
    • Furniture Store
    • Grocery Store
    • Hardware Store
    • Toy Store
    Food & Hospitality
    • Bar and Pub
    • Restaurant
    • Fast Food
    • Guest House
    • Beverage Distributor
    • Hotel
    Real Estate
    • Real Estate Agency
    • Architecture Firm
    • Construction
    • Estate Management
    • Gardening
    • Property Owner Association
    Consulting
    • Accounting Firm
    • Odoo Partner
    • Marketing Agency
    • Law firm
    • Talent Acquisition
    • Audit & Certification
    Manufacturing
    • Textile
    • Metal
    • Furnitures
    • Food
    • Brewery
    • Corporate Gifts
    Health & Fitness
    • Sports Club
    • Eyewear Store
    • Fitness Center
    • Wellness Practitioners
    • Pharmacy
    • Hair Salon
    Trades
    • Handyman
    • IT Hardware & Support
    • Solar Energy Systems
    • Shoe Maker
    • Cleaning Services
    • HVAC Services
    Others
    • Nonprofit Organization
    • Environmental Agency
    • Billboard Rental
    • Photography
    • Bike Leasing
    • Software Reseller
    Browse all Industries
  • Community
    Learn
    • Tutorials
    • Documentation
    • Certifications
    • Training
    • Blog
    • Podcast
    Empower Education
    • Education Program
    • Scale Up! Business Game
    • Visit Odoo
    Get the Software
    • Download
    • Compare Editions
    • Releases
    Collaborate
    • Github
    • Forum
    • Events
    • Translations
    • Become a Partner
    • Services for Partners
    • Register your Accounting Firm
    Get Services
    • Find a Partner
    • Find an Accountant
    • Meet an advisor
    • Implementation Services
    • Customer References
    • Support
    • Upgrades
    Github Youtube Twitter Linkedin Instagram Facebook Spotify
    +1 (650) 691-3277
    Get a demo
  • Pricing
  • Help

Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:

  • CRM
  • e-Commerce
  • Accounting
  • Inventory
  • PoS
  • Project
  • MRP
All apps
You need to be registered to interact with the community.
All Posts People Badges
Tags (View all)
odoo accounting v14 pos v15
About this forum
You need to be registered to interact with the community.
All Posts People Badges
Tags (View all)
odoo accounting v14 pos v15
About this forum
Help

Odoo 14 - Filestore not created during restoration

Subscribe

Get notified when there's activity on this post

This question has been flagged
filestorerestoredumpv14
3 Replies
5319 Views
Avatar
Tessa Roberts

Hello everyone,



I have a problem with my Odoo installation.


I have built an Odoo 14 in a set of Docker containers (an Odoo container and a Postgres container in version 10.3). Everything seems to work fine.



I tried to create a new database from the Odoo web interface and all went well. The database was created in the postgres container and the filestore directory was created in the odoo container (in /var/lib/odoo/filestore).



In the same Odoo installation, I tried to restore an existing database using the ZIP archive containing the database dump and filestore directory and, although the database was created in the postgres container, the filestore directory was not created in the odoo container at all.



Has anyone ever encountered this phenomenon?


I've already checked the filestore directory (/var/lib/odoo) permissions and I've also checked postgres versions (psql, pg_dump and pg_restore are all in version 10.3). 


The restored database was originally created with postgresql 10.3 as well.



I get no errors in the logs (neither Odoo nor postgres) when I try to restore the database.


On the other hand, I tried to dump the database I created directly from the web interface and got this error in the Odoo logs:



2024-01-25 14:19:45,357 9 INFO ? odoo.service.db: DUMP DB: odoo format zip 

2024-01-25 14:19:45,578 9 ERROR ? odoo.addons.web.controllers.main: Database.backup 

Traceback (most recent call last):

  File "/usr/lib/python3/dist-packages/odoo/addons/web/controllers/main.py", line 1180, in backup

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

  File "", line 2, in dump_db

  File "/usr/lib/python3/dist-packages/odoo/service/db.py", line 41, in if_db_mgt_enabled

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

  File "/usr/lib/python3/dist-packages/odoo/service/db.py", line 241, in dump_db

    odoo.tools.exec_pg_command(*cmd)

  File "/usr/lib/python3/dist-packages/odoo/tools/misc.py", line 130, in exec_pg_command

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

Exception: Postgres subprocess ('/usr/bin/pg_dump', '--no-owner', '--file=/tmp/tmpok49pnxc/dump.sql', 'odoo') error 1



There's definitely a configuration problem somewhere, but I can't put my finger on it. Does anyone have any ideas?


Thank you in advance


0
Avatar
Discard
Avatar
Tessa Roberts
Author Best Answer

Hello everyone,

I come to update my post because I found what was wrong with the database restore.


When I built my Odoo Docker installation, I used the Odoo 14 Docker image provided by Odoo in my Odoo container and the version 13.0 Postgres Docker image in my Postgresql container.


I couldn't restore the database correctly with the ZIP archive from Odoo's manager restore feature, so I searched my Odoo and Postgresql containers for any anomaly. 


I found that a Postgresql version 16.0 was installed in the Odoo container (certainly installed from the docker image provided by Odoo).


To check whether this was indeed the problem with the restoration, I completely recreated my docker environment using a postgres 16.0 image in my Postgresql container.


When I tried to restore the database, the filestore directory was indeed created in the correct directory (in the /var/lib/odoo/filestore directory of the Odoo container).


This seems to have solved my problem of restoring the database with a zip archive. 


The database dump problem persists, however, with exactly the same error. 

So I'm going back to my research!



UPDATE (22.02.2024)


For those of you experiencing the same problem with the dump, here's what I did that worked:

In my docker-compose.yml, I mounted a new volume as follows: 


volumes:
     [...]
      - /data/openupgrade/extra-addons/odoo/service/db.py:/usr/lib/python3/dist-packages/odoo/service/db.py 


I created the path "/data/openupgrade/extra-addons/odoo/service" and added a file db.py

I've overridden the "dump_db()" function code to replace it with the function code in version 16.


This manipulation solved my problem with the dump()







0
Avatar
Discard
Avatar
Nikhil Nakrani
Best Answer

Hi Tessa Roberts,

I hope you are doing well,

Can you check below solutions may be help

https://www.odoo.com/forum/help-1/database-backup-error-postgres-subprocess-usr-bin-pg-dump-no-owner-file-tmp-tmpaa0o5q-dump-sql-u-ahlain-db01-error-1-118245

https://www.odoo.com/forum/help-1/database-backup-error-postgres-subprocess-opt-bitnami-postgresql-bin-pg-dump-no-owner-file-tmp-tmpnad3bjd1-dump-sql-production-error-1-182797

https://www.odoo.com/forum/help-1/error-on-restoring-database-database-restore-error-postgres-subprocess-usr-bin-pg-restore-u-dbname-restored-no-owner-tmp-tmpm-lkwr-error-1-117151

Thanks.

0
Avatar
Discard
Avatar
andreaa23
Best Answer

The filestore is essential in Odoo as it holds attachments and binary files for the database

0
Avatar
Discard
andreaa23

Always back up the database and filestore together using the Odoo interface or manually.
https://incrediboxsprunki.com/mods/

Enjoying the discussion? Don't just read, join in!

Create an account today to enjoy exclusive features and engage with our awesome community!

Sign up
Related Posts Replies Views Activity
Moving only the database to another server (dump/restore problems) Solved
filestore restore dump odoo11
Avatar
Avatar
2
Jan 21
8765
Live and test database has missing file in filestore, Odoo14
filestore v14
Avatar
Avatar
1
Mar 24
3124
Restoring filestore on a different server?
filestore restore
Avatar
0
Mar 16
5081
"/web/database/manager" 404 page not found Odoo14 Solved
database restore v14
Avatar
Avatar
1
May 21
5255
How to save a csv file to download it later by clicking another button?
filestore csv CSV v14
Avatar
Avatar
1
Oct 21
3009
Community
  • Tutorials
  • Documentation
  • Forum
Open Source
  • Download
  • Github
  • Runbot
  • Translations
Services
  • Odoo.sh Hosting
  • Support
  • Upgrade
  • Custom Developments
  • Education
  • Find an Accountant
  • Find a Partner
  • Become a Partner
About us
  • Our company
  • Brand Assets
  • Contact us
  • Jobs
  • Events
  • Podcast
  • Blog
  • Customers
  • Legal • Privacy
  • Security
الْعَرَبيّة Català 简体中文 繁體中文 (台灣) Čeština Dansk Nederlands English Suomi Français Deutsch हिंदी Bahasa Indonesia Italiano 日本語 한국어 (KR) Lietuvių kalba Język polski Português (BR) română русский язык Slovenský jazyk slovenščina Español (América Latina) Español ภาษาไทย Türkçe українська Tiếng Việt

Odoo is a suite of open source business apps that cover all your company needs: CRM, eCommerce, accounting, inventory, point of sale, project management, etc.

Odoo's unique value proposition is to be at the same time very easy to use and fully integrated.

Website made with

Odoo Experience on YouTube

1. Use the live chat to ask your questions.
2. The operator answers within a few minutes.

Live support on Youtube
Watch now