From: Stephan Szabo <sszabo@megazone.bigpanda.com>
To: Tony Reina <reina_ga@hotmail.com>
Cc: pgsql-admin@postgresql.org
Subject: Re: Database storage bloat
Date: Thu, 8 Apr 2004 06:46:20 -0700 (PDT)
Message-ID: <20040408063838.Q93611@megazone.bigpanda.com> (raw)
In-Reply-To: <272e4be7.0404080115.39f1cb36@posting.google.com>
References: <272e4be7.0404080115.39f1cb36@posting.google.com>
On Thu, 8 Apr 2004, Tony Reina wrote:
> I'm developing a database for scientific recordings. These recordings
> are traditionally saved as binary flat files for simplicity and
> compact storage. Although I think ultimately having a database is
> better than 1,000s of flat files in terms of data access, I've found
> that the database (or at least my design) is pretty wasteful on
> storage space compared with the binary flat files.
>
> In particular, I tried importing all of the data from a binary flat
> file that is 1.35 MB into a PostgreSQL database (a very small test
> file; average production file is probably more like 100 MB). The
> database directory ballooned from 4.1 MB to 92 MB (a bloat of 65X the
> original storage of the binary flat file).
Well, an important question is where is that space going? It'd be
interesting to give a breakup by the directories and then which files (and
using the contrib/oid2name to get which table/indexes/etc they are).
At least 16MB of that is probably going into the transaction log (IIRC
that's the default size for the segments) in pg_xlog.
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-admin@postgresql.org
Cc: sszabo@megazone.bigpanda.com, reina_ga@hotmail.com
Subject: Re: Database storage bloat
In-Reply-To: <20040408063838.Q93611@megazone.bigpanda.com>
References: <272e4be7.0404080115.39f1cb36@posting.google.com> <20040408063838.Q93611@megazone.bigpanda.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox