2012-04-14 36 views
0

這是我my.cnf設置MySQL集羣7.2.2忽略設置和表已滿錯誤

[mysqld] 
ndbcluster 
#engine_condition_pushdown=0 
optimizer_switch=engine_condition_pushdown=off 

# IP address of the cluster management node 
ndb-connectstring=127.0.0.1 

[mysql_cluster] 
# IP address of the cluster management node 
ndb-connectstring=127.0.0.1 


[ndbd default] 
NoOfReplicas= 2 
MaxNoOfConcurrentOperations= 10000 
DataMemory= 320M 
IndexMemory= 96M 
TimeBetweenWatchDogCheck= 30000 
DataDir= /usr/local/mysql-cluster-gpl-7.2.2-osx10.6-x86_64/mysql-cluster 
MaxNoOfOrderedIndexes= 512 



[MYSQLD DEFAULT] 

[NDB_MGMD DEFAULT] 

[TCP DEFAULT] 

# Section for the cluster management node 
[NDB_MGMD] 
# IP address of the management node (this system) 
id=1 
HostName=127.0.0.1 


# Section for the storage nodes 
[NDBD] 
# IP address of the first storage node 
id=2 
HostName=127.0.0.1 
DataDir= /usr/local/mysql-cluster-gpl-7.2.2-osx10.6-x86_64/mysql-cluster 


[NDBD] 
# IP address of the second storage node 
id=3 
HostName=127.0.0.1 
DataDir= /usr/local/mysql-cluster-gpl-7.2.2-osx10.6-x86_64/mysql-cluster2 

# one [MYSQLD] per storage node 
[MYSQLD] 
[MYSQLD] 

我組數據存儲器320M,當我運行腳本,以填補其表錯誤停止「表布拉布拉已滿」 。 我嘗試使用-f選項和配置文件的路徑運行ndb_mgmd。 我將此文件複製到名稱爲config.ini但沒有結果的mysql-cluster文件夾中。

我:

ndb_mgm> ALL REPORT MEMORYUSAGE 
Node 2: Data usage is 100%(2560 32K pages of total 2560) 
Node 2: Index usage is 74%(1741 8K pages of total 2336) 
Node 3: Data usage is 100%(2560 32K pages of total 2560) 
Node 3: Index usage is 74%(1741 8K pages of total 2336) 

2560 * 32K = 80M。 80M就像默認的mysql集羣設置。

+0

您是否使用--initial或--reload選項重新啓動ndb_mgmd以從配置文件重新獲取配置?如果沒有,配置文件中的更改將被忽略,配置將從config-dir中的二進制存儲中獲取。 – 2012-04-17 13:13:14

+0

如果讀取一個文件中的所有設置,則出錯。 mysqld start ok。但ndb_mgmd記錄有關忽略的設置文件的錯誤,因爲他無法解析mysqld的設置,並停止加載文件。 – 2012-04-18 06:05:46

回答

1

我解決了我的問題。我需要劃分在兩個配置文件一個MySQL服務器這個配置並把它在數據/ my.cnf中:

[mysqld] 
ndbcluster 
#engine_condition_pushdown=0 
optimizer_switch=engine_condition_pushdown=off 

# IP address of the cluster management node 
ndb-connectstring=127.0.0.1 

[mysql_cluster] 
# IP address of the cluster management node 
ndb-connectstring=127.0.0.1 

而第二個文件的文件夾/mysql_cluster/config.ini集羣捆綁:

[ndbd default] 
NoOfReplicas= 2 
MaxNoOfConcurrentOperations= 10000 
DataMemory= 320M 
IndexMemory= 96M 
TimeBetweenWatchDogCheck= 30000 
DataDir= /usr/local/mysql-cluster-gpl-7.2.2-osx10.6-x86_64/mysql-cluster 
MaxNoOfOrderedIndexes= 512 



[MYSQLD DEFAULT] 

[NDB_MGMD DEFAULT] 

[TCP DEFAULT] 

# Section for the cluster management node 
[NDB_MGMD] 
# IP address of the management node (this system) 
id=1 
HostName=127.0.0.1 


# Section for the storage nodes 
[NDBD] 
# IP address of the first storage node 
id=2 
HostName=127.0.0.1 
DataDir= /usr/local/mysql-cluster-gpl-7.2.2-osx10.6-x86_64/mysql-cluster 


[NDBD] 
# IP address of the second storage node 
id=3 
HostName=127.0.0.1 
DataDir= /usr/local/mysql-cluster-gpl-7.2.2-osx10.6-x86_64/mysql-cluster2 

# one [MYSQLD] per storage node 
[MYSQLD] 
[MYSQLD]