MySQL Forums
Forum List  »  Performance

Using multiple CPUs
Posted by: Ira Holtzer
Date: June 21, 2011 06:09AM

Hi,

We have MySQL on multiple servers in production for a while now. Today while looking into an optimization problem we were having, we found that mysql is using only 1 of the 2 CPUs on the box. These are HP DL360 G7 with 2 X E5620 (or sometimes E5630) CPUs. cpuinfo is showing 16 processors, 2 X quad X 2 HW Threads/core = 16.

The OS is Centos 5.5 and our mysql versions are 5.5.8-11 depending on the box.

running atop we see below (hopefully) that only one cpu is utilized (seeing 8 "processors" working). Actually it's all the odd numbered processors. I am not 100% sure how linux is numbering them, but it seems to me they are all on the same CPU.
As far as I understood mysql should use all processors it has available, and there is no setting for CPU usage/affinity

CPU | sys 17% | user 194% | irq 6% | | | idle 1382% | wait 0% | | | steal 0% | guest 0% |
cpu | sys 2% | user 27% | irq 1% | | | idle 69% | cpu009 w 0% | | | steal 0% | guest 0% |
cpu | sys 2% | user 24% | irq 1% | | | idle 72% | cpu001 w 0% | | | steal 0% | guest 0% |
cpu | sys 2% | user 24% | irq 1% | | | idle 73% | cpu013 w 0% | | | steal 0% | guest 0% |
cpu | sys 2% | user 24% | irq 1% | | | idle 73% | cpu005 w 0% | | | steal 0% | guest 0% |
cpu | sys 2% | user 23% | irq 1% | | | idle 75% | cpu011 w 0% | | | steal 0% | guest 0% |
cpu | sys 2% | user 21% | irq 1% | | | idle 77% | cpu015 w 0% | | | steal 0% | guest 0% |
cpu | sys 2% | user 20% | irq 1% | | | idle 78% | cpu003 w 0% | | | steal 0% | guest 0% |
cpu | sys 2% | user 17% | irq 1% | | | idle 81% | cpu007 w 0% | | | steal 0% | guest 0% |
cpu | sys 0% | user 3% | irq 0% | | | idle 96% | cpu004 w 0% | | | steal 0% | guest 0% |
cpu | sys 0% | user 2% | irq 0% | | | idle 98% | cpu000 w 0% | | | steal 0% | guest 0% |
cpu | sys 0% | user 2% | irq 0% | | | idle 98% | cpu012 w 0% | | | steal 0% | guest 0% |
cpu | sys 0% | user 2% | irq 0% | | | idle 98% | cpu014 w 0% | | | steal 0% | guest 0% |
cpu | sys 0% | user 2% | irq 0% | | | idle 98% | cpu008 w 0% | | | steal 0% | guest 0% |
cpu | sys 0% | user 1% | irq 0% | | | idle 98% | cpu010 w 0% | | | steal 0% | guest 0% |
cpu | sys 0% | user 1% | irq 0% | | | idle 99% | cpu006 w 0% | | | steal 0% | guest 0% |
cpu | sys 0% | user 1% | irq 0% | | | idle 99% | cpu002 w 0% | | | steal 0% | guest 0% |

Did I get it right?
Can I tell mysql to use the other cpu? is there a point?

Options: ReplyQuote


Subject
Views
Written By
Posted
Using multiple CPUs
2992
June 21, 2011 06:09AM
1032
June 22, 2011 07:30PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.