4

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?

0

3 Answers 3

2

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.

1
  • +1 - it's all about the index.
    – sybreon
    Jul 2, 2010 at 14:28
0

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

1
  • 1
    With most queries selecting a single row by PK, the query cache isn't going to get you much anyways. Jul 1, 2010 at 20:29
0

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.

Not the answer you're looking for? Browse other questions tagged .