pg.ddx.io pgsql-admin@postgresql.org mailing list archive
help / color / mirror / Atom feedpg_basebackup Failed
4+ messages / 4 participants
[nested] [flat]
* pg_basebackup Failed
@ 2024-04-25 12:34 Yongye Serkfem <yserkfem@gmail.com>
0 siblings, 3 replies; 4+ messages in thread
From: Yongye Serkfem @ 2024-04-25 12:34 UTC (permalink / raw)
To: pgsql-admin@lists.postgresql.org
Hi All,
I do not know why I am having this problem. My pg_basebackup which I took
using this command "pg_basebackup -h xxxxxx -p 5432 -U postgres_repuser -D
/data/postgres -R" is failing with this error message "pg_basebackup:
error: could not create directory "/data/postgres/pg_log": File exists"
I cleaned up that directory using rm -rf /data/postgres/ .*/ and I still
end up with the above error message.
Any suggestions will be highly appreciated.
Yong
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: pg_basebackup Failed
@ 2024-04-25 13:05 Mahendra Singh <msmahendrasingh18@gmail.com>
parent: Yongye Serkfem <yserkfem@gmail.com>
2 siblings, 0 replies; 4+ messages in thread
From: Mahendra Singh @ 2024-04-25 13:05 UTC (permalink / raw)
To: Yongye Serkfem <yserkfem@gmail.com>; +Cc: pgsql-admin@lists.postgresql.org
Check the complete path on your primary replica.
Refer the below example
Example: *pg_basebackup -h <hostip> -U <>repuser -Xs -P -R -D
/var/lib/pgsql/11/ -p 5490*
This command will copy the complete data in */data* directory from the
primary node to /var/lib/pgsql/11/ on the replica node.
On replica node you can go to /var/lib/pgsql/11/ and find that /data
directory of primary replica gets copied here.
On Thu, Apr 25, 2024 at 4:35 PM Yongye Serkfem <yserkfem@gmail.com> wrote:
> Hi All,
> I do not know why I am having this problem. My pg_basebackup which I took
> using this command "pg_basebackup -h xxxxxx -p 5432 -U postgres_repuser -D
> /data/postgres -R" is failing with this error message "pg_basebackup:
> error: could not create directory "/data/postgres/pg_log": File exists"
> I cleaned up that directory using rm -rf /data/postgres/ .*/ and I still
> end up with the above error message.
> Any suggestions will be highly appreciated.
>
> Yong
>
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: pg_basebackup Failed
@ 2024-04-25 14:33 Kashif Zeeshan <kashi.zeeshan@gmail.com>
parent: Yongye Serkfem <yserkfem@gmail.com>
2 siblings, 0 replies; 4+ messages in thread
From: Kashif Zeeshan @ 2024-04-25 14:33 UTC (permalink / raw)
To: Yongye Serkfem <yserkfem@gmail.com>; +Cc: pgsql-admin@lists.postgresql.org
Hi
To debug the issue, try to take the backup to a location where user taking
the backup has Access, provide the location with -D option.
This way it will be confirmed if the issue is due to permissions.
Thanks
Kashif Zeeshan
Bitnine Global
On Thu, Apr 25, 2024 at 5:35 PM Yongye Serkfem <yserkfem@gmail.com> wrote:
> Hi All,
> I do not know why I am having this problem. My pg_basebackup which I took
> using this command "pg_basebackup -h xxxxxx -p 5432 -U postgres_repuser -D
> /data/postgres -R" is failing with this error message "pg_basebackup:
> error: could not create directory "/data/postgres/pg_log": File exists"
> I cleaned up that directory using rm -rf /data/postgres/ .*/ and I still
> end up with the above error message.
> Any suggestions will be highly appreciated.
>
> Yong
>
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: pg_basebackup Failed
@ 2024-04-25 15:11 Carlos Alves <carlos.alves@tecnisys.com.br>
parent: Yongye Serkfem <yserkfem@gmail.com>
2 siblings, 0 replies; 4+ messages in thread
From: Carlos Alves @ 2024-04-25 15:11 UTC (permalink / raw)
To: Yongye Serkfem <yserkfem@gmail.com>; +Cc: pgsql-admin@lists.postgresql.org
Em 25/04/2024 09:34, Yongye Serkfem escreveu:
> Hi All,
> I do not know why I am having this problem. My pg_basebackup which I took using this command "pg_basebackup -h xxxxxx -p 5432 -U postgres_repuser -D /data/postgres -R" is failing with this error message "pg_basebackup: error: could not create directory "/data/postgres/pg_log": File exists"
> I cleaned up that directory using rm -rf /data/postgres/ .*/ and I still end up with the above error message.
> Any suggestions will be highly appreciated.
>
> Yong
I think the command "rm -rf /data/postgres/.*/ " may not remove all
content.. try "rm -rf /data/postgres/*"
^ permalink raw reply [nested|flat] 4+ messages in thread
end of thread, other threads:[~2024-04-25 15:11 UTC | newest]
Thread overview: 4+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2024-04-25 12:34 pg_basebackup Failed Yongye Serkfem <yserkfem@gmail.com>
2024-04-25 13:05 ` Mahendra Singh <msmahendrasingh18@gmail.com>
2024-04-25 14:33 ` Kashif Zeeshan <kashi.zeeshan@gmail.com>
2024-04-25 15:11 ` Carlos Alves <carlos.alves@tecnisys.com.br>
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