mirror of
https://github.com/MariaDB/server.git
synced 2025-01-20 05:52:27 +01:00
Merge dev3-138.dev.cn.tlan:/home/zhl/mysql/mysql-5.0/mysql-5.0-ndb-bj
into dev3-138.dev.cn.tlan:/home/zhl/mysql/mysql-5.1/mysql-5.1-ndb-bj sql/sql_base.cc: Auto merged sql/sql_view.cc: Auto merged storage/ndb/src/mgmsrv/ConfigInfo.cpp: Auto merged storage/ndb/src/mgmsrv/MgmtSrvr.cpp: Auto merged
This commit is contained in:
commit
bea213ff81
2 changed files with 13 additions and 3 deletions
|
@ -2688,6 +2688,13 @@ transformNode(InitConfigFileParser::Context & ctx, const char * data){
|
|||
return false;
|
||||
}
|
||||
|
||||
if(id >= MAX_NODES)
|
||||
{
|
||||
ctx.reportError("too many nodes configured, only up to %d nodes supported.",
|
||||
MAX_NODES);
|
||||
return false;
|
||||
}
|
||||
|
||||
// next node id _always_ next numbers after last used id
|
||||
ctx.m_userProperties.put("NextNodeId", id+1, true);
|
||||
|
||||
|
@ -3579,11 +3586,11 @@ sanity_checks(Vector<ConfigInfo::ConfigRuleSection>§ions,
|
|||
Uint32 mgm_nodes = 0;
|
||||
Uint32 api_nodes = 0;
|
||||
if (!ctx.m_userProperties.get("DB", &db_nodes)) {
|
||||
ctx.reportError("At least one database node should be defined in config file");
|
||||
ctx.reportError("At least one database node (ndbd) should be defined in config file");
|
||||
return false;
|
||||
}
|
||||
if (!ctx.m_userProperties.get("MGM", &mgm_nodes)) {
|
||||
ctx.reportError("At least one management server node should be defined in config file");
|
||||
ctx.reportError("At least one management server node (ndb_mgmd) should be defined in config file");
|
||||
return false;
|
||||
}
|
||||
if (!ctx.m_userProperties.get("API", &api_nodes)) {
|
||||
|
|
|
@ -449,7 +449,10 @@ MgmtSrvr::MgmtSrvr(SocketServer *socket_server,
|
|||
// read config locally
|
||||
_config= readConfig();
|
||||
if (_config == 0) {
|
||||
ndbout << "Unable to read config file" << endl;
|
||||
if (config_filename != NULL)
|
||||
ndbout << "Invalid configuration file: " << config_filename << endl;
|
||||
else
|
||||
ndbout << "Invalid configuration file" << endl;
|
||||
exit(-1);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue