OperationalError:无法连接到服务器。启动odoo时出错

时间:2020-06-15 07:00:53

标签: python postgresql odoo odoo-10

尝试运行odoo 10时出现此错误:

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"?

1 个答案:

答案 0 :(得分:0)

为了帮助其他面临相同问题的人,我按照以下步骤解决了此问题 首先,我杀死了所有正在运行的进程

ps ax | grep odoo

sudo kill -9 (process_id)

然后我检查了postgresql的状态并重新启动了postgresql。

sudo /etc/init.d/postgresql status

sudo /etc/init.d/postgresql restart

问题已成功解决!