I had no idea it was that bad!
Dec. 4th, 2006 11:54 amI was checking out a review of new Xeon hardware, which was using MySQL 4, MySQL 5 and PostgreSQL 8.2 beta. The test is mostly realistic, consisting of PHP pages doing queries, taken from their own website, with an exception, that the dataset is restrained to something like 2 gigabytes, so that it doesn't hit the disks too much (this can make it either unrealistic, or is a strategy to stay sane).
The article mostly talks about the hardware, but the results put MySQL in, uh, a "bad light". MySQL 4.1.20, going from a one single-core processor to two dual-core processors (that's between twice to four times the horsepower), goes 56% faster. MySQL 5.0.20a goes 40% faster. PostgreSQL 8.2-dev (okay, dev, whatever, have you looked at MySQL recently?) puts in a 224% increase in performance, meaning that it actually gets the "slightly more than three times as fast" you'd expect from having "between two and four times the horsepower".
They also show graphs of how they behave dealing with concurrent requests, where you see MySQL peak at about 520 requests per second, then goes down as the number of concurrent requests. PostgreSQL, on the other hand, slowly goes up to about 640 requests per second, then pretty much stays there, being clearly limited by the hardware to that level, a textbook example of nice scaling. At a concurrency of 100, PostgreSQL pulls in nearly twice as many requests per second than MySQL.
So much for MySQL being "the fast one" (PostgreSQL was traditionally the "safe and correct one", which was already nothing to sneeze at, as long as it managed to be "fast enough").
The article mostly talks about the hardware, but the results put MySQL in, uh, a "bad light". MySQL 4.1.20, going from a one single-core processor to two dual-core processors (that's between twice to four times the horsepower), goes 56% faster. MySQL 5.0.20a goes 40% faster. PostgreSQL 8.2-dev (okay, dev, whatever, have you looked at MySQL recently?) puts in a 224% increase in performance, meaning that it actually gets the "slightly more than three times as fast" you'd expect from having "between two and four times the horsepower".
They also show graphs of how they behave dealing with concurrent requests, where you see MySQL peak at about 520 requests per second, then goes down as the number of concurrent requests. PostgreSQL, on the other hand, slowly goes up to about 640 requests per second, then pretty much stays there, being clearly limited by the hardware to that level, a textbook example of nice scaling. At a concurrency of 100, PostgreSQL pulls in nearly twice as many requests per second than MySQL.
So much for MySQL being "the fast one" (PostgreSQL was traditionally the "safe and correct one", which was already nothing to sneeze at, as long as it managed to be "fast enough").
no subject
Date: 2006-12-04 03:28 pm (UTC)no subject
Date: 2006-12-04 04:22 pm (UTC)Especially as that involves the PHP people becoming sensible. No chance, right there.
no subject
Date: 2006-12-04 05:36 pm (UTC)no subject
Date: 2006-12-04 09:18 pm (UTC)no subject
Date: 2006-12-04 09:45 pm (UTC)no subject
Date: 2006-12-04 09:53 pm (UTC)no subject
Date: 2006-12-04 10:08 pm (UTC)I know what I'm going to do, though!
no subject
Date: 2006-12-04 10:05 pm (UTC)This is also one of the reason the PostgreSQL people have struggled so much to get things working on Windows...
Note, also, that of the two, they're the one with a non-blocking client API (like with Xlib, you get the file descriptor and you have to call it back when it's readable). That just plains reeks of smartness and sanity, right there.
no subject
Date: 2006-12-05 09:32 pm (UTC)no subject
Date: 2006-12-05 09:44 pm (UTC)