gpt4 book ai didi

linux - 全新安装后 PostgreSQL "cannot access the server configuration file (...) No such file or directory"

转载 作者:IT王子 更新时间:2023-10-29 00:32:02 26 4
gpt4 key购买 nike

我刚按照官方安装的postgresql documentation :但由于某种原因,它不起作用。它确实使用 sudo apt-get postgres 等安装。但是服务器的启动似乎不起作用。

我尝试根据他们的 documentation 启动服务器但是先生。输入此命令时,计算机向我的脑袋抛出以下错误:

命令:

user@user-noobcomputer:/usr/lib/postgresql/9.4$ bin/postgres -D /usr/local/pgsql/data/

错误:

postgres cannot access the server configuration file "/usr/local/pgsql/data/postgresql.conf": No such file or directory" 

我不知道为什么这个文件不存在。任何人都可以帮助我了解如何克服此错误消息并启动并运行我的 postgres 服务器吗?

最佳答案

首先确保没有安装该文件。以 super 用户身份更新 mlocate 数据库,然后对该文件运行 mlocate 查询。

$updatedb
$locate postgresql.conf

这将返回系统中具有该名称的任何文件。如果文件位于错误的文件夹中,那么它将显示在该查询中。

如果没有,可以尝试转到PostgreSQL docs他们有一个该文件外观的基本示例。尝试使用该设置制作文件副本。

关于linux - 全新安装后 PostgreSQL "cannot access the server configuration file (...) No such file or directory",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/33216761/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com