Commit 713999a4 authored by Michael Widenius's avatar Michael Widenius

Allow one to decrease page-buffer-size down to 1M (from 128M) for maria_read_log

Don't allow too low value of pagecache_buffer_size for mysqld

storage/maria/ha_maria.cc:
  Don't allow too low value of pagecache_buffer_size (as it will stop mysqld from starting)
storage/maria/maria_read_log.c:
  Allow one to decrease page-buffer-size down to 1M (from 128M)
parent a008186f
...@@ -191,7 +191,7 @@ static MYSQL_SYSVAR_ULONGLONG(pagecache_buffer_size, pagecache_buffer_size, ...@@ -191,7 +191,7 @@ static MYSQL_SYSVAR_ULONGLONG(pagecache_buffer_size, pagecache_buffer_size,
"The size of the buffer used for index blocks for Maria tables. " "The size of the buffer used for index blocks for Maria tables. "
"Increase this to get better index handling (for all reads and " "Increase this to get better index handling (for all reads and "
"multiple writes) to as much as you can afford.", 0, 0, "multiple writes) to as much as you can afford.", 0, 0,
KEY_CACHE_SIZE, MALLOC_OVERHEAD, ~(ulong) 0, IO_SIZE); KEY_CACHE_SIZE, 8192*16L, ~(ulong) 0, IO_SIZE);
static MYSQL_SYSVAR_ULONG(pagecache_division_limit, pagecache_division_limit, static MYSQL_SYSVAR_ULONG(pagecache_division_limit, pagecache_division_limit,
PLUGIN_VAR_RQCMDARG, PLUGIN_VAR_RQCMDARG,
......
...@@ -199,7 +199,8 @@ static struct my_option my_long_options[] = ...@@ -199,7 +199,8 @@ static struct my_option my_long_options[] =
"Path to the directory where to store transactional log", "Path to the directory where to store transactional log",
(uchar **) &maria_data_root, (uchar **) &maria_data_root, 0, (uchar **) &maria_data_root, (uchar **) &maria_data_root, 0,
GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0}, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0},
{ "page-buffer-size", 'P', "", { "page-buffer-size", 'P',
"The size of the buffer used for index blocks for Maria tables",
&opt_page_buffer_size, &opt_page_buffer_size, 0, &opt_page_buffer_size, &opt_page_buffer_size, 0,
GET_ULONG, REQUIRED_ARG, (long) USE_BUFFER_INIT, GET_ULONG, REQUIRED_ARG, (long) USE_BUFFER_INIT,
1024L*1024L, (long) ~(ulong) 0, (long) MALLOC_OVERHEAD, 1024L*1024L, (long) ~(ulong) 0, (long) MALLOC_OVERHEAD,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment