小编Rac*_*ana的帖子

Ubuntu 20.04 上的 PgAdmin 致命:用户密码身份验证失败

我已经在 Ubuntu 20.04 上安装了 Postgres 和 PGAdmin4,但无法创建服务器并连接到数据库

在此输入图像描述

正如我在几个解决方案中看到的,我将 pg_hba.conf 文件上的方法更改为 md5

# Database administrative login by Unix domain socket
local   all             postgres                                md5

# TYPE  DATABASE        USER            ADDRESS                 METHOD

# "local" is for Unix domain socket connections only
local   all             all                                     md5
# IPv4 local connections:
host    all             all             127.0.0.1/32            md5
# IPv6 local connections:
host    all             all             ::1/128                 md5
Run Code Online (Sandbox Code Playgroud)

我还连接到 psql,创建新用户,更改密码并通过运行重新启动服务器sudo systemctl restart postgresql

                                   List of roles
 Role name |                         Attributes                         | Member of 
-----------+------------------------------------------------------------+-----------
 postgres  | Superuser, …
Run Code Online (Sandbox Code Playgroud)

postgresql pgadmin

5
推荐指数
1
解决办法
8328
查看次数

标签 统计

pgadmin ×1

postgresql ×1