Re: database is bigger after dump/restore - why? (60 GB to 109 GB) - Mailing list pgsql-general

From Aleksey Tsalolikhin
Subject Re: database is bigger after dump/restore - why? (60 GB to 109 GB)
Date
Msg-id AANLkTik8=u8zJqyd0iKmGhB=Tmb+9YvhXnCpYpewbXGt@mail.gmail.com
Whole thread Raw
In response to database is bigger after dump/restore - why? (60 GB to 109 GB)  (Aleksey Tsalolikhin <atsaloli.tech@gmail.com>)
Responses Re: database is bigger after dump/restore - why? (60 GB to 109 GB)
List pgsql-general
I've dumped the big table from the original database (where it is 61 GB in size)
and am restoring it into a test database to see what the size is after
the restore.

As it is now, our DR is offline because we did not expect the database to
nearly double in size upon COPY of the data into a new database.  Would like to
understand what is going on.    And would like to not have such a swell of data
upon transfer.  Is there anything I can do, please?

Best,
Aleksey

On Tue, Feb 22, 2011 at 12:44 PM, Aleksey Tsalolikhin
<atsaloli.tech@gmail.com> wrote:
> Hi.  Last week our 60 GB database (per psql \l+) was (re-)replicated to
> the DR site using SlonyI, and arrived 109 GB in size which caused a
> problem as it filled up the filesystem on the DR server - we expected the
> DR database to be the same size.  Mystery.
>
> Now just past weekend we upgraded our production server by pg_dump
> and pg_restore, and again the database is 109 GB in size!
>
> Most of our data is in a single table, which on the old server is 50 GB in
> size and on the new server is 100 GB in size.
>
> Could you please help us understand why a COPY of the data into a new
> database (whether DR or the new server) results in different disk usage?
>
> Somebody mentioned on the Slony users list that there is a kind of padding
> that goes in that actually helps performance.
>
> Is there a way to track disk usage MINUS the padding?
>
> Thanks,
> Aleksey
>

pgsql-general by date:

Previous
From: Kalai R
Date:
Subject: PostgreSQL database design for a large company
Next
From: Gaini Rajeshwar
Date:
Subject: Re: Data types for IP address.