pg.ddx.io pgsql-bugs@postgresql.org mailing list archivehelp / color / mirror / Atom feed
BUG #17649: With libpg5 15.0 psql 10.22 uses HOME variable instead of uid and /etc/passwd to select .pgpass file 2+ messages / 2 participants [nested] [flat]
* BUG #17649: With libpg5 15.0 psql 10.22 uses HOME variable instead of uid and /etc/passwd to select .pgpass file @ 2022-10-18 09:17 PG Bug reporting form <noreply@postgresql.org> 0 siblings, 1 reply; 2+ messages in thread From: PG Bug reporting form @ 2022-10-18 09:17 UTC (permalink / raw) To: pgsql-bugs@lists.postgresql.org; +Cc: rvpostgres@metaways.de The following bug has been logged on the website: Bug reference: 17649 Logged by: Reinhard Vicinus Email address: rvpostgres@metaways.de PostgreSQL version: 15.0 Operating system: Ubuntu 18.04 Description: This is probably the same issue that was reported in bug #17647 The general postgresql version we use is 10.22-1.pgdg18.04+1 With the update of libpg5 from 14.5-1.pgdg18.04+1 to 15.0-1.pgdg18.04+1 the behavior of psql changed and with libpg5 version 15.0 it uses the HOME environment variable to determine the location of the .pgpass file. With 14.5 the uid of the running process is used to determine the home directory location. This causes the issue that "sudo -u postgres psql" no longer finds the .pgpass file in /var/lib/postgresql/. After downgrading libpg5 to 14.5-1.pgdg18.04+1 or setting the correct HOME environment variable, it works again as intended. ^ permalink raw reply [nested|flat] 2+ messages in thread
* Re: BUG #17649: With libpg5 15.0 psql 10.22 uses HOME variable instead of uid and /etc/passwd to select .pgpass file @ 2022-10-18 13:29 Julien Rouhaud <rjuju123@gmail.com> parent: PG Bug reporting form <noreply@postgresql.org> 0 siblings, 0 replies; 2+ messages in thread From: Julien Rouhaud @ 2022-10-18 13:29 UTC (permalink / raw) To: rvpostgres@metaways.de; pgsql-bugs@lists.postgresql.org Hi, On Tue, Oct 18, 2022 at 09:17:05AM +0000, PG Bug reporting form wrote: > The following bug has been logged on the website: > > Bug reference: 17649 > Logged by: Reinhard Vicinus > Email address: rvpostgres@metaways.de > PostgreSQL version: 15.0 > Operating system: Ubuntu 18.04 > Description: > > This is probably the same issue that was reported in bug #17647 Indeed! > > The general postgresql version we use is 10.22-1.pgdg18.04+1 > > With the update of libpg5 from 14.5-1.pgdg18.04+1 to 15.0-1.pgdg18.04+1 the > behavior of psql changed and with libpg5 version 15.0 it uses the HOME > environment variable to determine the location of the .pgpass file. With > 14.5 the uid of the running process is used to determine the home directory > location. This causes the issue that "sudo -u postgres psql" no longer finds > the .pgpass file in /var/lib/postgresql/. After downgrading libpg5 to > 14.5-1.pgdg18.04+1 or setting the correct HOME environment variable, it > works again as intended. > As I just answered on the other bug, this is a wanted and documented change, you can refer at https://www.postgresql.org/message-id/flat/1634252654444.90107%40mit.edu for the discussion about it. You can use "sudo -iu" to behave the way you want. ^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2022-10-18 13:29 UTC | newest] Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed) -- links below jump to the message on this page -- 2022-10-18 09:17 BUG #17649: With libpg5 15.0 psql 10.22 uses HOME variable instead of uid and /etc/passwd to select .pgpass file PG Bug reporting form <noreply@postgresql.org> 2022-10-18 13:29 ` Julien Rouhaud <rjuju123@gmail.com>
This inbox is served by DDX for PostgreSQL; see mirroring instructions for how to clone and mirror all data and code used for this inbox