pg_probackup icon indicating copy to clipboard operation
pg_probackup copied to clipboard

При бэкапе меняется Backup ID

Open AlexSavenkov opened this issue 4 years ago • 11 comments

INFO: Backup start, pg_probackup version: 2.4.15, instance: ppak_kis, backup ID: R0YIS2, backup mode: FULL, wal mode: STREAM, remote: true, compress-algorithm: none, compress-level: 1 WARNING: Current PostgreSQL role is superuser. It is not recommended to run backup or checkdb as superuser. INFO: Backup R0YIS2 is going to be taken from standby INFO: wait for pg_start_backup() INFO: Wait for WAL segment /backup/today/backups/ppak_kis/R0YIS2/database/pg_wal/00000013000004DB000000DC to be streamed INFO: PGDATA size: 324GB INFO: Start transferring data files INFO: Data files are transferred, time elapsed: 1h:15m INFO: wait for pg_stop_backup() INFO: pg_stop backup() successfully executed INFO: Syncing backup files to disk INFO: Backup files are synced, time elapsed: 3s INFO: Validating backup R0YIS2 INFO: Backup R0YIS2 data files are valid INFO: Backup R0YIS2 resident size: 325GB INFO: Backup R0YIS2 completed postgres@m08-nfs-01:~$ pg_probackup-10 show -B /backup/today WARNING: backup ID in control file "R0Y242" doesn't match name of the backup folder "/backup/today/backups/ppak_kis/R0YIS2/backup.control"

BACKUP INSTANCE 'ppak_kis'

Instance Version ID Recovery Time Mode WAL Mode TLI Time Data WAL Zratio Start LSN Stop LSN Status

ppak_kis 10 R0Y242 2021-10-14 05:58:15+03 FULL STREAM 19/0 1h:15m 324GB 1216MB 1.00 4DB/DCDA5080 4DC/276F2928 OK
postgres@m08-nfs-01:~$ date Thu Oct 14 13:05:50 MSK 2021

AlexSavenkov avatar Oct 14 '21 11:10 AlexSavenkov

Hello! Hm, we should stop calculating backup id on-fly all the time, and just store it in backup meta.

gsmolk avatar Oct 21 '21 22:10 gsmolk

@gsmol, hi!

I apologize for the necroposting, but this issue is open, so I will not create a new one.

In version 2.5.8 for PostgreSQL 14, I did not have anything like this, now I am deploying the infrastructure for PostgreSQL 15 backup using version 2.5.11 and I am constantly getting a similar warning now.

You have already fixed it earlier, and now there is a regression?

Or does the warning not appear in every case?

strafer avatar Feb 03 '23 15:02 strafer

Hi! Thx. We will check it.

Burus avatar Feb 09 '23 10:02 Burus

@Burus can you at least tell me if this is a false warning and everything is fine with the backups and I can just ignore it, or does it reflect some problems in the backups?

strafer avatar Feb 09 '23 13:02 strafer

@strafer It doesn't affect your data in any way, it's just an output issue.

daniel-95 avatar Feb 10 '23 07:02 daniel-95

@strafer could you please show me backup.control file for the backup you have problem with?

daniel-95 avatar Feb 10 '23 07:02 daniel-95

@daniel-95

Corresponding warning message: WARNING: backup ID in control file "RPOQ70" doesn't match name of the backup folder "/srv/pg_probackup/backups/pgsql.example.com/RPP6V0/backup.control"

RPP6V0/backup.control:
#Configuration
backup-mode = FULL
stream = true
compress-alg = zlib
compress-level = 9
from-replica = false

#Compatibility
block-size = 8192
xlog-block-size = 8192
checksum-version = 1
program-version = 2.5.11
server-version = 15

#Result backup info
timelineid = 1
start-lsn = 0/22000028
stop-lsn = 0/220040B0
start-time = '2023-02-07 06:47:24+03'
end-time = '2023-02-07 06:48:05+03'
recovery-xid = 1014
recovery-time = '2023-02-07 06:47:32+03'
data-bytes = 64978530
wal-bytes = 16777216
uncompressed-bytes = 90651095
pgdata-bytes = 90650739
status = OK
primary_conninfo = 'user=backup channel_binding=prefer host=pgsql.example.com port=5432 sslmode=verify-full sslcompression=0 sslcert=/etc/tls/cert.pem sslkey=/etc/tls/private.key sslrootcert=/etc/tls/rootca.pem sslsni=1 ssl_min_protocol_version=TLSv1.2 gssencmode=prefer krbsrvname=postgres target_session_attrs=any'
content-crc = 584381959

strafer avatar Feb 10 '23 08:02 strafer

I suppose you're using system with musl libc. Am I right?

funny-falcon avatar Feb 28 '23 18:02 funny-falcon

I believed we've fixed it in a2387b5134bc6f56b54079903b1845494d29252e (branch REL_2_5)

funny-falcon avatar Feb 28 '23 19:02 funny-falcon

I suppose you're using system with musl libc. Am I right?

If this is a question for me, then no, I run pg_probackup in a container from an image originating from debian:11-slim with glibc 2.31

strafer avatar Mar 01 '23 09:03 strafer

Additional information: I returned to work with our postgres backup service, today I tried to update the version to 2.5.12 — the warning is still there (the other environment has not changed).

strafer avatar Jun 30 '23 08:06 strafer