Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
mariadb
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
mariadb
Commits
bfe01b48
Commit
bfe01b48
authored
Aug 14, 2006
by
Justin.He/justin.he@qa3-104.qa.cn.tlan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
BUG#19045, No meaningfull error message when defining too many nodes
parent
216474fa
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
3 deletions
+13
-3
ndb/src/mgmsrv/ConfigInfo.cpp
ndb/src/mgmsrv/ConfigInfo.cpp
+9
-2
ndb/src/mgmsrv/MgmtSrvr.cpp
ndb/src/mgmsrv/MgmtSrvr.cpp
+4
-1
No files found.
ndb/src/mgmsrv/ConfigInfo.cpp
View file @
bfe01b48
...
...
@@ -2604,6 +2604,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
);
...
...
@@ -3495,11 +3502,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
))
{
...
...
ndb/src/mgmsrv/MgmtSrvr.cpp
View file @
bfe01b48
...
...
@@ -450,7 +450,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
);
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment