Quantcast
Channel: MySQL Forums - NDB clusters
Viewing all articles
Browse latest Browse all 1560

Error restoring hot backup with ndb_restore. HELP (2 replies)

$
0
0
Hi all,

I'm having problems restoring a backup with ndb_restore command.

config.ini
-----------------------------------
# Mgm Nodes

[MGM DEFAULT]
PortNumber: 1186
DataDir: /usr/local/mysql/data

# First (PRIMARY) mgm node

[NDB_MGMD]
Id: 1
HostName: 192.168.0.140

# Second (BACKUP) mgm node

[NDB_MGMD]
Id: 2
HostName: 192.168.0.141

# Storage nodes
# ---------------------------------------------------------

[NDBD DEFAULT]

NoOfReplicas: 2
DataDir: /usr/local/mysql/data
FileSystemPath: /usr/local/mysql/data

[NDBD]
Id: 3
HostName: 192.168.0.145

[NDBD]
Id: 4
HostName: 192.168.0.146

[NDBD]
Id: 5
HostName: 192.168.0.147

[NDBD]
Id: 6
HostName: 192.168.0.148

# SQL Nodes
# ---------------------------------------------------------

[mysqld]
Id: 7
HostName: 192.168.0.142


[mysqld]
Id: 8
HostName: 192.168.0.143


[mysqld]
Id: 9
HostName: 192.168.0.144
# ----------------------------------------------------------
# ----------- END file -------------------------------------

my.cnf 's
# ----------- file -----------------------------------------
[mysqld]
ndbcluster

#connectstring: primary,secondary management nodes
ndb-connectstring=nodeid=X,192.168.0.140,192.168.0.141

[mysql_cluster]
ndb-connectstring=nodeid=X,192.168.0.140,192.168.0.141
# ----------------------------------------------------------
X is nodeid
# ----------- END file -------------------------------------

The backup is made as shown:

ndb_mgm> START BACKUP WAIT COMPLETED

To restore it, I put the cluster in single user mode.


ndb_mgm> enter single user mode 9
Single user mode entered
Access is granted for API node 9 only.
ndb_mgm> show
Cluster Configuration
---------------------
[ndbd(NDB)] 4 node(s)
id=3 @192.168.0.145 (mysql-5.1.47 ndb-7.1.8, single user mode, Nodegroup: 0, Master)
id=4 @192.168.0.146 (mysql-5.1.47 ndb-7.1.8, single user mode, Nodegroup: 0)
id=5 @192.168.0.147 (mysql-5.1.47 ndb-7.1.8, single user mode, Nodegroup: 1)
id=6 @192.168.0.148 (mysql-5.1.47 ndb-7.1.8, single user mode, Nodegroup: 1)

[ndb_mgmd(MGM)] 2 node(s)
id=1 @192.168.0.140 (mysql-5.1.47 ndb-7.1.8)
id=2 @192.168.0.141 (mysql-5.1.47 ndb-7.1.8)

[mysqld(API)] 3 node(s)
id=7 @192.168.0.142 (mysql-5.1.47 ndb-7.1.8)
id=8 @192.168.0.143 (mysql-5.1.47 ndb-7.1.8)
id=9 @192.168.0.144 (mysql-5.1.47 ndb-7.1.8)

And then in node "id=6 @192.168.0.148"


-bash-3.00# ndb_restore -m -n 6 -b 2 --backup_path=/usr/local/mysql/data/BACKUP/BACKUP-2

Nodeid = 6
Backup Id = 2
backup path = /usr/local/mysql/data/BACKUP/BACKUP-2
Opening file '/usr/local/mysql/data/BACKUP/BACKUP-2/BACKUP-2.6.ctl'
Backup version in files: ndb-6.3.11 ndb version: mysql-5.1.47 ndb-7.1.8
Stop GCP of Backup: 288
Configuration error: Error : Could not alloc node id at 192.168.0.140 port 1186: Id 6 configured as ndbd(NDB), connect attempted as mysqld(API).
Failed to initialize consumers

NDBT_ProgramExit: 1 - Failed

-bash-3.00#
I can't find many information about this error. Any idea about what's going wrong??

Thanks

Viewing all articles
Browse latest Browse all 1560

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>