Skip to Content
Menu
This question has been flagged

Hi Everyone,

I am performing an Odoo Migration using OpenUpgrade with dockers containers.
-> A container for my Odoo 10 Server;
-> A container for my PostgreSQL Database Server;
When I run the OpenUpgrade script throught the command 

 

python3 ./odoo-bin --config=/etc/odoo/odoo.conf -d TestDB_Migr -u all --stop-after-init 

I got a Connection to the database failed error. As follow -> 


odoo@63057840bd16:~/OpenUpgrade_11/OpenUpgrade$ python3 ./odoo-bin --config=/etc/odoo/odoo.conf -d TestDB_Migr -u all --stop-after-init

2021-09-12 22:10:05,306 2061 INFO ? odoo: Odoo version 11.0

2021-09-12 22:10:05,307 2061 INFO ? odoo: Using configuration file at /etc/odoo/odoo.conf

2021-09-12 22:10:05,307 2061 INFO ? odoo: addons paths: ['/mnt/extra-addons', '/usr/lib/python2.7/dist-packages/odoo/addons', '/var/lib/odoo/OpenUpgrade_11/OpenUpgrade/odoo/addons']

2021-09-12 22:10:05,308 2061 INFO ? odoo: database: default@default:default

2021-09-12 22:10:05,309 2061 INFO ? odoo.sql_db: Connection to the database failed

Traceback (most recent call last):

File "./odoo-bin", line 8, in

\odoo\.cli\.main\(\)\\
\
\ \ File\ \"\/var\/lib\/odoo\/OpenUpgrade_11\/OpenUpgrade\/odoo\/cli\/command\.py\"\,\ line\ 60\,\ in\ main\
\
\ \ \ \ o\.run\(args\)\
\
\ \ File\ \"\/var\/lib\/odoo\/OpenUpgrade_11\/OpenUpgrade\/odoo\/cli\/server\.py\"\,\ line\ 176\,\ in\ run\
\
\ \ \ \ main\(args\)\
\
\ \ File\ \"\/var\/lib\/odoo\/OpenUpgrade_11\/OpenUpgrade\/odoo\/cli\/server\.py\"\,\ line\ 140\,\ in\ main\
\
\ \ \ \ \odoo\.service\.db\._create_empty_database\(db_name\)\\
\
\ \ File\ \"\/var\/lib\/odoo\/OpenUpgrade_11\/OpenUpgrade\/odoo\/service\/db\.py\"\,\ line\ 95\,\ in\ _create_empty_database\
\
\ \ \ \ with\ closing\(db\.cursor\(\)\)\ as\ cr\:\
\
\ \ File\ \"\/var\/lib\/odoo\/OpenUpgrade_11\/OpenUpgrade\/odoo\/sql_db\.py\"\,\ line\ 637\,\ in\ cursor\
\
\ \ \ \ return\ Cursor\(self\.__pool\,\ self\.dbname\,\ self\.dsn\,\ serialized\=serialized\)\
\
\ \ File\ \"\/var\/lib\/odoo\/OpenUpgrade_11\/OpenUpgrade\/odoo\/sql_db\.py\"\,\ line\ 178\,\ in\ __init__\
\
\ \ \ \ self\._cnx\ \=\ pool\.borrow\(dsn\)\
\
\ \ File\ \"\/var\/lib\/odoo\/OpenUpgrade_11\/OpenUpgrade\/odoo\/sql_db\.py\"\,\ line\ 520\,\ in\ _locked\
\
\ \ \ \ return\ fun\(self\,\ \*args\,\ \*\*kwargs\)\
\
\ \ File\ \"\/var\/lib\/odoo\/OpenUpgrade_11\/OpenUpgrade\/odoo\/sql_db\.py\"\,\ line\ 588\,\ in\ borrow\
\
\ \ \ \ \*\*connection_info\)\
\
\ \ File\ \"\/usr\/lib\/python3\/dist\-packages\/psycopg2\/__init__\.py\"\,\ line\ 164\,\ in\ connect\
\
\ \ \ \ conn\ \=\ _connect\(dsn\,\ connection_factory\=connection_factory\,\ async\=async\)\
\
psycopg2\.OperationalError\:\ could\ not\ connect\ to\ server\:\ No\ such\ file\ or\ directory\
\
\ \ \ \ \ \ \ \ Is\ the\ server\ running\ locally\ and\ accepting\
\
\ \ \ \ \ \ \ \ connections\ on\ Unix\ domain\ socket\ \"\/var\/run\/postgresql\/\
.s.PGSQL.5432"?



odoo@63057840bd16:~/OpenUpgrade_11/OpenUpgrade$
Avatar
Discard
Related Posts Replies Views Activity
0
Dec 24
68
1
Nov 22
5199
0
Jun 19
5084
0
Aug 24
327
0
Nov 23
757