Openerp 7.0错误数据库

时间:2013-03-27 21:02:24

标签: postgresql debian openerp

我对Openerp有疑问,能帮帮我吗?

ERROR ? openerp.sql_db: Connection to the database failed
Traceback (most recent call last):
  File "/opt/openerp/server/openerp/sql_db.py", line 440, in borrow
    result = psycopg2.connect(dsn=dsn, connection_factory=PsycoConnection)
OperationalError: fe_sendauth: no password supplied

4 个答案:

答案 0 :(得分:2)

检查您的/etc/openerp/openerp-server.conf并确保至少设置了以下选项:

db_host = (usually localhost)
db_port = (usually 5432)
db_user =
db_password = 

尝试通过运行:

手动连接到数据库
psql -d postgres -U <YOUR DATABASE USERNAME> -W

如果这样有效(你应该得到像“postgres =&gt;”这样的提示,按ctrl + d退出它)但是OpenERP中仍然存在错误,可能是因为你运行Ubuntu / Debian而你刚刚安装了OpenERP包。出现错误是因为init脚本无法在程序包安装后自动终止dpkg启动的第一个openerpppthon进程。要解决此问题,请运行:

# ps aux|grep openerp

您会看到一行如下所示:

openerp  14438  0.3  0.8 235096 69060 ?        Sl   03:23   0:00 /usr/bin/python /usr/bin/openerp-server --config=/etc/openerp/openerp-server.conf --logfile=/var/log/openerp/openerp-server.log

第一个数字是Python进程的pid。通过运行来终止该过程:

kill -9 14438

然后通过运行:

重新启动openerp服务器
/etc/init.d/openerp restart 

您的openerp-server.conf现在应该由OpenERP重新阅读,错误应该消失。

答案 1 :(得分:1)

在Google和Stack Overflow中搜索“fe_sendauth:未提供密码”。

您的PostgreSQL设置为需要您正在连接的(地址,数据库,用户)组合的密码,而您没有发送密码。

您可以阅读the Client Authentication chapter of the PostgreSQL documentation了解更多信息。

答案 2 :(得分:0)

使用此命令创建postgres用户。 确保用户的名称与系统用户相同。

sudo su postgres

createuser -d -S -R <your system user>

psql

alter user <your system user> with password <your password>;

希望它能解决您与数据库建立连接的问题。

答案 3 :(得分:0)

转到opererp-server.conf并查找addons_path。确保你有/ openerp / addons和/ openerp / web / addons。如果您还有别的东西,请将其取下并重新启动服务器。它会工作。