MySQL Forums
Forum List  »  NDB clusters

Re: sql node and storage node concept, state of cluster.
Posted by: Jonathan Stephens
Date: May 10, 2005 10:54AM

Doesn't really matter which node you create the DB and tables on. What does matter is that the SQL node can't "see" the tables until FLUSH TABLES has been executed on each storage node. Once this is done, you can (and should) load the data itself in via the SQL node.

What the manual describes is the minimum requirement for clustered data storage and retrieval. The management node is actually required only when starting, stopping, backing up, and restoring the cluster. Additional SQL nodes are fine, but AFAIK you'll have to do failover between those in your application, e.g. (pseudocode):

if( mysql_connect('sqlnode1.localnet', $user, $pass) )
{
doStuffWithData();
}
elseif( mysql_connect('sqlnode2.localnet', $user, $pass) )
{
doStuffWithData();
}
else
die('We've got heaps of trouble, mate! Both SQL nodes are cactus!');

Of course, there are more elegant ways of implementing such logic, but you get the idea, I hope. ;)

Jon Stephens
MySQL Documentation Team @ Oracle

MySQL Dev Zone
MySQL Server Documentation
Oracle

Options: ReplyQuote




Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.