我试图使用Postgresql在我自己的服务器上运行tinyRSS.但是我一直收到这个错误:
LOG: provided user name (tinyRSS) and authenticated user name (apache) do not match FATAL: Peer authentication Failed for user "tinyRSS"
我知道postgresql使用基于主机的身份验证,因为我没有与主机一样的帐户名(tinyRSS),我需要使用用户名映射,所以我将这行添加到pg_ident.conf中:
# MAPNAME SYSTEM-USERNAME PG-USERNAME tinyRSS hongyi tinyRSS
在pg_hba.conf下:
# TYPE DATABASE USER ADDRESS METHOD # "local" is for Unix domain socket connections only # local all all peer # IPv4 local connections: host all all 127.0.0.1/32 ident map=tinyRSS # IPv6 local connections: host all all ::1/128 ident
我可以知道我做错了什么以及解决方案吗?提前致谢!