Question:
How can I optimize my mySQL database? It is huge (over 200K items) and it runs SUPER slow. Please help!?
Honamos
2007-04-11 06:41:05 UTC
We are using Debian with PHP. The site is similar to... http://www.qwikfliks.com/xgenesis.asp?nwct=yes, in which there are THOUSANDS of items that customers can browse through. The machine is an:
2800+ AMD Athlon64
1GB PC3200 Dual Channel RAM
80GB HD
Four answers:
anonymous
2007-04-11 06:47:52 UTC
mySQL is as fast as it gets. But it could be your table design.



Break the tables down to the minimum, then JOIN using indexes. So why carry a full address, when you can look that up from that single record. That's what relational databases and SQL are all about.



But from my point of view, your website is quite fast. GOOD WORK dude.



Good luck and Happy Computing!
sheepbalz
2007-04-11 14:09:28 UTC
Make sure that you have the tables indexed on the keys that you are using to access the data for selects and joins. It will help speed things up a bit. Also check your systems load to make sure that there isn't something else running that is sucking up the resources.
AnalProgrammer
2007-04-11 14:11:49 UTC
This link has all the information you need. I would place emphasis on indexes and how your code accesses the database. See notes on the explain command.
nutwpinut
2007-04-11 13:48:56 UTC
More Ram and faster HD is the biggest Hardware change you can do. 200k is not that bad, your queries and schema may be bad and need to be rewritten.


This content was originally posted on Y! Answers, a Q&A website that shut down in 2021.
Loading...