Hi ,

Thank you very much for your compelete description about MySQL and multi
processor platforms .
According to your mail if I have several connection to my SQL server and I
have more than 1 CPU and installed the SMP on my machine the MySQL
performance will be better than a single CPU and If I have only 1 connection
to my SQL server then single and dual CPU are not import for this situation
.
So it is ok ! cause I have about 200 concurrence connection to my SQL
machine and it seems that be better to have more that one CPU .
About other SQL servers that you said support multi processing alone without
depending on OS and SMP . Can you tell me them ?!
I thinks that Oracle would be one of them .

--
Regards

    ============================================================
   /  Seyyed Hamid Reza    /        WINDOWS FOR NOW  !!            /
  /  Hashemi Golpayegani  /  Linux for future , FreeBSD for ever  /
 /    Morva System Co.   / ------------------------------------- /
/  Network Administrator/ [EMAIL PROTECTED]   ,   ICQ# : 42209876 /
===========================================================


-----Original Message-----
From: Nemholt, Jesper Frank [mailto:[EMAIL PROTECTED]]
Sent: Sunday, April 01, 2001 3:25 PM
To: 'Hamid Hashemi Golpayegani'; [EMAIL PROTECTED]
Subject: RE: Dual Processor and MySQL !


> -----Original Message-----
> From: Hamid Hashemi Golpayegani [mailto:[EMAIL PROTECTED]]
> Sent: sábado, 31 de marzo de 2001 17:09
> To: [EMAIL PROTECTED]
> Subject: Dual Processor and MySQL !
>
>
> Hi ,
>
> Sorry for this question may be this question asked before but
> I can't find
> it .
> I want to know that an SMP Dual CPU machine for a MySQL
> server is better
> that a single CPU machine ?!
> I mean is the MySQl use the both CPU's for processing or not ?
> and how much affect on the responding and which parameters
> are going better
> in this case ?!

As said by other, if the OS supports SMP, MySQL will benefit from this,
since MySQL is a threaded application.
However, a singlethreaded SQL (ie. a SQL MySQL is unable to break up into
several parts) will only run on one CPU at a time, and this is the situation
you will see most of the time. In fact I'm not even sure MySQL does try to
break up SQLs into >1 threads, but I know other database servers do.
A SQL with several subselects is a good example. Every subselect can run as
a seperate thread, but as you probably know, MySQL doesn't support
subselects, so there...

So, you should not expect to get better single SQL performance from a SMP
machine. Where you will get better performance is if you have >1 concurrent
user or rather >1 concurrent SQL (who don't lock each others tables),
because MySQL (or rather the OS) then will balance the SQLs between the
available CPUs.

You will allways get better performance out of a single CPU machine rather
than a SMP machine if the CPU type is the same and the single processor is
about the same clock frequency as the SMP processors combined.

A single Pentium III 1 GHz will in single threaded tasks be a little more
than twice as fast as a dual Pentium III 500 MHz, and in every case allways
faster.
If you serve a single threaded task to a dual Pentium III 500 MHz, it
perform like a single Pentium III 500 MHz. If you serve a multithreaded task
to it, it'll perform somewhere between 500 MHz and close to 1 GHz.

SMP should only be considered when you can't get any faster with a single
CPU machine, and if you need that extra performance, you should still use
the fastest clocked CPUs for SMP, because if you don't it'll feel slow in
singlethreaded performance.

I've run MySQL on machines with between 2 & 12 CPUs running either Linux,
Solaris or Tru64. With one SQL active at any given time, I've never seen
MySQL use more than one CPU. With two SQLs active at the same time, it uses
2 CPUs and so forth, unless the SQLs lock each others tables, which in fact,
for me, is a major problem in MySQL.

You need a recent MySQL to fully benefit from SMP, since older 3.22.x
doesn't have any configure options to control SMP behavior.
Secondly, on some platforms it is quite important to compile MySQL with the
right flags in order to get the best SMP/thread performance.


--
Un saludo / Venlig hilsen / Regards

Jesper Frank Nemholt
Unix System Manager
Compaq Computer Corporation

Phone : +34 699 419 171
E-Mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to