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
26a30a73
Commit
26a30a73
authored
Aug 18, 2004
by
joreland@mysql.com
Browse files
Options
Browse Files
Download
Plain Diff
Merge mysql.com:/home/jonas/src/mysql-4.1
into mysql.com:/home/jonas/src/mysql-4.1-ndb
parents
51b696eb
94189cb4
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
33 additions
and
35 deletions
+33
-35
ndb/src/ndbapi/TransporterFacade.cpp
ndb/src/ndbapi/TransporterFacade.cpp
+7
-4
ndb/test/ndbapi/testBackup.cpp
ndb/test/ndbapi/testBackup.cpp
+6
-1
ndb/test/run-test/daily-devel-tests.txt
ndb/test/run-test/daily-devel-tests.txt
+6
-6
ndb/test/run-test/main.cpp
ndb/test/run-test/main.cpp
+5
-3
ndb/test/src/NdbBackup.cpp
ndb/test/src/NdbBackup.cpp
+9
-21
No files found.
ndb/src/ndbapi/TransporterFacade.cpp
View file @
26a30a73
...
...
@@ -349,12 +349,15 @@ TransporterFacade::start_instance(const char * connectString){
if
(
s_config_retriever
->
do_connect
()
==
-
1
)
break
;
const
Uint32
nodeId
=
s_config_retriever
->
allocNodeId
();
Uint32
nodeId
=
s_config_retriever
->
allocNodeId
();
for
(
Uint32
i
=
0
;
nodeId
==
0
&&
i
<
5
;
i
++
){
NdbSleep_SecSleep
(
3
);
nodeId
=
s_config_retriever
->
allocNodeId
();
}
if
(
nodeId
==
0
)
break
;
ndb_mgm_configuration
*
props
=
s_config_retriever
->
getConfig
();
if
(
props
==
0
)
break
;
...
...
ndb/test/ndbapi/testBackup.cpp
View file @
26a30a73
...
...
@@ -205,6 +205,11 @@ int runClearTable(NDBT_Context* ctx, NDBT_Step* step){
return
NDBT_OK
;
}
int
runDropTable
(
NDBT_Context
*
ctx
,
NDBT_Step
*
step
){
GETNDB
(
step
)
->
getDictionary
()
->
dropTable
(
ctx
->
getTab
()
->
getName
());
return
NDBT_OK
;
}
#include "bank/Bank.hpp"
int
runCreateBank
(
NDBT_Context
*
ctx
,
NDBT_Step
*
step
){
...
...
@@ -408,7 +413,7 @@ TESTCASE("BackupOne",
INITIALIZER
(
runRestoreOne
);
VERIFIER
(
runVerifyOne
);
FINALIZER
(
runClearTable
);
FINALIZER
(
runDropTable
);
}
TESTCASE
(
"BackupBank"
,
"Test that backup and restore works during transaction load
\n
"
...
...
ndb/test/run-test/daily-devel-tests.txt
View file @
26a30a73
...
...
@@ -3,7 +3,7 @@
#
max-time: 1500
cmd: testIndex
args: -n CreateAll
args: -n CreateAll
T1 T6 T13
#-m 7200 1: testIndex -n InsertDeleteGentle T7
max-time: 3600
...
...
@@ -20,12 +20,12 @@ args: -n CreateLoadDrop T1 T10
#
max-time: 600
cmd: testBackup
args: -n BackupOne
max-time: 600
cmd: testBackup
args: -n BackupBank T6
args: -n BackupOne T1 T6 T3 I3
#max-time: 600
#cmd: testBackup
#args: -n BackupBank T6
#
#
# MGMAPI AND MGSRV
#
...
...
ndb/test/run-test/main.cpp
View file @
26a30a73
...
...
@@ -938,9 +938,11 @@ gather_result(atrt_config& config, int * result){
BaseString
tmp
=
g_gather_progname
;
for
(
size_t
i
=
0
;
i
<
config
.
m_processes
.
size
();
i
++
){
atrt_process
&
proc
=
config
.
m_processes
[
i
];
tmp
.
appfmt
(
" %s:%s"
,
proc
.
m_hostname
.
c_str
(),
proc
.
m_proc
.
m_cwd
.
c_str
());
if
(
proc
.
m_proc
.
m_path
!=
""
){
tmp
.
appfmt
(
" %s:%s"
,
proc
.
m_hostname
.
c_str
(),
proc
.
m_proc
.
m_cwd
.
c_str
());
}
}
const
int
r1
=
system
(
tmp
.
c_str
());
...
...
ndb/test/src/NdbBackup.cpp
View file @
26a30a73
...
...
@@ -70,11 +70,11 @@ NdbBackup::getFileSystemPathForNode(int _node_id){
* Fetch configuration from management server
*/
ConfigRetriever
cr
(
0
,
NODE_TYPE_API
);
ndb_mgm_configuration
*
p
;
ndb_mgm_configuration
*
p
=
0
;
BaseString
tmp
;
tmp
.
assfmt
(
"%s:%d"
,
host
.
c_str
(),
port
);
NdbMgmHandle
handle
=
ndb_mgm_create_handle
();
if
(
handle
==
0
||
ndb_mgm_connect
(
handle
,
tmp
.
c_str
())
!=
0
&&
if
(
handle
==
0
||
ndb_mgm_connect
(
handle
,
tmp
.
c_str
())
!=
0
||
(
p
=
ndb_mgm_get_configuration
(
handle
,
0
))
==
0
){
const
char
*
s
=
0
;
...
...
@@ -97,7 +97,8 @@ NdbBackup::getFileSystemPathForNode(int _node_id){
ndbout
<<
"Invalid configuration fetched, DB missing"
<<
endl
;
return
NULL
;
}
unsigned
int
type
=
123456
;
unsigned
int
type
=
NODE_TYPE_DB
+
1
;
if
(
iter
.
get
(
CFG_TYPE_OF_SECTION
,
&
type
)
||
type
!=
NODE_TYPE_DB
){
ndbout
<<
"type = "
<<
type
<<
endl
;
ndbout
<<
"Invalid configuration fetched, I'm wrong type of node"
<<
endl
;
...
...
@@ -148,31 +149,18 @@ NdbBackup::execRestore(bool _restore_data,
ndbout
<<
"res: "
<<
res
<<
endl
;
#if 0
snprintf(buf, 255, "ndb_restore -c \"nodeid=%d;host=%s\" -n %d -b %d %s %s %s/BACKUP/BACKUP-%d",
ownNodeId,
addr,
_node_id,
_backup_id,
_restore_data?"-r":"",
_restore_meta?"-m":"",
path,
_backup_id);
snprintf
(
buf
,
255
,
"%sndb_restore -c
\"
host=%s
\"
-n %d -b %d %s %s ."
,
#if 1
""
,
#else
"valgrind --leak-check=yes -v "
#endif
snprintf
(
buf
,
255
,
"valgrind --leak-check=yes -v ndb_restore -c
\"
nodeid=%d;host=%s
\"
-n %d -b %d %s %s ."
,
ownNodeId
,
addr
.
c_str
(),
_node_id
,
_backup_id
,
_restore_data
?
"-r"
:
""
,
_restore_meta
?
"-m"
:
""
);
// path,
// _backup_id);
ndbout
<<
"buf: "
<<
buf
<<
endl
;
res
=
system
(
buf
);
...
...
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