credativ team mailing list archive
-
credativ team
-
Mailing list archive
-
Message #06046
[Bug 1365717] [NEW] Upgrade unable to connect to local posgresql database when config has 'False' values
Public bug reported:
Got this traceback when attempting to execute against our PostgreSQL database:
Traceback (most recent call last):
File "migrate.py", line 300, in <module>
db_name = copy_database(conn_parms)
File "migrate.py", line 23, in copy_database
conn = psycopg2.connect(**conn_parms)
File "/usr/lib/python2.7/dist-packages/psycopg2/__init__.py", line 167, in connect
if port is not None and int(port) > 0:
ValueError: invalid literal for int() with base 10: 'False'
Did some digging and found my openerp-server.cfg had the following values:
db_host = False
db_maxconn = 64
db_name = False
db_password = False
db_port = False
db_user = openerp
The 'False' values were causing the upgrade script 'migrate.py' to
choke, but were fine for OpenERP itself - v6.0 in our case, trying to
get to 7.0. migrate.py was downloaded from
http://github.com/OpenUpgrade/OpenUpgrade/raw/8.0/scripts/migrate.py
I've attached a patch that allowed me to connect - though I also had to, due to my set up, temporarily specify the following in my pg_hba.conf
local all all trust
** Affects: openupgrade-server
Importance: Undecided
Status: New
** Tags: migrate.py password postgresql
** Attachment added: "Fix for v8.0 migrate.py to"
https://bugs.launchpad.net/bugs/1365717/+attachment/4195786/+files/migrate.py.20140904.patch
--
You received this bug notification because you are a member of
OpenUpgrade Committers, which is subscribed to OpenUpgrade Server.
https://bugs.launchpad.net/bugs/1365717
Title:
Upgrade unable to connect to local posgresql database when config has
'False' values
Status in OpenUpgrade Server:
New
Bug description:
Got this traceback when attempting to execute against our PostgreSQL database:
Traceback (most recent call last):
File "migrate.py", line 300, in <module>
db_name = copy_database(conn_parms)
File "migrate.py", line 23, in copy_database
conn = psycopg2.connect(**conn_parms)
File "/usr/lib/python2.7/dist-packages/psycopg2/__init__.py", line 167, in connect
if port is not None and int(port) > 0:
ValueError: invalid literal for int() with base 10: 'False'
Did some digging and found my openerp-server.cfg had the following values:
db_host = False
db_maxconn = 64
db_name = False
db_password = False
db_port = False
db_user = openerp
The 'False' values were causing the upgrade script 'migrate.py' to
choke, but were fine for OpenERP itself - v6.0 in our case, trying to
get to 7.0. migrate.py was downloaded from
http://github.com/OpenUpgrade/OpenUpgrade/raw/8.0/scripts/migrate.py
I've attached a patch that allowed me to connect - though I also had to, due to my set up, temporarily specify the following in my pg_hba.conf
local all all trust
To manage notifications about this bug go to:
https://bugs.launchpad.net/openupgrade-server/+bug/1365717/+subscriptions
Follow ups
References