Description.  This function can be used to dump debugging information to the cluster log. The NDB Cluster management client DUMP command is a wrapper for this function.


ndb_mgm_dump_state(), like the DUMP command, can cause a running NDB Cluster to malfunction or even to fail completely if it is used improperly. Be sure to consult the relevant documentation before using this function. For more information on the DUMP command, and for a listing of current DUMP codes and their effects, see NDB Cluster Management Client DUMP Commands.


int ndb_mgm_dump_state
      NdbMgmHandle handle,
      int nodeId,
      const int* arguments,
      int numberOfArguments,
      struct ndb_mgm_reply* reply

Parameters.  This function takes the following pararemeters:

Return value.  0 on success; otherwise, an error code.

Example.  The following example has the same result as running 2 DUMP 1000 in the management client:

//  [...]
#include <mgmapi_debug.h>
//  [...]
struct ndb_mgm_reply reply;
int args[1];
int stat, arg_count, node_id;

args[0] = 1000;
arg_count = 1;
node_id = 2;

stat = ndb_mgm_dump_state(h, node_id, args, arg_count, &reply);