pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
BUG #8400: DB size changed after restore
3+ messages / 3 participants
[nested] [flat]

* BUG #8400: DB size changed after restore
@ 2013-08-27 08:31 ajayaksadvance@gmail.com
  2013-08-30 18:33 ` Re: BUG #8400: DB size changed after restore Kevin Grittner <kgrittn@ymail.com>
  0 siblings, 1 reply; 3+ messages in thread

From: ajayaksadvance@gmail.com @ 2013-08-27 08:31 UTC (permalink / raw)
  To: pgsql-bugs

The following bug has been logged on the website:

Bug reference:      8400
Logged by:          Ajay
Email address:      ajayaksadvance@gmail.com
PostgreSQL version: 9.2.0
Operating system:   ubuntu
Description:        

Hi, 


I am not sure its a bug or not but need some information on this.


I am doing upgrade from 8.4 to 9.2 hence DB dump and then restore.


On postgrse 8.4 , i have DB of size 32 GB.
SELECT pg_size_pretty(pg_database_size('<DBNAME>')) As fulldbsize;


I have done vacummdb before going for dump.


I have first done schema dump and then DB data and all is fine.


But on restore its running successfully but i am getting only size 9213 MB.




Dont know, what exactly happend?


I have checked rows count, random data its seems fine but why there is
difference?


How to make sure restore is done properly?


But ifi do below on 8.4 and 9.2 then i am getting different size and
obviously small on 9.2 .
SELECT pg_size_pretty(pg_total_relation_size('package')) As fulldbsize;


Please suggest.



-- 
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs



^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: BUG #8400: DB size changed after restore
  2013-08-27 08:31 BUG #8400: DB size changed after restore ajayaksadvance@gmail.com
@ 2013-08-30 18:33 ` Kevin Grittner <kgrittn@ymail.com>
  2013-08-30 18:41   ` Re: BUG #8400: DB size changed after restore John R Pierce <pierce@hogranch.com>
  0 siblings, 1 reply; 3+ messages in thread

From: Kevin Grittner @ 2013-08-30 18:33 UTC (permalink / raw)
  To: ajayaksadvance@gmail.com <ajayaksadvance@gmail.com>; pgsql-bugs

"ajayaksadvance@gmail.com" <ajayaksadvance@gmail.com> wrote:

> PostgreSQL version: 9.2.0

There have been many fixes for bugs and security vulnerabilities in
the 9.2 minor releases since 9.2.0.

http://www.postgresql.org/support/versioning/

> I am not sure its a bug or not but need some information on this.

There's no real evidence of a bug, it would have been better to
post a question to: pgsql-general@postgresql.org

> I am doing upgrade from 8.4 to 9.2 hence DB dump and then
> restore.

Normally when upgrading with this technique you should use the
pg_dump executable from the target version to dump the old
database.  The newer software understands previous storage formats,
but the older software doesn't know anything about versions that
were written later.

> On postgrse 8.4 , i have DB of size 32 GB.
> SELECT pg_size_pretty(pg_database_size('<DBNAME>'))
>   As fulldbsize;
>
> I have done vacummdb before going for dump.

That will make space available for re-use, but generally won't
eliminate dead space or reduce file sizes.

> I have first done schema dump and then DB data and all is fine.
>
> But on restore its running successfully but i am getting only
> size 9213 MB.
>
> Dont know, what exactly happend?

Well, you could narrow the possibilities by restoring that dump to
an 8.4 database and see how big that is.  Some major releases have
improved the storage formats for some data types, like numeric; but
you might just be dealing with dead space from deletes and updates.

--
Kevin Grittner
EDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company


-- 
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs



^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: BUG #8400: DB size changed after restore
  2013-08-27 08:31 BUG #8400: DB size changed after restore ajayaksadvance@gmail.com
  2013-08-30 18:33 ` Re: BUG #8400: DB size changed after restore Kevin Grittner <kgrittn@ymail.com>
@ 2013-08-30 18:41   ` John R Pierce <pierce@hogranch.com>
  0 siblings, 0 replies; 3+ messages in thread

From: John R Pierce @ 2013-08-30 18:41 UTC (permalink / raw)
  To: pgsql-bugs

On 8/30/2013 11:33 AM, Kevin Grittner wrote:
> but
> you might just be dealing with dead space from deletes and updates.


I would suggest 'likely are' rather than 'might be'.


-- 
john r pierce                                      37N 122W
somewhere on the middle of the left coast



-- 
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs



^ permalink  raw  reply  [nested|flat] 3+ messages in thread


end of thread, other threads:[~2013-08-30 18:41 UTC | newest]

Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2013-08-27 08:31 BUG #8400: DB size changed after restore ajayaksadvance@gmail.com
2013-08-30 18:33 ` Kevin Grittner <kgrittn@ymail.com>
2013-08-30 18:41   ` John R Pierce <pierce@hogranch.com>

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