MyBB Community Forums

Full Version: MySQLd using a lot of RAM
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello

I have a blank MyBB Forum running and MySQLd seems to be taking up the memory. Any idea on how to reduce usage?

Regards
URL? Can you post the stats here?
(2011-12-13, 08:25 PM)Paul H. Wrote: [ -> ]URL? Can you post the stats here?

It's a VPS with 512MB RAM and just went down because of high RAM usage. I ran top -s on the VPS and it is MySQLD that is using it up. I only have MyBB running which is blank/no traffic.

www.hostdevforum.com

It's eating the RAM up.
This isn't a MyBB issue. You need to configure and optimize your my.cnf file.
(2011-12-13, 08:30 PM)Nathan Malcolm Wrote: [ -> ]This isn't a MyBB issue. You need to configure and optimize your my.cnf file.

Hi Nathan

Thanks for your reply.
Are there any guides on doing this?

Regards
If an empty forum is causing MySQL to use a lot of memory it must be badly misconfigured. Unfortunately though we can't help much you set up your server, this is the MyBB forum, you'd be better off Googling for MySQL configuration tips, asking on a specialist site, or on stackoverflow or something.
MySQl as default is a pretty major memory hog. If you add the following lines to your my.cnf then restart MYSQL, you should see a good reduction in usage (feel free to tweak them, of course);

[mysqld]
default-storage-engine = myisam
key_buffer = 8M
query_cache_size = 8M
query_cache_limit = 4M
max_connections=25
thread_cache=1
skip-innodb 
query_cache_min_res_unit=0
tmp_table_size = 4M
max_heap_table_size = 4M
table_cache=256
concurrent_insert=2 

I use similar settings on my VPS with 512mb of guaranteed memory and I'm fine.