0

I have a huge issue trying to solve it for a few hours. I installed, configured and ran the mysql-cluster but when I want to create a table I get the following issue:

create table simples (id int not null primary key) engine=ndb; 

ERROR 157 (HY000): Could not connect to storage engine

I changed my my.cnf file like this :

[mysqld]
ndbcluster
ndb-connectstring=host:port
datadir=/home/user/my_cluster/mysqld_data
basedir=/home/user/mysqlc
port=5018

I tried again to create tables but I have still the error.

 [my_cluster]# /home/user/mysqlc/bin/mysql -h 127.0.0.1 -P

5018 -u root Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 10 Server version: 5.6.15-ndb-7.3.4-cluster-gpl MySQL Cluster Community Server (GPL)

Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners.

Also I executed this command to check all engines status but everything is fine :

show engines;

+--------------------+---------+----------------------------------------------------------------+--------------+------+------------+

| Engine | Support | Comment | Transactions | XA | Savepoints | +--------------------+---------+----------------------------------------------------------------+--------------+------+------------+ | ndbcluster | YES | Clustered, fault-tolerant tables | YES | NO | NO | | CSV | YES | CSV storage engine | NO | NO | NO | | InnoDB | DEFAULT | Supports transactions, row-level locking, and foreign keys | YES | YES | YES | | ndbinfo | YES | MySQL Cluster system information storage engine | NO | NO | NO | | MRG_MYISAM | YES | Collection of identical MyISAM tables | NO | NO | NO | | MyISAM | YES | MyISAM storage engine | NO | NO | NO | | ARCHIVE | YES | Archive storage engine | NO | NO | NO | | BLACKHOLE | YES | /dev/null storage engine (anything you write to it disappears) | NO | NO | NO | | PERFORMANCE_SCHEMA | YES | Performance Schema | NO | NO | NO | | FEDERATED | NO | Federated MySQL storage engine | NULL | NULL | NULL | | MEMORY | YES | Hash based, stored in memory, useful for temporary tables | NO | NO | NO | +--------------------+---------+----------------------------------------------------------------+--------------+------+------------+ 11 rows in set (0.00 sec)

2 Answers2

0

What this means is simply as it says, one SQL node is not connected to the NDB storage engine. It can be that you have messed up the ndb-connectstring in the my.cnf of that SQL node.

It is often the case that someone has been doing ALTER TABLEs, and for some reason, the schema files have been corrupted or is of the wrong version on one or more SQL nodes. It would make sense to check the SQL nodes for potential problems there.

The other possibility is that it could be an issue with your firewall. I would recommend you check your firewall and /etc/hosts tables.

Steve
  • 329
  • 1
  • 9
0

If you have previously installed another mysql-server package, make sure you delete all your old config files and folders.

Hatem
  • 200
  • 1
  • 10