public inbox for [email protected]  
help / color / mirror / Atom feed
Pgbackrest info output interpretation
2+ messages / 2 participants
[nested] [flat]

* Pgbackrest info output interpretation
@ 2025-11-14 08:32  KK CHN <[email protected]>
  0 siblings, 1 reply; 2+ messages in thread

From: KK CHN @ 2025-11-14 08:32 UTC (permalink / raw)
  To: [email protected]

Hi,

I am having confusion trying to understand the database size, backupsize
and repo backup size..

In my DB server I have du output as follows.

/data/edb/as16
[root@db1 as16]# du -h -d 1
5.3G    ./data
25G     ./tablespace
30G     .
[root@db1 as16]#

On my Repo Server pgbackest info says ....

full backup: 20251114-121504F
            timestamp start/stop: 2025-11-14 12:15:04+05:30 / 2025-11-14
12:20:58+05:30
            wal start/stop: 000000010000000500000024 /
000000010000000500000024
            database size: 3GB, database backup size: 3GB
            repo1: backup size: 431.0MB

Could someone shed some light on    431 MB and database size:3GB, database
backup size : 3GB  compared to the DB cluster on disk usage output ?

How to correlate the pgbackrest ( info) database size, database backup size
and repo1 backup size     and actual du output on DB cluster.

Note: I am using zst compression on pgbackrest


Regards,
Krishane


^ permalink  raw  reply  [nested|flat] 2+ messages in thread

* Re: Pgbackrest info output interpretation
@ 2025-11-14 13:48  Greg Sabino Mullane <[email protected]>
  parent: KK CHN <[email protected]>
  0 siblings, 0 replies; 2+ messages in thread

From: Greg Sabino Mullane @ 2025-11-14 13:48 UTC (permalink / raw)
  To: KK CHN <[email protected]>; +Cc: [email protected]

The "database size" is going to be your data directory, MINUS your pg_wal
directory, MINUS unlogged/temp relations, and MINUS things that are not
needed for recovery (i.e. all the small pg_ directories such as
pg_subtrans). The "database backup size" is how much of that 3GB is part of
*this* backup - for a full backup, the number will be the same, for diff or
incr, it will be a lot less. The "repo backup size" on the last line is the
compressed size of the previous "database backup size"

How to correlate the pgbackrest ( info) database size, database backup size
> and repo1 backup size     and actual du output on DB cluster.
>

You cannot, really, without deep knowledge of things like which files on
disk map back to unlogged tables. However, du on the datadir minus all pg_
dirs should get you in the ballpark. As a quick example:

cd $DATADIR
du --summarize * | awk '!/pg_/{x=x+$1}END{print x}' | numfmt --to=iec

Cheers,
Greg

--
Crunchy Data - https://www.crunchydata.com
Enterprise Postgres Software Products & Tech Support


^ permalink  raw  reply  [nested|flat] 2+ messages in thread


end of thread, other threads:[~2025-11-14 13:48 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2025-11-14 08:32 Pgbackrest info output interpretation KK CHN <[email protected]>
2025-11-14 13:48 ` Greg Sabino Mullane <[email protected]>

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox