pg_basebackup fails with Could not stat file or directory "./.pg_hba.conf.un~"

Поиск
Список
Период
Сортировка
От Stephens, Gary
Тема pg_basebackup fails with Could not stat file or directory "./.pg_hba.conf.un~"
Дата
Msg-id DM4PR11MB5328327445FFA1FE28426198F0B79@DM4PR11MB5328.namprd11.prod.outlook.com
обсуждение исходный текст
Ответы Re: pg_basebackup fails with Could not stat file or directory "./.pg_hba.conf.un~"  ("David G. Johnston" <david.g.johnston@gmail.com>)
Список pgsql-bugs

Hi,

 

I’m writing to report a bug with pg_basebackup. It fails with this error:

 

pg_basebackup: error: could not initiate base backup: ERROR:  could not stat file or directory "./.pg_hba.conf.un~": Permission denied

 

The file in question is a temporary file created by vim, and has the same permissions and security context as the file that it was editing (pg_hba.conf).

 

It's unclear to me why pg_basebackup is trying to read this file. It's also unclear why it's failing when it does try to read it, since the file has the same permissions and security context that should allow the instance to read it (even though the backup really shouldn’t need to read it).

 

The directory where it resides is /var/lib/pgsql/data (this is where pg_hba.conf resides as well).

 

Please note: After I removed the file, the backup ran normally. I have not tested to see whether other temp files in the same directory would cause a similar failure.

 

Database version:

postgres=# select version();

                                                   version

-------------------------------------------------------------------------------------------------------------

PostgreSQL 13.7 on x86_64-redhat-linux-gnu, compiled by gcc (GCC) 8.5.0 20210514 (Red Hat 8.5.0-10), 64-bit

 

Thanks,

 

Gary Stephens

Enterprise Holdings, Incorporated




CONFIDENTIALITY NOTICE: This e-mail and any files transmitted with it are intended solely for the use of the individual or entity to whom they are addressed and may contain confidential and privileged information protected by law. If you received this e-mail in error, any review, use, dissemination, distribution, or copying of the e-mail is strictly prohibited. Please notify the sender immediately by return e-mail and delete all copies from your system.


В списке pgsql-bugs по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: BUG #17811: Replacing an underlying view breaks OLD/NEW tuple when accessing it via upper-level view
Следующее
От: "David G. Johnston"
Дата:
Сообщение: Re: pg_basebackup fails with Could not stat file or directory "./.pg_hba.conf.un~"