pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: David Barton <dave@oneit.com.au>
To: pgsql-performance@postgresql.org
Subject: Re: High Disk write and space taken by PostgreSQL
Date: Thu, 16 Aug 2012 11:36:53 +0800
Message-ID: <502C6AD5.4070407@oneit.com.au> (raw)
In-Reply-To: <CA+-36iFtmVsuvrXbahBX=29Sn-9XsaZpWHQfg9dmOf3SEkJcug@mail.gmail.com>
References: <CA+-36iFtmVsuvrXbahBX=29Sn-9XsaZpWHQfg9dmOf3SEkJcug@mail.gmail.com>

Hi Ramesh,

Are you able to provide a table schema?  Were you using MyISAM or InnoDB 
on MySQL?

If you back up the database & restore clean, what is the size comparison 
of the database filed on the restored copy to the existing one?  It may 
be full of empty tuples.  Is there any period where you could try a full 
vacuum?

What are your indexes?  Is the size in the indexes or the database tables?

At the current rate of insertion, that table is going to get very large 
very quickly.  Do you have anything deleting the rows afterwards?  I 
have no experience with databases past 50M rows, so my questions are 
just so you can line up the right info for when the real experts get 
online :-)

Regards, David

On 16/08/12 11:23, J Ramesh Kumar wrote:
>
> Hi,
>
> My application has high data intensive operations (high number of 
> inserts 1500 per sec.). I switched my application from MySQL to 
> PostgreSQL. When I take performance comparison report between mysql 
> and pgsql, I found that, there are huge difference in disk writes and 
> disk space taken. Below stats shows the difference between MySQL and 
> PostgreSQL.
>
>
> 	*MySQL* 	*PostgreSQL*
> Inserts Per Second* 	1500 	1500
> Updates Per Second* 	6.5 	6.5
> Disk Write Per Second* 	0.9 MB 	6.2 MB
> Database Size Increased Per day* 	13 GB 	36 GB
>
>
> * approx values
>
> Why this huge difference in disk writes and disk space utilization? 
> How can I reduce the disk write and space ? Kindly help me. Please let 
> me know, if you require any other information(such as postgres.conf).
>
> Thanks,
> Ramesh

view thread (14+ messages)  latest in thread

Message-ID: <502C6AD5.4070407@oneit.com.au>
Permalink:  ../502C6AD5.4070407@oneit.com.au/
Also on:    postgresql.org/message-id/502C6AD5.4070407@oneit.com.au

 · 

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-performance@postgresql.org
  Cc: dave@oneit.com.au
  Subject: Re: High Disk write and space taken by PostgreSQL
  In-Reply-To: <502C6AD5.4070407@oneit.com.au>

* 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