From: Cary B. O'Brien <cobrien@access.digex.net>
To: pgsql-interfaces@postgresql.org
Subject: Re: [INTERFACES] large object error
Date: Mon, 26 Oct 1998 07:41:12 -0500 (EST)
Message-ID: <199810261241.HAA10837@access1.digex.net> (raw)
Peter wrote...
> Hi All! :-)
>
> Thanks for your help! :-) I am attempting to write an app
> that uses large objects. It is an offline Usenet NNTP news
> reader that stores all of the message information in a
> postgres database. I am using the LOBS to hold the
You might want to investigate the disk space usage of large objects
and postgresql. My quick investigation indicated that each large
object took up at least one 16k file. In addition, all the files were
in the same directory.
The downside is wasted disk space for articles and (if you end up with
lots and lots of articles in the same database) slow directory
look-ups.
You may want to store the articles in plain disk files, with a hashed
directory structure. You could use a sequence or the oid as a
key. I.E. article 12345678 goes in file 12/34/56/78. I have done this
before with other databases. It also lets you spread things out
over multiple file systems.
Note:
1) This was the result of about an hour's worth of testing.
2) It might not be applicable in your situation. For example,
BLOBS might still be a very good idea if your clients are
coming in over TCP/IP and don't have file system access.
3) It ought to work.
Comments?
[big snip]
--- cary
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 using the --to and --cc options:
reply via email
To: pgsql-interfaces@postgresql.org
Cc: cobrien@access.digex.net
Subject: Re: [INTERFACES] large object error
In-Reply-To: <199810261241.HAA10837@access1.digex.net>
* 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