From: Date: August 10 2006 12:24pm Subject: bk commit into 5.0 tree (root:1.2246) BUG#19045 List-Archive: http://lists.mysql.com/commits/10250 X-Bug: 19045 Message-Id: <200608101024.k7AAO2LR030504@qa3-104.qa.cn.tlan> Below is the list of changes that have just been committed into a local 5.0 repository of root. When root does a push these changes will be propagated to the main repository and, within 24 hours after the push, to the public repository. For information on how to access the public repository see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html ChangeSet@stripped, 2006-08-10 18:23:52+08:00, root@stripped +2 -0 BUG#19045, No meaningfull error message when defining too many nodes improve error information when too many nodes configured ndb/src/mgmsrv/ConfigInfo.cpp@stripped, 2006-08-10 18:23:40+08:00, root@stripped +6 -5 directly show the reason of error info: too many nodes configurated. replace ctx.fname with its alias name, so that even normal user can understand it: DB->NDBD API->MYSQLD MGM->NDB_MGMD ndb/src/mgmsrv/MgmtSrvr.cpp@stripped, 2006-08-10 18:23:45+08:00, root@stripped +4 -1 if config_filename is not null, show it. # This is a BitKeeper patch. What follows are the unified diffs for the # set of deltas contained in the patch. The rest of the patch, the part # that BitKeeper cares about, is below these diffs. # User: root # Host: qa3-104.qa.cn.tlan # Root: /mnt/sda7/hejun/mysql/bug19045-5.0 --- 1.79/ndb/src/mgmsrv/ConfigInfo.cpp 2006-08-10 18:24:05 +08:00 +++ 1.80/ndb/src/mgmsrv/ConfigInfo.cpp 2006-08-10 18:24:05 +08:00 @@ -3325,10 +3325,11 @@ Uint64 newVal = (Uint64)((Int64)oldVal * mul + add); if(!ctx.m_info->verify(ctx.m_currentInfo, newName, newVal)){ - ctx.reportError("Unable to handle deprication, new value not within bounds" - "%s %s - [%s] starting at line: %d", + ctx.reportError("too many nodes configured, only up to %d nodes supported. " + "%s %s - [%s] configuration at line: %d", + MAX_NODES, oldName, newName, - ctx.fname, ctx.m_sectionLineno); + ConfigInfo::nameToAlias(ctx.fname), ctx.m_sectionLineno); return false; } @@ -3495,11 +3496,11 @@ 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 (for the 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 (for the ndb_mgmd) should be defined in config file"); return false; } if (!ctx.m_userProperties.get("API", &api_nodes)) { --- 1.102/ndb/src/mgmsrv/MgmtSrvr.cpp 2006-08-10 18:24:05 +08:00 +++ 1.103/ndb/src/mgmsrv/MgmtSrvr.cpp 2006-08-10 18:24:05 +08:00 @@ -450,7 +450,10 @@ // 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); } }