"Gauthier, Dave" <dave.gauthier@intel.com> writes:
> ls -1 | wc took a while for the other bad one but eventually came up
> with exactly 7,949,911 files, so yes, millions. The other one had
> millions too before I dropped it. Something is clearly wrong.
No doubt, but it's impossible to tell what from just the bare statement
that you had a lot of unexpected files.
Did you happen to notice the timestamps on those files --- eg, were
there recent ones, or were they all old? Do you use a lot of temporary
tables? Have you had a lot of crashes in this database?
>> This is PG v 8.3.4 on linux.
It wouldn't be a bad idea to update to 8.3.something-recent.
regards, tom lane