Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

This question already has an answer here:

I'm having a really hard time figuring out how much ram I need for this database. Right now it's one table that is mostly filled with text content and has +40k entries.

mysql> show table status;
+-------+--------+---------+------------+-------+----------------+-------------+--------    ---------+--------------+-----------+----------------+---------------------+---------------- -----+------------+-------------------+----------+----------------+---------+
| Name  | Engine | Version | Row_format | Rows  | Avg_row_length | Data_length |     Max_data_length | Index_length | Data_free | Auto_increment | Create_time         |   Update_time         | Check_time | Collation         | Checksum | Create_options | Comment |
| links | MyISAM |      10 | Dynamic    | 44135 |          76235 |  3364651760 | 281474976710655 |       454656 |         0 |          88275 | 2010-06-30 12:33:00 | 2010-07-01 14:41:56 | NULL       | latin1_swedish_ci |     NULL |                |         |
+-------+--------+---------+------------+-------+----------------+-------------+-----------------+--------------+-----------+----------------+---------------------+----------------  -----+------------+-------------------+----------+----------------+---------+
1 row in set (0.00 sec)

Just so you won't be confused -- this isn't 4gig yet but it will be here soon. I have a server that I want to put it on that has 512meg of ram -- is this going to be enough or do I need to upgrade?

Most queries are going to be selecting a single row on a unique key. Think of it as a blog with +40k articles.

Is there any formula for this? It seems like my index is only 1/2 meg or so -- that's all that needs to stay in memory right?

share|improve this question

marked as duplicate by mdpc, MadHatter, Bryan, RobM, Falcon Momot Jul 17 '13 at 1:35

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

I would think you should be fine. If the index can fit (and stay) in memory, that should be enough to get pretty decent performance, provided you aren't dealing with a huge request load or anything.

share|improve this answer
+1 - it's all about the index. – sybreon Jul 2 '10 at 14:28

I would say no.. MySQL will be at its best with a large query cache.. 512 is nothing these days.. more so for a DB of that size even if you aren't doing a lot of complex joins

share|improve this answer
With most queries selecting a single row by PK, the query cache isn't going to get you much anyways. – Eric Petroelje Jul 1 '10 at 20:29

i have a mysql database of only 150 mb and is for eccomerce site, i receive 1000 daily visitors and i need a server of 1 gb . The database is pretty whell structure in queries but that will work for me , i reccommend for you at least 2gb of ram.

share|improve this answer

Not the answer you're looking for? Browse other questions tagged or ask your own question.