diff options
author | unknown <tomas@poseidon.ndb.mysql.com> | 2006-03-22 10:17:29 +0100 |
---|---|---|
committer | unknown <tomas@poseidon.ndb.mysql.com> | 2006-03-22 10:17:29 +0100 |
commit | 07627827e9c06fbd2a38262fc66d23756a1a1eac (patch) | |
tree | e8cd3ae83d55738d60df66229b6f7b79272cd755 | |
parent | 0cfbdc4e00dfcd6aad0d1510c55a38c9c0818999 (diff) | |
download | mariadb-git-07627827e9c06fbd2a38262fc66d23756a1a1eac.tar.gz |
added config parameter InitialNoOfOpenFiles
-rw-r--r-- | mysql-test/ndb/ndb_config_2_node.ini | 3 | ||||
-rw-r--r-- | storage/ndb/src/kernel/blocks/ndbfs/Ndbfs.cpp | 6 | ||||
-rw-r--r-- | storage/ndb/src/mgmsrv/ConfigInfo.cpp | 12 |
3 files changed, 19 insertions, 2 deletions
diff --git a/mysql-test/ndb/ndb_config_2_node.ini b/mysql-test/ndb/ndb_config_2_node.ini index e7a12dbde77..26ed928a7cf 100644 --- a/mysql-test/ndb/ndb_config_2_node.ini +++ b/mysql-test/ndb/ndb_config_2_node.ini @@ -12,6 +12,9 @@ MaxNoOfAttributes= CHOOSE_MaxNoOfAttributes TimeBetweenGlobalCheckpoints= 500 NoOfFragmentLogFiles= 3 DiskPageBufferMemory= CHOOSE_DiskPageBufferMemory +# the following parametes just function as a small regression +# test that the parameter exists +InitialNoOfOpenFiles= 27 [ndbd] HostName= CHOOSE_HOSTNAME_1 # hostname is a valid network adress diff --git a/storage/ndb/src/kernel/blocks/ndbfs/Ndbfs.cpp b/storage/ndb/src/kernel/blocks/ndbfs/Ndbfs.cpp index 138b519631c..46324ff4373 100644 --- a/storage/ndb/src/kernel/blocks/ndbfs/Ndbfs.cpp +++ b/storage/ndb/src/kernel/blocks/ndbfs/Ndbfs.cpp @@ -108,9 +108,11 @@ Ndbfs::execREAD_CONFIG_REQ(Signal* signal) m_maxFiles = 40; ndb_mgm_get_int_parameter(p, CFG_DB_MAX_OPEN_FILES, &m_maxFiles); - + Uint32 noIdleFiles = 27; + ndb_mgm_get_int_parameter(p, CFG_DB_INITIAL_OPEN_FILES, &m_maxFiles); + if (noIdleFiles > m_maxFiles) + m_maxFiles = noIdleFiles; // Create idle AsyncFiles - Uint32 noIdleFiles = m_maxFiles > 27 ? 27 : m_maxFiles ; for (Uint32 i = 0; i < noIdleFiles; i++){ theIdleFiles.push_back(createAsyncFile()); } diff --git a/storage/ndb/src/mgmsrv/ConfigInfo.cpp b/storage/ndb/src/mgmsrv/ConfigInfo.cpp index 214a3b41e62..4bd64d98a7f 100644 --- a/storage/ndb/src/mgmsrv/ConfigInfo.cpp +++ b/storage/ndb/src/mgmsrv/ConfigInfo.cpp @@ -893,6 +893,18 @@ const ConfigInfo::ParamInfo ConfigInfo::m_ParamInfo[] = { STR_VALUE(MAX_INT_RNIL) }, { + CFG_DB_MAX_OPEN_FILES, + "InitialNoOfOpenFiles", + DB_TOKEN, + "Initial number of files open per "DB_TOKEN_PRINT" node.(One thread is created per file)", + ConfigInfo::CI_USED, + false, + ConfigInfo::CI_INT, + "27", + "20", + STR_VALUE(MAX_INT_RNIL) }, + + { CFG_DB_TRANSACTION_CHECK_INTERVAL, "TimeBetweenInactiveTransactionAbortCheck", DB_TOKEN, |