In MySQL NDB Cluster databases, when the data memory is full, “The table is full” error occurs in all operations in the tables. To resolve this error, increase the value of the DataMemory and IndexMemory parameters, turn off services on all nodes from the NDB management server, and load the new configuration with “ndb_mgmd –reload” and start the related services.
Error
You will see errors in the MySQL error log file as follows.
1 |
2019-09-26 08:20:14 3395 [ERROR] /usr/sbin/mysqld: The table 'my_table' is full |
Query Memory Usage in MySQL Nodes
You can view the memory usage in nodes with the following command.
1 2 3 4 5 6 |
[root@mysqlmgmt mysql-cluster]# ndb_mgm -e "ALL REPORT MEMORYUSAGE" Connected to Management Server at: localhost:1186 Node 2: Data usage is 11%(125788 32K pages of total 1048576) Node 2: Index usage is 8%(43601 8K pages of total 524320) Node 3: Data usage is 11%(125789 32K pages of total 1048576) Node 3: Index usage is 8%(43601 8K pages of total 524320) |
Chage DataMemory and IndexMemory Parameters in MySQL
The Mysql Cluster configuration file is “/var/lib/mysql-cluster/config.ini”. It is necessary to change the following parameters in this file.
DataMemory = 8192M # Memory allocate for data storage
IndexMemory = 1024M # Memory allocate for index storage
Then shut down all nodes, start the Management Server service and start the ndb and mysql services.
Shut Down MySQL Nodes:
1 |
[root@mysqlmgmt mysql-cluster]# ndb_mgm -e shutdown |
Start Management Server Service
1 |
[root@mysqlmgmt mysql-cluster]# ndb_mgmd --reload -f /var/lib/mysql-cluster/config.ini |