odoo15网站登录报错
-
本机win10家庭中文版21H1,安装了odoo15和postgresql12数据库。
但从浏览器登录时,却提示错误。
查询win10日志提示-
System
- Provider
[ Name] Microsoft-Windows-DistributedCOM
[ Guid] {1B562E86-B7AA-4131-BADC-B6F3A001407E}
[ EventSourceName] DCOM- EventID 10016
[ Qualifiers] 0
Version 0
Level 3
Task 0
Opcode 0
Keywords 0x8080000000000000
- TimeCreated
[ SystemTime] 2022-05-22T03:09:08.1288646Z
EventRecordID 173459
- Correlation
[ ActivityID] {69866905-3077-4036-955c-6d8265185490}
- Execution
[ ProcessID] 1316
[ ThreadID] 12996Channel System
Computer LENOVO14RYZEN-JB
- Security
[ UserID] S-1-5-18
-
EventData
param1 应用程序-特定
param2 本地
param3 启动
param4 Windows.SecurityCenter.WscBrokerManager
param5 不可用
param6 NT AUTHORITY
param7 SYSTEM
param8 S-1-5-18
param9 LocalHost (使用 LRPC)
param10 不可用
param11 不可用
conf文件如下:
postgresql权限如下:
请问到底 问题出在哪里?
-
-
添加补充信息:
●odoo日志:
2022-05-23 02:04:45,513 7712 INFO ? odoo.sql_db: Connection to the database failed
2022-05-23 02:04:45,519 7712 INFO ? werkzeug: 127.0.0.1 - - [23/May/2022 02:04:45] "GET /favicon.ico HTTP/1.1" 500 - 0 0.000 0.205
2022-05-23 02:04:45,530 7712 ERROR ? werkzeug: Error on request:
Traceback (most recent call last):
File "C:\Program Files\Odoo 15.0.20220514\python\lib\site-packages\werkzeug\serving.py", line 306, in run_wsgi
execute(self.server.app)
File "C:\Program Files\Odoo 15.0.20220514\python\lib\site-packages\werkzeug\serving.py", line 294, in execute
application_iter = app(environ, start_response)
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\service\server.py", line 482, in app
return self.app(e, s)
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\service\wsgi_server.py", line 112, in application
return application_unproxied(environ, start_response)
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\service\wsgi_server.py", line 87, in application_unproxied
result = odoo.http.root(environ, start_response)
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\http.py", line 1336, in call
return self.dispatch(environ, start_response)
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\http.py", line 1302, in call
return self.app(environ, start_wrapped)
File "C:\Program Files\Odoo 15.0.20220514\python\lib\site-packages\werkzeug\middleware\shared_data.py", line 220, in call
return self.app(environ, start_response)
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\http.py", line 1488, in dispatch
self.setup_db(httprequest)
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\http.py", line 1393, in setup_db
httprequest.session.db = db_monodb(httprequest)
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\http.py", line 1609, in db_monodb
dbs = db_list(True, httprequest)
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\http.py", line 1576, in db_list
dbs = odoo.service.db.list_dbs(force)
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\service\db.py", line 389, in list_dbs
with closing(db.cursor()) as cr:
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\sql_db.py", line 706, in cursor
return Cursor(self.__pool, self.dbname, self.dsn, serialized=serialized)
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\sql_db.py", line 256, in init
self._cnx = pool.borrow(dsn)
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\sql_db.py", line 589, in locked
return fun(self, *args, **kwargs)
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\sql_db.py", line 657, in borrow
**connection_info)
File "C:\Program Files\Odoo 15.0.20220514\python\lib\site-packages\psycopg2_init.py", line 127, in connect
conn = _connect(dsn, connection_factory=connection_factory, **kwasync)
psycopg2.OperationalError - - - -
@steven 在 odoo15网站登录报错 中说:
Connection to the database failed
应该是连接数据库出错。看看数据库的用户名/密码设置,以及odoo实例的访问权限。
-
@digitalsatori
●数据库的对应好象都没有错误。主机号、用户名、port号、密码都一致。
●odoo.conf文件:
●但就是用pdamin4打开数据库里,有个注释好象有问题:
但我安装的数据库路径却是:
-
@digitalsatori
●我在odoo.conf中将db_host修改成了127.0.0.1,并重启了odoo和postgresql服务,再在浏览器中登录127.0.0.1:8069,还是不行。
odoo日志如下:
2022-05-15 03:08:26,940 8804 INFO ? odoo: Odoo version 15.0-20220514
2022-05-15 03:08:26,940 8804 INFO ? odoo: Using configuration file at C:\Program Files\Odoo 15.0.20220514\server\odoo.conf
2022-05-15 03:08:26,940 8804 INFO ? odoo: addons paths: ['C:\Program Files\Odoo 15.0.20220514\server\odoo\addons', 'c:\users\jiangbin\appdata\local\openerp s.a\odoo\addons\15.0', 'c:\program files\odoo 15.0.20220514\server\odoo\addons']
2022-05-15 03:08:26,940 8804 INFO ? odoo: database: openpg@localhost:5432
2022-05-15 03:08:27,718 8804 INFO ? odoo.addons.base.models.ir_actions_report: Will use the Wkhtmltopdf binary at C:\Program Files\Odoo 15.0.20220514\thirdparty\wkhtmltopdf.exe
2022-05-15 03:08:28,470 8804 INFO ? odoo.service.server: Initiating shutdown
2022-05-15 03:08:28,470 8804 INFO ? odoo.service.server: Hit CTRL-C again or send a second signal to force the shutdown.
2022-05-15 03:08:30,706 7620 INFO ? odoo: Odoo version 15.0-20220514
2022-05-15 03:08:30,707 7620 INFO ? odoo: Using configuration file at C:\Program Files\Odoo 15.0.20220514\server\odoo.conf
2022-05-15 03:08:30,707 7620 INFO ? odoo: addons paths: ['C:\Program Files\Odoo 15.0.20220514\server\odoo\addons', 'c:\users\jiangbin\appdata\local\openerp s.a\odoo\addons\15.0', 'c:\program files\odoo 15.0.20220514\server\odoo\addons']
2022-05-15 03:08:30,707 7620 INFO ? odoo: database: openpg@localhost:5432
2022-05-15 03:08:30,930 7620 INFO ? odoo.addons.base.models.ir_actions_report: Will use the Wkhtmltopdf binary at C:\Program Files\Odoo 15.0.20220514\thirdparty\wkhtmltopdf.exe
2022-05-15 03:08:31,149 7620 INFO ? odoo.service.server: HTTP service (werkzeug) running on LENOVO14RYZEN-JB:8069
2022-05-15 03:08:35,231 7620 INFO ? odoo.sql_db: Connection to the database failed
2022-05-15 03:08:39,278 7620 INFO ? odoo.sql_db: Connection to the database failed
2022-05-15 03:10:56,511 7620 INFO ? odoo.http: HTTP Configuring static files
2022-05-15 03:11:00,585 7620 INFO ? odoo.sql_db: Connection to the database failed
2022-05-15 03:11:00,589 7620 INFO ? werkzeug: 127.0.0.1 - - [15/May/2022 03:11:00] "GET / HTTP/1.1" 500 - 0 0.000 4.063
2022-05-15 03:11:00,595 7620 ERROR ? werkzeug: Error on request:
Traceback (most recent call last):
File "C:\Program Files\Odoo 15.0.20220514\python\lib\site-packages\werkzeug\serving.py", line 306, in run_wsgi
execute(self.server.app)
File "C:\Program Files\Odoo 15.0.20220514\python\lib\site-packages\werkzeug\serving.py", line 294, in execute
application_iter = app(environ, start_response)
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\service\server.py", line 482, in app
return self.app(e, s)
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\service\wsgi_server.py", line 112, in application
return application_unproxied(environ, start_response)
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\service\wsgi_server.py", line 87, in application_unproxied
result = odoo.http.root(environ, start_response)
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\http.py", line 1336, in call
return self.dispatch(environ, start_response)
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\http.py", line 1302, in call
return self.app(environ, start_wrapped)
File "C:\Program Files\Odoo 15.0.20220514\python\lib\site-packages\werkzeug\middleware\shared_data.py", line 220, in call
return self.app(environ, start_response)
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\http.py", line 1488, in dispatch
self.setup_db(httprequest)
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\http.py", line 1393, in setup_db
httprequest.session.db = db_monodb(httprequest)
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\http.py", line 1609, in db_monodb
dbs = db_list(True, httprequest)
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\http.py", line 1576, in db_list
dbs = odoo.service.db.list_dbs(force)
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\service\db.py", line 389, in list_dbs
with closing(db.cursor()) as cr:
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\sql_db.py", line 706, in cursor
return Cursor(self.__pool, self.dbname, self.dsn, serialized=serialized)
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\sql_db.py", line 256, in init
self._cnx = pool.borrow(dsn)
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\sql_db.py", line 589, in locked
return fun(self, *args, **kwargs)
File "C:\Program Files\Odoo 15.0.20220514\server\odoo\sql_db.py", line 657, in borrow
**connection_info)
File "C:\Program Files\Odoo 15.0.20220514\python\lib\site-packages\psycopg2_init.py", line 127, in connect
conn = _connect(dsn, connection_factory=connection_factory, **kwasync)
psycopg2.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?
could not connect to server: Connection refused (0x0000274D/10061)
Is the server running on host "localhost" (127.0.0.1) and accepting
TCP/IP connections on port 5432? - - -●pg_hba.conf的截图如下: