Skip to Content
Menu
This question has been flagged
3 Replies
44278 Views

Dear all
After successful installation of Odoo on Windows 10 (All in One Package)  I get an Internal Error 500 on the local odoo site.
Looking at the log file of the odoo server it seems that the server is not able to access the postgresql server

OperationalError: could not connect to server: Connection refused (0x0000274D/10061)    Is the server running on host "localhost" (::1) and accepting TCP/IP connections on port 5432?
I checked the service management console on windows but there has no service "postgresql" os similar running.

My Questions

  • How can I verify if the postgresql server is up and running?

  • How can I start the "postgresql" server ?

  • Should the installer not install the postgresql as a service? if so what is the name of the service and how can I install it manually?

thank you regards
Mark

Avatar
Discard
Author Best Answer

Thank you, I verified and notices that the Odoo (all in One) installes the postgre binary but did not initialized the DB and also did not installed the service "postgre". I don't know if this is a problem of windows 10. May be other users can confirm this?

However I collected several information how to initialize postgresql and how it can be installed as a service from different sites on the internet.

finally I could it get running by following these steps:

1. Open cmd line environment with Administrator privileges

2. got to postgresql isntallation from odoo e.g.: cd "C:\Program Files (x86)\Odoo 9.0-20161005\PostgreSQL\bin"

3. initialize the postgresql server with the credentials you have entered during the odoo installer

initdb.exe --locale=German_Germany -E UTF-8 -U openpg -W "C:\Program Files (x86)\Odoo 9.0-20161005\PostgreSQL\data"

Remarks: please make sure that the data directory is empty. please use your "locale" according your platform. the -U is the option to create a superuser with that name while -W will prompt you for the password for this new user.

4. register the "postgres" service: pg_ctl.exe register -N postgres -D "c:\Program Files (x86)\Odoo 9.0-20161005\PostgreSQL\data"

5. start the service in the windows mgmt console

6. after that you should be able to access the odoo page and start with the DB installation

Hope this helps



Avatar
Discard
Best Answer

Hi,
Odoo in Windows with the all in one package installs postgresql inside the openerp folder :

C:\Program Files\OpenERP 7.0-20150312\PostgreSQL

This is an old winxp installation of openerp.  Maybe for odoo and recent version of windows are the same.

To check for Postgresql service, in cmd run
net start | findstr "Postgre"

Or  Start -> Run ->  services.msc
Look for Posgresql_For_Openerp  or something similar

To access the postgresql server you have to modify the pg_hba.conf file.  This file resides in the data dir of the posgresql folder.  (C:\Program Files\OpenERP 7.0-20150312\PostgreSQL\data)

At the end of the file add something like this:

host all openerp all  md5     (or the name of the user you created when the installer asked for one)
host all odoo all md5


HTH.


Avatar
Discard
Related Posts Replies Views Activity
5
Feb 24
33030
1
Mar 15
4260
2
Aug 15
3423
1
Jul 24
3460
2
Jan 24
10134