Re: Data Loss After Restore?

From: Dan Langille <dan(at)langille(dot)org>
To: Trevor Astrope <astrope(at)e-corp(dot)net>
Cc: pgsql-admin(at)postgresql(dot)org
Subject: Re: Data Loss After Restore?
Date: 2002-04-03 16:11:50
Message-ID: 20020403110947.V93107-100000@m20.unixathome.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

On Wed, 3 Apr 2002, Trevor Astrope wrote:

> I restored a 7.1.3 database to another machine which seems to have went
> fine. However, the data on the disk is less than the original machine...
> There is only 6.5GB in pgsql/dta/base on my test machine and the same
> directory on the production machine was at 8.4GB at the time of the dump.
> This was after a vacuum.
>
> I didn't see any errors when restoring the database, so I'm confused why
> the restored database takes up so much less space... Is there any reason
> why this would happen? Is there any easy way to see where I may have lost
> data?

My initial guess is that 'dead-space' within the original files has now
been freed up by unloading and then reloading the data. Such dead space
occurs when rows are deleted, etc. vacuum cleans up this space.
Although I'm not sure if a vacuum would also reduce the database size
(i.e. the disk space consumed).

In response to

Browse pgsql-admin by date

  From Date Subject
Next Message Tom Lane 2002-04-03 16:38:50 Re: Data Loss After Restore?
Previous Message Trevor Astrope 2002-04-03 15:55:54 Data Loss After Restore?