Re: Database upgrade Pg11 to Pg12 issues

From: Craig McIlwee <craigm(at)vt(dot)edu>
To: Bruce Momjian <bruce(at)momjian(dot)us>
Cc: Simon Windsor <simon(dot)windsor(at)cornfield(dot)me(dot)uk>, pgsql-general(at)lists(dot)postgresql(dot)org
Subject: Re: Database upgrade Pg11 to Pg12 issues
Date: 2021-02-04 03:07:03
Message-ID: CAGqBcTawGhPj+1OPK4Kni_+b0qRPrEO2fc-tBX0A-2WvjDuKhQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

(replying to the entire list instead of Bruce only this time...)

> This doesn't make sense to me. Since we hard-linked, why would 12 be so
> much smaller? If it was symlinks, I could imaging that, but it doesn't
> use symlinks, just hard links, so it should be similar. Please look at
> the size of main/base on both, since that is where your data is. Maybe
> 11 just has a lot of old WAL that isn't copied.
>
>
It depends on how the directory sizes were measured. "du" won't count the
same file more than once, so if space was measured using one of the
following commands:

du -hs /var/lib/postgresql/
du -hs /var/lib/postgresql/11/main /var/lib/postgresql/12/main

Then you would see a large value for the 11 directory and then the 12
directory would only show the files that weren't already counted when
measuring the 11 directory. Running du on each version's directory
separately might give results that are more in line with expectations.

Craig

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Bruce Momjian 2021-02-04 03:29:35 Re: Database upgrade Pg11 to Pg12 issues
Previous Message brajmohan saxena 2021-02-04 02:40:07 COPY command in ODBC