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
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
0fa99ec2
Commit
0fa99ec2
authored
Aug 24, 2004
by
unknown
Browse files
Options
Browse Files
Download
Plain Diff
Merge bk-internal.mysql.com:/home/bk/mysql-4.1
into brandersnatch.localdomain:/home/dlenev/src/mysql-4.1-fix
parents
805dcdad
c6e77b16
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
48 additions
and
17 deletions
+48
-17
mysql-test/ndb/ndbcluster.sh
mysql-test/ndb/ndbcluster.sh
+1
-0
mysql-test/r/subselect.result
mysql-test/r/subselect.result
+1
-0
ndb/src/mgmclient/CommandInterpreter.cpp
ndb/src/mgmclient/CommandInterpreter.cpp
+23
-16
ndb/src/mgmsrv/Services.cpp
ndb/src/mgmsrv/Services.cpp
+23
-1
No files found.
mysql-test/ndb/ndbcluster.sh
View file @
0fa99ec2
...
@@ -194,6 +194,7 @@ stop_default_ndbcluster() {
...
@@ -194,6 +194,7 @@ stop_default_ndbcluster() {
exec_mgmtclient
=
"
$exec_mgmtclient
--try-reconnect=1"
exec_mgmtclient
=
"
$exec_mgmtclient
--try-reconnect=1"
echo
"all stop"
|
$exec_mgmtclient
2>&1 |
cat
>
/dev/null
echo
"all stop"
|
$exec_mgmtclient
2>&1 |
cat
>
/dev/null
echo
"3 stop"
|
$exec_mgmtclient
2>&1 |
cat
>
/dev/null
if
[
-f
"
$fs_ndb
/
$pidfile
"
]
;
then
if
[
-f
"
$fs_ndb
/
$pidfile
"
]
;
then
kill
-9
`
cat
"
$fs_ndb
/
$pidfile
"
`
2> /dev/null
kill
-9
`
cat
"
$fs_ndb
/
$pidfile
"
`
2> /dev/null
...
...
mysql-test/r/subselect.result
View file @
0fa99ec2
...
@@ -1916,6 +1916,7 @@ INSERT INTO t1(`IZAVORGANG_ID`,`KUERZEL`,`IZAANALYSEART_ID`,`IZAPMKZ_ID`)VALUES(
...
@@ -1916,6 +1916,7 @@ INSERT INTO t1(`IZAVORGANG_ID`,`KUERZEL`,`IZAANALYSEART_ID`,`IZAPMKZ_ID`)VALUES(
SELECT `IZAVORGANG_ID` FROM t1 WHERE `KUERZEL` IN(SELECT MIN(`KUERZEL`)`Feld1` FROM t1 WHERE `KUERZEL` LIKE'601%'And`IZAANALYSEART_ID`='D0000000001');
SELECT `IZAVORGANG_ID` FROM t1 WHERE `KUERZEL` IN(SELECT MIN(`KUERZEL`)`Feld1` FROM t1 WHERE `KUERZEL` LIKE'601%'And`IZAANALYSEART_ID`='D0000000001');
IZAVORGANG_ID
IZAVORGANG_ID
D0000000001
D0000000001
drop table t1;
CREATE TABLE `t1` ( `aid` int(11) NOT NULL default '0', `bid` int(11) NOT NULL default '0', PRIMARY KEY (`aid`,`bid`));
CREATE TABLE `t1` ( `aid` int(11) NOT NULL default '0', `bid` int(11) NOT NULL default '0', PRIMARY KEY (`aid`,`bid`));
CREATE TABLE `t2` ( `aid` int(11) NOT NULL default '0', `bid` int(11) NOT NULL default '0', PRIMARY KEY (`aid`,`bid`));
CREATE TABLE `t2` ( `aid` int(11) NOT NULL default '0', `bid` int(11) NOT NULL default '0', PRIMARY KEY (`aid`,`bid`));
insert into t1 values (1,1),(1,2),(2,1),(2,2);
insert into t1 values (1,1),(1,2),(2,1),(2,2);
...
...
ndb/src/mgmclient/CommandInterpreter.cpp
View file @
0fa99ec2
...
@@ -649,9 +649,10 @@ CommandInterpreter::executeShow(char* parameters)
...
@@ -649,9 +649,10 @@ CommandInterpreter::executeShow(char* parameters)
}
}
int
int
ndb_nodes
=
0
,
master_id
=
0
,
api_nodes
=
0
,
ndb_nodes
=
0
,
mgm_nodes
=
0
;
api_nodes
=
0
,
mgm_nodes
=
0
;
for
(
i
=
0
;
i
<
state
->
no_of_nodes
;
i
++
)
{
for
(
i
=
0
;
i
<
state
->
no_of_nodes
;
i
++
)
{
switch
(
state
->
node_states
[
i
].
node_type
)
{
switch
(
state
->
node_states
[
i
].
node_type
)
{
...
@@ -659,6 +660,8 @@ CommandInterpreter::executeShow(char* parameters)
...
@@ -659,6 +660,8 @@ CommandInterpreter::executeShow(char* parameters)
api_nodes
++
;
api_nodes
++
;
break
;
break
;
case
NDB_MGM_NODE_TYPE_NDB
:
case
NDB_MGM_NODE_TYPE_NDB
:
if
(
state
->
node_states
[
i
].
dynamic_id
>
master_id
)
master_id
=
state
->
node_states
[
i
].
dynamic_id
;
ndb_nodes
++
;
ndb_nodes
++
;
break
;
break
;
case
NDB_MGM_NODE_TYPE_MGM
:
case
NDB_MGM_NODE_TYPE_MGM
:
...
@@ -681,8 +684,11 @@ CommandInterpreter::executeShow(char* parameters)
...
@@ -681,8 +684,11 @@ CommandInterpreter::executeShow(char* parameters)
ndbout
<<
" (Version: "
ndbout
<<
" (Version: "
<<
getMajor
(
state
->
node_states
[
i
].
version
)
<<
"."
<<
getMajor
(
state
->
node_states
[
i
].
version
)
<<
"."
<<
getMinor
(
state
->
node_states
[
i
].
version
)
<<
"."
<<
getMinor
(
state
->
node_states
[
i
].
version
)
<<
"."
<<
getBuild
(
state
->
node_states
[
i
].
version
)
<<
")"
<<
endl
;
<<
getBuild
(
state
->
node_states
[
i
].
version
)
<<
","
<<
" Nodegroup: "
<<
state
->
node_states
[
i
].
node_group
;
if
(
state
->
node_states
[
i
].
dynamic_id
==
master_id
)
ndbout
<<
", Master"
;
ndbout
<<
")"
<<
endl
;
}
else
}
else
{
{
ndbout
<<
" (not connected) "
<<
endl
;
ndbout
<<
" (not connected) "
<<
endl
;
...
@@ -692,13 +698,13 @@ CommandInterpreter::executeShow(char* parameters)
...
@@ -692,13 +698,13 @@ CommandInterpreter::executeShow(char* parameters)
}
}
ndbout
<<
endl
;
ndbout
<<
endl
;
ndbout
<<
api
_nodes
ndbout
<<
mgm
_nodes
<<
"
API
Node(s)"
<<
"
MGM
Node(s)"
<<
endl
;
<<
endl
;
for
(
i
=
0
;
i
<
state
->
no_of_nodes
;
i
++
)
{
for
(
i
=
0
;
i
<
state
->
no_of_nodes
;
i
++
)
{
if
(
state
->
node_states
[
i
].
node_type
==
NDB_MGM_NODE_TYPE_
API
)
{
if
(
state
->
node_states
[
i
].
node_type
==
NDB_MGM_NODE_TYPE_
MGM
)
{
ndbout
<<
"
API
node:
\t
"
<<
state
->
node_states
[
i
].
node_id
;
ndbout
<<
"
MGM
node:
\t
"
<<
state
->
node_states
[
i
].
node_id
;
if
(
state
->
node_states
[
i
].
version
!=
0
)
{
if
(
state
->
node_states
[
i
].
version
!=
0
)
{
ndbout
<<
" (Version: "
ndbout
<<
" (Version: "
<<
getMajor
(
state
->
node_states
[
i
].
version
)
<<
"."
<<
getMajor
(
state
->
node_states
[
i
].
version
)
<<
"."
...
@@ -707,19 +713,19 @@ CommandInterpreter::executeShow(char* parameters)
...
@@ -707,19 +713,19 @@ CommandInterpreter::executeShow(char* parameters)
}
else
}
else
{
{
ndbout
<<
" (no
t connected
) "
<<
endl
;
ndbout
<<
" (no
version information available
) "
<<
endl
;
}
}
}
}
}
}
ndbout
<<
endl
;
ndbout
<<
endl
;
ndbout
<<
mgm
_nodes
ndbout
<<
api
_nodes
<<
"
MGM
Node(s)"
<<
"
API
Node(s)"
<<
endl
;
<<
endl
;
for
(
i
=
0
;
i
<
state
->
no_of_nodes
;
i
++
)
{
for
(
i
=
0
;
i
<
state
->
no_of_nodes
;
i
++
)
{
if
(
state
->
node_states
[
i
].
node_type
==
NDB_MGM_NODE_TYPE_
MGM
)
{
if
(
state
->
node_states
[
i
].
node_type
==
NDB_MGM_NODE_TYPE_
API
)
{
ndbout
<<
"
MGM
node:
\t
"
<<
state
->
node_states
[
i
].
node_id
;
ndbout
<<
"
API
node:
\t
"
<<
state
->
node_states
[
i
].
node_id
;
if
(
state
->
node_states
[
i
].
version
!=
0
)
{
if
(
state
->
node_states
[
i
].
version
!=
0
)
{
ndbout
<<
" (Version: "
ndbout
<<
" (Version: "
<<
getMajor
(
state
->
node_states
[
i
].
version
)
<<
"."
<<
getMajor
(
state
->
node_states
[
i
].
version
)
<<
"."
...
@@ -728,11 +734,12 @@ CommandInterpreter::executeShow(char* parameters)
...
@@ -728,11 +734,12 @@ CommandInterpreter::executeShow(char* parameters)
}
else
}
else
{
{
ndbout
<<
" (no
version information available
) "
<<
endl
;
ndbout
<<
" (no
t connected
) "
<<
endl
;
}
}
}
}
}
}
ndbout
<<
endl
;
ndbout
<<
endl
;
// ndbout << helpTextShow;
// ndbout << helpTextShow;
return
;
return
;
}
else
if
(
strcmp
(
parameters
,
"PROPERTIES"
)
==
0
||
}
else
if
(
strcmp
(
parameters
,
"PROPERTIES"
)
==
0
||
...
...
ndb/src/mgmsrv/Services.cpp
View file @
0fa99ec2
...
@@ -31,6 +31,8 @@
...
@@ -31,6 +31,8 @@
#include "Services.hpp"
#include "Services.hpp"
extern
bool
g_StopServer
;
static
const
unsigned
int
MAX_READ_TIMEOUT
=
1000
;
static
const
unsigned
int
MAX_READ_TIMEOUT
=
1000
;
static
const
unsigned
int
MAX_WRITE_TIMEOUT
=
100
;
static
const
unsigned
int
MAX_WRITE_TIMEOUT
=
100
;
...
@@ -1012,10 +1014,27 @@ MgmApiSession::stop(Parser<MgmApiSession>::Context &,
...
@@ -1012,10 +1014,27 @@ MgmApiSession::stop(Parser<MgmApiSession>::Context &,
nodes
.
push_back
(
atoi
(
p
));
nodes
.
push_back
(
atoi
(
p
));
}
}
int
stop_self
=
0
;
for
(
size_t
i
=
0
;
i
<
nodes
.
size
();
i
++
)
{
if
(
nodes
[
i
]
==
m_mgmsrv
.
getOwnNodeId
())
{
stop_self
=
1
;
if
(
i
!=
nodes
.
size
()
-
1
)
{
m_output
->
println
(
"stop reply"
);
m_output
->
println
(
"result: server must be stopped last"
);
m_output
->
println
(
""
);
return
;
}
}
}
int
stopped
=
0
,
result
=
0
;
int
stopped
=
0
,
result
=
0
;
for
(
size_t
i
=
0
;
i
<
nodes
.
size
();
i
++
)
for
(
size_t
i
=
0
;
i
<
nodes
.
size
();
i
++
)
if
((
result
=
m_mgmsrv
.
stopNode
(
nodes
[
i
],
abort
!=
0
))
==
0
)
if
(
nodes
[
i
]
!=
m_mgmsrv
.
getOwnNodeId
())
{
if
((
result
=
m_mgmsrv
.
stopNode
(
nodes
[
i
],
abort
!=
0
))
==
0
)
stopped
++
;
}
else
stopped
++
;
stopped
++
;
m_output
->
println
(
"stop reply"
);
m_output
->
println
(
"stop reply"
);
...
@@ -1025,6 +1044,9 @@ MgmApiSession::stop(Parser<MgmApiSession>::Context &,
...
@@ -1025,6 +1044,9 @@ MgmApiSession::stop(Parser<MgmApiSession>::Context &,
m_output
->
println
(
"result: Ok"
);
m_output
->
println
(
"result: Ok"
);
m_output
->
println
(
"stopped: %d"
,
stopped
);
m_output
->
println
(
"stopped: %d"
,
stopped
);
m_output
->
println
(
""
);
m_output
->
println
(
""
);
if
(
stop_self
)
g_StopServer
=
true
;
}
}
...
...
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