summaryrefslogtreecommitdiff
path: root/storage/innobase/srv
diff options
context:
space:
mode:
Diffstat (limited to 'storage/innobase/srv')
-rw-r--r--storage/innobase/srv/srv0mon.cc12
-rw-r--r--storage/innobase/srv/srv0srv.cc48
-rw-r--r--storage/innobase/srv/srv0start.cc2
3 files changed, 14 insertions, 48 deletions
diff --git a/storage/innobase/srv/srv0mon.cc b/storage/innobase/srv/srv0mon.cc
index 60fef24d183..b6496d03908 100644
--- a/storage/innobase/srv/srv0mon.cc
+++ b/storage/innobase/srv/srv0mon.cc
@@ -909,7 +909,7 @@ static monitor_info_t innodb_counter_info[] =
MONITOR_DEFAULT_START, MONITOR_MODULE_INDEX},
{"index_page_splits", "index", "Number of index page splits",
- MONITOR_NONE,
+ MONITOR_EXISTING,
MONITOR_DEFAULT_START, MONITOR_INDEX_SPLIT},
{"index_page_merge_attempts", "index",
@@ -1411,10 +1411,12 @@ srv_mon_process_existing_counter(
/* Get the value from corresponding global variable */
switch (monitor_id) {
- /* export_vars.innodb_buffer_pool_reads. Num Reads from
- disk (page not in buffer) */
+ case MONITOR_INDEX_SPLIT:
+ value = buf_pool.pages_split;
+ break;
+
case MONITOR_OVLD_BUF_POOL_READS:
- value = srv_stats.buf_pool_reads;
+ value = buf_pool.stat.n_pages_read;
break;
/* innodb_buffer_pool_read_requests, the number of logical
@@ -1475,7 +1477,7 @@ srv_mon_process_existing_counter(
/* innodb_buffer_pool_bytes_dirty */
case MONITOR_OVLD_BUF_POOL_BYTES_DIRTY:
- value = buf_pool.stat.flush_list_bytes;
+ value = buf_pool.flush_list_bytes;
break;
/* innodb_buffer_pool_pages_free */
diff --git a/storage/innobase/srv/srv0srv.cc b/storage/innobase/srv/srv0srv.cc
index c16868b5cf5..2e9f5a0eff8 100644
--- a/storage/innobase/srv/srv0srv.cc
+++ b/storage/innobase/srv/srv0srv.cc
@@ -675,6 +675,7 @@ void srv_boot()
if (transactional_lock_enabled())
sql_print_information("InnoDB: Using transactional memory");
#endif
+ buf_dblwr.init();
srv_thread_pool_init();
trx_pool_init();
srv_init();
@@ -1001,59 +1002,22 @@ srv_export_innodb_status(void)
export_vars.innodb_data_writes = os_n_file_writes;
- ulint dblwr = 0;
-
- if (buf_dblwr.is_initialised()) {
- buf_dblwr.lock();
- dblwr = buf_dblwr.submitted();
- export_vars.innodb_dblwr_pages_written = buf_dblwr.written();
- export_vars.innodb_dblwr_writes = buf_dblwr.batches();
- buf_dblwr.unlock();
- }
+ buf_dblwr.lock();
+ ulint dblwr = buf_dblwr.submitted();
+ export_vars.innodb_dblwr_pages_written = buf_dblwr.written();
+ export_vars.innodb_dblwr_writes = buf_dblwr.batches();
+ buf_dblwr.unlock();
export_vars.innodb_data_written = srv_stats.data_written + dblwr;
- export_vars.innodb_buffer_pool_read_requests
- = buf_pool.stat.n_page_gets;
-
export_vars.innodb_buffer_pool_write_requests =
srv_stats.buf_pool_write_requests;
- export_vars.innodb_buffer_pool_reads = srv_stats.buf_pool_reads;
-
- export_vars.innodb_buffer_pool_read_ahead_rnd =
- buf_pool.stat.n_ra_pages_read_rnd;
-
- export_vars.innodb_buffer_pool_read_ahead =
- buf_pool.stat.n_ra_pages_read;
-
- export_vars.innodb_buffer_pool_read_ahead_evicted =
- buf_pool.stat.n_ra_pages_evicted;
-
- export_vars.innodb_buffer_pool_pages_data =
- UT_LIST_GET_LEN(buf_pool.LRU);
-
export_vars.innodb_buffer_pool_bytes_data =
buf_pool.stat.LRU_bytes
+ (UT_LIST_GET_LEN(buf_pool.unzip_LRU)
<< srv_page_size_shift);
- export_vars.innodb_buffer_pool_pages_dirty =
- UT_LIST_GET_LEN(buf_pool.flush_list);
-
- export_vars.innodb_buffer_pool_pages_made_young
- = buf_pool.stat.n_pages_made_young;
- export_vars.innodb_buffer_pool_pages_made_not_young
- = buf_pool.stat.n_pages_not_made_young;
-
- export_vars.innodb_buffer_pool_pages_old = buf_pool.LRU_old_len;
-
- export_vars.innodb_buffer_pool_bytes_dirty =
- buf_pool.stat.flush_list_bytes;
-
- export_vars.innodb_buffer_pool_pages_free =
- UT_LIST_GET_LEN(buf_pool.free);
-
#ifdef UNIV_DEBUG
export_vars.innodb_buffer_pool_pages_latched =
buf_get_latched_pages_number();
diff --git a/storage/innobase/srv/srv0start.cc b/storage/innobase/srv/srv0start.cc
index b0adc15300c..a881ae0ad6a 100644
--- a/storage/innobase/srv/srv0start.cc
+++ b/storage/innobase/srv/srv0start.cc
@@ -1997,7 +1997,7 @@ void innodb_shutdown()
ut_ad(dict_sys.is_initialised() || !srv_was_started);
ut_ad(trx_sys.is_initialised() || !srv_was_started);
- ut_ad(buf_dblwr.is_initialised() || !srv_was_started
+ ut_ad(buf_dblwr.is_created() || !srv_was_started
|| srv_read_only_mode
|| srv_force_recovery >= SRV_FORCE_NO_TRX_UNDO);
ut_ad(lock_sys.is_initialised() || !srv_was_started);