Below is the list of changes that have just been committed into a local
5.1 repository of jonas. When jonas 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, 2007-03-07 12:12:43+01:00, jonas@stripped +3 -0
ndb -
Add new config parameter to allow node to bind INADDR_ANY instead of name in config.ini
"TcpBind_INADDR_ANY" type bool
storage/ndb/include/mgmapi/mgmapi_config_parameters.h@stripped, 2007-03-07 12:12:40+01:00, jonas@stripped +1 -0
Add new config parameter to allow node to bind INADDR_ANY instead of naem in config.ini
storage/ndb/src/common/mgmcommon/IPCConfig.cpp@stripped, 2007-03-07 12:12:40+01:00, jonas@stripped +7 -2
Add new config parameter to allow node to bind INADDR_ANY instead of naem in config.ini
storage/ndb/src/mgmsrv/ConfigInfo.cpp@stripped, 2007-03-07 12:12:40+01:00, jonas@stripped +30 -1
Add new config parameter to allow node to bind INADDR_ANY instead of naem in config.ini
# 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: jonas
# Host: perch.ndb.mysql.com
# Root: /home/jonas/src/51-work
--- 1.31/storage/ndb/include/mgmapi/mgmapi_config_parameters.h 2007-03-07 12:12:48 +01:00
+++ 1.32/storage/ndb/include/mgmapi/mgmapi_config_parameters.h 2007-03-07 12:12:48 +01:00
@@ -152,6 +152,7 @@
#define CFG_TCP_SEND_BUFFER_SIZE 454
#define CFG_TCP_RECEIVE_BUFFER_SIZE 455
#define CFG_TCP_PROXY 456
+#define CFG_TCP_BIND_INADDR_ANY 460
#define CFG_SHM_SEND_SIGNAL_ID 500
#define CFG_SHM_CHECKSUM 501
--- 1.96/storage/ndb/src/mgmsrv/ConfigInfo.cpp 2007-03-07 12:12:48 +01:00
+++ 1.97/storage/ndb/src/mgmsrv/ConfigInfo.cpp 2007-03-07 12:12:48 +01:00
@@ -342,6 +342,18 @@
"0",
STR_VALUE(MAX_INT_RNIL) },
+ {
+ KEY_INTERNAL,
+ "TcpBind_INADDR_ANY",
+ DB_TOKEN,
+ "Bind IP_ADDR_ANY so that connections can be made from anywhere (for autogenerated connections)",
+ ConfigInfo::CI_USED,
+ false,
+ ConfigInfo::CI_BOOL,
+ "false",
+ "false",
+ "true"},
+
/***************************************************************************
* DB
***************************************************************************/
@@ -1761,7 +1773,17 @@
ConfigInfo::CI_STRING,
UNDEFINED,
0, 0 },
-
+
+ {
+ CFG_TCP_BIND_INADDR_ANY,
+ "TcpBind_INADDR_ANY",
+ "TCP",
+ "Bind InAddrAny instead of hostname for server part of connection",
+ ConfigInfo::CI_USED,
+ false,
+ ConfigInfo::CI_BOOL,
+ "false",
+ "false", "true" },
/****************************************************************************
* SHM
@@ -3017,6 +3039,13 @@
DBUG_RETURN(false);
}
+ Uint32 bindAnyAddr = 0;
+ node1->get("TcpBind_INADDR_ANY", &bindAnyAddr);
+ if (bindAnyAddr)
+ {
+ ctx.m_currentSection->put("TcpBind_INADDR_ANY", 1, true);
+ }
+
Uint32 port= 0;
if(strcmp(type1, MGM_TOKEN)==0)
node1->get("PortNumber",&port);
--- 1.28/storage/ndb/src/common/mgmcommon/IPCConfig.cpp 2007-03-07 12:12:48 +01:00
+++ 1.29/storage/ndb/src/common/mgmcommon/IPCConfig.cpp 2007-03-07 12:12:48 +01:00
@@ -249,10 +249,15 @@
else
conf.isMgmConnection= false;
+ Uint32 bindInAddrAny = 0;
+ iter.get(CFG_TCP_BIND_INADDR_ANY, &bindInAddrAny);
+
if (nodeId == nodeIdServer && !conf.isMgmConnection) {
- tr.add_transporter_interface(remoteNodeId, localHostName, server_port);
+ tr.add_transporter_interface(remoteNodeId,
+ !bindInAddrAny ? localHostName : "",
+ server_port);
}
-
+
DBUG_PRINT("info", ("Transporter between this node %d and node %d using port %d, signalId %d, checksum %d",
nodeId, remoteNodeId, server_port, sendSignalId, checksum));
/*
| Thread |
|---|
| • bk commit into 5.1 tree (jonas:1.2426) | jonas | 7 Mar |