MySQL Forums
Forum List  »  InnoDB

Please help me diagnose a possible mem leak
Posted by: Michael Rubin
Date: April 03, 2013 08:33PM

I'm seeing what looks like a memleak once I increased my buffer-pool size beyond 2-4G (before I did this, the server could run fine for months). The symptoms are: mysqld starts filling up gigs of swap space; free memory on the machine goes towards 0 (including file i/o buffering); yet looking at `top`, mysqld usage (both rss and virt) are nowhere near what `free` is showing. If I shut down mysqld, the swap space clears out to ~0, but there are gigs of unaccounted-for usage that don't free up. If I reboot the machine, that usage clears up (but if I put mysqld under some load, it starts filling up RAM again).

Please let me know if there are any tricks to diagnosing this further. Thank you very much for any assistance!

Version: 5.5.30-log - MySQL Community Server (GPL) by Remi
Machine: CentOS 6.3 x86_64, 16G of RAM, 4cpu

My config is as follows:

[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
user=mysql
# Disabling symbolic-links is recommended to prevent assorted security risks
symbolic-links=0

log-error=/var/log/mysqld.log
# Will log MySQL queries, This log will grow quickly
#log=/var/log/mysql-query.log
slow-query-log = 1
slow_query_log_file = /var/log/mysql-slow.log
long_query_time = 2

innodb_file_per_table

# Set buffer pool size to 50-80% of your computer's memory
innodb_buffer_pool_size=2144M # setting this to 8G or even 6G seems to leak
innodb_additional_mem_pool_size=20M
innodb_buffer_pool_instances=4

# Set the log file size to about 25% of the buffer pool size
innodb_log_file_size=192M
innodb_log_buffer_size=8M

#innodb_flush_log_at_trx_commit=0
innodb_rollback_on_timeout=1

#innodb_file_io_threads=16
#innodb_thread_concurrency=8

log-bin=1
binlog-format=MIXED
expire_logs_days=14
server-id=1
relay-log=mysqld-relay-bin

innodb_purge_threads=1

sort_buffer_size=128M
join_buffer_size=128M
read_rnd_buffer_size=32M
bulk_insert_buffer_size=32M
tmp_table_size=256M
max_heap_table_size=256M
table_cache=1024
max_connections=512
max_allowed_packet=16M

key_buffer_size=16M # myisam only
read_buffer_size=16M # myisam only
myisam_sort_buffer_size=16M
myisam_max_sort_file_size=1G

#thread_cache_size = 16
#thread_cache = 8
#thread_concurrency = 8

[mysqld_safe]
log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid

# Will log MySQL queries, This log will grow quickly
#log=/var/log/mysql-query.log

log-slow-queries = /var/log/mysql-slow.log
long_query_time = 2



Edited 1 time(s). Last edit at 04/03/2013 08:34PM by Michael Rubin.

Options: ReplyQuote


Subject
Views
Written By
Posted
Please help me diagnose a possible mem leak
1331
April 03, 2013 08:33PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.