why is pg_dump so much smaller than my database?

From: Carson Gross <carsongross(at)gmail(dot)com>
To: pgsql-general <pgsql-general(at)postgresql(dot)org>
Subject: why is pg_dump so much smaller than my database?
Date: 2012-03-29 05:32:29
Message-ID: CAO92UoHBOaWauifeH0dznG=YvtJa85FezTHGFLRtVb7cGGmzPA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

I've got a pretty big database (~30 gigs) and when I do a pg_dump, it ends
up only being 2 gigs.

The database consists mainly of one very large table (w/ a few varchar
columns) which, according to pg_relation_size() is 10 gigs
and pg_total_relation_size() is 26 gigs (we need to drop some indexes
there.)

I'm just trying to get my head around the pg_dump being an order of
magnitude smaller than the darned database itself. I would thing that the
db would offer more efficient encoding for a lot of stuff vs. an ascii file.

Thanks,
Carson

Responses

Browse pgsql-general by date

  From Date Subject
Next Message John R Pierce 2012-03-29 07:11:57 Re: why is pg_dump so much smaller than my database?
Previous Message Arvind Singh 2012-03-29 05:30:50 PG Log