pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Guillaume Lelarge <guillaume@lelarge.info>
To: Rob Audenaerde <Rob.Audenaerde@Valuecare.nl>
Cc: pgsql-admin@postgresql.org <pgsql-admin@postgresql.org>
Subject: Re: database size much bigger than tablespaces on filesystem
Date: Wed, 14 Sep 2011 14:00:15 +0200
Message-ID: <1316001615.2110.13.camel@localhost.localdomain> (raw)
In-Reply-To: <1D020918205F334CBDD5CE7DF2038A2E15A5812457@IE2RD2XVS271.red002.local>
References: <1D020918205F334CBDD5CE7DF2038A2E15A5812457@IE2RD2XVS271.red002.local>

On Wed, 2011-09-14 at 04:03 -0700, Rob Audenaerde wrote:
> I have a Postgresql 8.3 instance with tablespaces totalling on about 74G. This is fine.
> 
> But if I ask Postgresql how big my database is, I get a (unexpected) large answer: 595 GB.
> 
> This seems very strange. Disk I/O tests on the system are in the 'normal' range, but queries are slower than they used to be.
> 
> Is this corruption of the database? Or are there ways to 'fix' this oddity?
> 
> Btw:
> 
> I check the tablespace size by the os:
> 
> /usr/local/pgsql/data/tblspaces/du -c -h
> 74G total 
> 
> All tablespaces are there. I check this by the \db command in pgsql
> 
> I check te database size like this:
> 
> select pg_size_pretty(pg_database_size('database')) 
> 595 GB

You should also check the space held in $PGDATA/base.


-- 
Guillaume
  http://blog.guillaume.lelarge.info
  http://www.dalibo.com




view thread (7+ messages)  latest in thread

Message-ID: <1316001615.2110.13.camel@localhost.localdomain>
Permalink:  ../1316001615.2110.13.camel@localhost.localdomain/
Also on:    postgresql.org/message-id/1316001615.2110.13.camel@localhost.localdomain

 · 

reply

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-admin@postgresql.org
  Cc: guillaume@lelarge.info, Rob.Audenaerde@Valuecare.nl
  Subject: Re: database size much bigger than tablespaces on filesystem
  In-Reply-To: <1316001615.2110.13.camel@localhost.localdomain>

* 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