From 93a21814c007309d22b3ad1ffceb9e51992d8305 Mon Sep 17 00:00:00 2001 From: "jonas@perch.ndb.mysql.com" <> Date: Wed, 26 Apr 2006 14:53:43 +0200 Subject: [PATCH 1/2] ndb - bug#17150 ndb_mgmd limited no of api nodes, by restricting no of mgmsessions (these are used for dynamic port allocation) --- ndb/include/util/SocketServer.hpp | 2 +- ndb/src/common/util/SocketServer.cpp | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ndb/include/util/SocketServer.hpp b/ndb/include/util/SocketServer.hpp index ee2dd31c41f..02a0a6b5d92 100644 --- a/ndb/include/util/SocketServer.hpp +++ b/ndb/include/util/SocketServer.hpp @@ -74,7 +74,7 @@ public: /** * Constructor / Destructor */ - SocketServer(int maxSessions = 32); + SocketServer(unsigned maxSessions = ~(unsigned)0); ~SocketServer(); /** diff --git a/ndb/src/common/util/SocketServer.cpp b/ndb/src/common/util/SocketServer.cpp index db5c03f925a..755764c7700 100644 --- a/ndb/src/common/util/SocketServer.cpp +++ b/ndb/src/common/util/SocketServer.cpp @@ -27,7 +27,7 @@ #define DEBUG(x) ndbout << x << endl; -SocketServer::SocketServer(int maxSessions) : +SocketServer::SocketServer(unsigned maxSessions) : m_sessions(10), m_services(5) { @@ -124,7 +124,7 @@ SocketServer::setup(SocketServer::Service * service, DBUG_RETURN(false); } - if (listen(sock, m_maxSessions) == -1){ + if (listen(sock, m_maxSessions > 32 ? 32 : m_maxSessions) == -1){ DBUG_PRINT("error",("listen() - %d - %s", errno, strerror(errno))); NDB_CLOSE_SOCKET(sock); From a8f407a7ef471a48e110c04acb4419d0ae5ca49a Mon Sep 17 00:00:00 2001 From: "jonas@perch.ndb.mysql.com" <> Date: Wed, 26 Apr 2006 14:54:20 +0200 Subject: [PATCH 2/2] Add ndb_config to rpm spec --- support-files/mysql.spec.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/support-files/mysql.spec.sh b/support-files/mysql.spec.sh index b161ec13073..08aba7e2231 100644 --- a/support-files/mysql.spec.sh +++ b/support-files/mysql.spec.sh @@ -630,6 +630,7 @@ fi %attr(755, root, root) %{_bindir}/ndb_desc %attr(755, root, root) %{_bindir}/ndb_show_tables %attr(755, root, root) %{_bindir}/ndb_test_platform +%attr(755, root, root) %{_bindir}/ndb_config %files ndb-extra %defattr(-,root,root,0755)