Unanswered: mySQL Windows versus Linux performance
Just stumbled in here this evening. Glad to find a forum like this. Hope I can help as well as be helped.
Anybody ever done any serious testing of mySQL performance differences on Windows servers vs. Linux servers?
I moved a busy Invision Board forum (300MB db, 200+ active users) off of a Cobalt RAQ4 that was dying under the load. I split the web server and the database server. The new web server is a Celeron 2.4 with 1GB RAM, running Win 2003, IIS and PHP in CGI mode. The new database server is a Dual PIII 600 with 768MB RAM and SCSI drives, running Win 2000 and mySQL 4.1.7nt.
The anemic RAQ4 with it's puny AMD 400mhz processor, 512MB ram, and IDE drive, was serving about 15 other low-traffic sites in addition to the mySQL server and the busy Invision forum. It actually did a fairly credible job keeping up untl the forum got to 125 or more active users. After that, it got doggy.
The new web server and database server are doing little else except serving this forum, yet I am already maxing out at 500MB and 250 to 300 active users. The db server is tuned to use all of the RAM for MySQL (without resorting to swapping). I've tinkered with the my.cnf parameters many times. Yet, at peak periods with 250 or more active participants on the forum, both CPUs on the database server are pegged at 95% or better, and performance goes down the toilet.
I expected much better performance considering the dramatic upgrade in hardware, and I am wondering if mySQL on Windows is simply a much worse performing than on Linux.
Any suggestions, experiences in this area, anecdotal tales, spells, voodoo, or other relevant comments greatly appreciated.
Side note: Windows 2003 has proven to be a big disappointment from a web server stability standpoint. I have no axe to grind against Windows 2003; I use it in a shared hosting enviroment with great stability. I believe the problem is PHP, which doesn't seem to coexist very well.
I don't think there would be a noticable difference in performance between Linux or Windows. A couple of suggestions: add more RAM to the server. From my experience, 1GB of RAM should be the minimum, but with the kind of load you have, I'd make it 2GB. You should see a noticable difference just from that upgrade. If that still doesn't give you the performance you want, go to dual P4 instead of PIII... not even sure why you would use PIII processors.
I don't think there would be a noticable difference in performance between Linux or Windows. A couple of suggestions: add more RAM to the server. From my experience, 1GB of RAM should be the minimum, but with the kind of load you have, I'd make it 2GB. You should see a noticable difference just from that upgrade.
Not sure about this. So far, whether I tune MySQL to use 256MB, or use all available RAM, I don't see much difference in performance. I realize conventional wisdom is that more RAM is better, but so far, memory tuning hasn't yielded expected improvements.
Originally Posted by ranbla
If that still doesn't give you the performance you want, go to dual P4 instead of PIII... not even sure why you would use PIII processors.
Cause money doesn't grow on trees?
Keep in mind this database was previously running on a 512MB Cobalt RAQ (basically Pentium I class machine at 400Mhz), running Apache, Sendmail, FTP, etc., with a bunch of other domains. While the database size and number of users increased twofold, the Dual PIII machine is many times more powerful than the Cobalt RAQ. Hence my suspicion about Windows versus Linux.
Seriously, I do appreciate the input. I'm just not sure I understand the bottleneck yet. More study required, I suppose.