Skip site navigation (1) Skip section navigation (2)

Postgres vs. MySQL

From: Evilio del Rio <edelrio(at)cmima(dot)csic(dot)es>
To: dspam-users(at)networkdweebs(dot)com
Cc: pgsql-performance(at)postgresql(dot)org
Subject: Postgres vs. MySQL
Date: 2004-11-24 13:14:18
Message-ID: (view raw or whole thread)
Lists: pgsql-performance

I have installed the dspam filter
( on our mail server
(RedHat 7.3 Linux with sendmail 8.13 and procmail). I have ~300 users
with a quite low traffic of 4000 messages/day. So it's a quite common
platform/environment, nothing spectacular.

First time(s) I tried the Postgres interface that was already installed
for other applications.  Whenever I begin to train and/or filter
messages throug dspam the performance is incredibly bad. First messages
are ok but soon the filter time begins to increase to about 30 seconds
or more! I looked for some optimization both for the linux  kernel and the
postgres server.  Nothing has work for me. I always have the same
behavior. For isolation purposes I started using another server just to
hold the dspam database and nothing else. No matter what I do: postgres
gets slower and slower with each new message fed or filtered. 

Several strategies have failed: newest RPMs from,
pg_autovacuum, etc.

I finally tried the MySQL driver.

I have started using this tool right now for dspam, so I am a newcomer
in MySQL.

The result: after some preparation in configuring some parameters for
mysqld (with the "QuickStart" Guide from all works fine!

It's incredible! the same servers, the same messages, the same dspam
compilation (well each one with the corresponding
--with-storage-driver=*sql_drv). Postgres is getting worst than
30s/message and MySQL process the same in less than a second.

I can surrender the Postgres server by just corpus-feeding one single
short message to each user (it takes hours to process 300 users!).

On the other hand, MySQL only takes a few minutes to process the same

I do not want to make flame over Postgres (I have always prefered it for
its capabilities) but I am absolutely impressed by MySQL (I have seen
the light!)

Please, could anyone explain me this difference?
Is Postgres that bad?
Is MySQL that good?
Am I the only one to have observed this behavior?



Evilio Jose del Rio Silvan   Centre Mediterrani d'Investigacions
edelrio(at)cmima(dot)csic(dot)es                Marines i Ambientals
"Microsoft sells you Windows, Linux gives you the whole house" - Anonymous


pgsql-performance by date

Next:From: Steinar H. GundersonDate: 2004-11-24 14:16:15
Subject: Re: Postgres vs. MySQL
Previous:From: Richard HuxtonDate: 2004-11-24 11:02:06
Subject: Re: FW: FW: Index usage

Privacy Policy | About PostgreSQL
Copyright © 1996-2015 The PostgreSQL Global Development Group