diff options
author | unknown <magnus@neptunus.(none)> | 2004-04-14 10:53:21 +0200 |
---|---|---|
committer | unknown <magnus@neptunus.(none)> | 2004-04-14 10:53:21 +0200 |
commit | 6386c55cee50bad6a9979d1fab28e03bb8612ca7 (patch) | |
tree | 3fbbacf704304b69228474b9f03549ccd585a017 /ndb/demos | |
parent | 0ba6cb48d84f1ff951d09871a96be6cdef3f2c3c (diff) | |
download | mariadb-git-6386c55cee50bad6a9979d1fab28e03bb8612ca7.tar.gz |
Initial revision of NDB Cluster files
BitKeeper/etc/logging_ok:
Logging to logging@openlogging.org accepted
Diffstat (limited to 'ndb/demos')
-rw-r--r-- | ndb/demos/1-node/1-api-3/Ndb.cfg | 2 | ||||
-rw-r--r-- | ndb/demos/1-node/1-db-2/Ndb.cfg | 2 | ||||
-rw-r--r-- | ndb/demos/1-node/1-mgm-1/Ndb.cfg | 2 | ||||
-rw-r--r-- | ndb/demos/1-node/1-mgm-1/template_config.ini | 70 | ||||
-rw-r--r-- | ndb/demos/2-node/2-api-4/Ndb.cfg | 2 | ||||
-rw-r--r-- | ndb/demos/2-node/2-api-5/Ndb.cfg | 2 | ||||
-rw-r--r-- | ndb/demos/2-node/2-api-6/Ndb.cfg | 2 | ||||
-rw-r--r-- | ndb/demos/2-node/2-api-7/Ndb.cfg | 2 | ||||
-rw-r--r-- | ndb/demos/2-node/2-db-2/Ndb.cfg | 2 | ||||
-rw-r--r-- | ndb/demos/2-node/2-db-3/Ndb.cfg | 2 | ||||
-rw-r--r-- | ndb/demos/2-node/2-mgm-1/Ndb.cfg | 2 | ||||
-rw-r--r-- | ndb/demos/2-node/2-mgm-1/template_config.ini | 157 | ||||
-rw-r--r-- | ndb/demos/config-templates/config_template-1-REP.ini | 87 | ||||
-rw-r--r-- | ndb/demos/config-templates/config_template-4.ini | 336 | ||||
-rw-r--r-- | ndb/demos/config-templates/config_template-install.ini | 64 | ||||
-rw-r--r-- | ndb/demos/run_demo1-PS-SS_common.sh | 50 | ||||
-rwxr-xr-x | ndb/demos/run_demo1-PS.sh | 30 | ||||
-rwxr-xr-x | ndb/demos/run_demo1-SS.sh | 30 | ||||
-rwxr-xr-x | ndb/demos/run_demo1.sh | 41 | ||||
-rwxr-xr-x | ndb/demos/run_demo2.sh | 54 |
20 files changed, 939 insertions, 0 deletions
diff --git a/ndb/demos/1-node/1-api-3/Ndb.cfg b/ndb/demos/1-node/1-api-3/Ndb.cfg new file mode 100644 index 00000000000..61309af029e --- /dev/null +++ b/ndb/demos/1-node/1-api-3/Ndb.cfg @@ -0,0 +1,2 @@ +OwnProcessId 3 +127.0.0.1 10000 diff --git a/ndb/demos/1-node/1-db-2/Ndb.cfg b/ndb/demos/1-node/1-db-2/Ndb.cfg new file mode 100644 index 00000000000..9315950b67a --- /dev/null +++ b/ndb/demos/1-node/1-db-2/Ndb.cfg @@ -0,0 +1,2 @@ +OwnProcessId 2 +127.0.0.1 10000 diff --git a/ndb/demos/1-node/1-mgm-1/Ndb.cfg b/ndb/demos/1-node/1-mgm-1/Ndb.cfg new file mode 100644 index 00000000000..61d4c0ecc17 --- /dev/null +++ b/ndb/demos/1-node/1-mgm-1/Ndb.cfg @@ -0,0 +1,2 @@ +OwnProcessId 1 +127.0.0.1 10000 diff --git a/ndb/demos/1-node/1-mgm-1/template_config.ini b/ndb/demos/1-node/1-mgm-1/template_config.ini new file mode 100644 index 00000000000..76bb7867e3c --- /dev/null +++ b/ndb/demos/1-node/1-mgm-1/template_config.ini @@ -0,0 +1,70 @@ +############################################################################### +# +# Initial system configuration file for MySQL Cluster v3.1.0 (Demo 1) +# +############################################################################### + +[DB DEFAULT] +NoOfReplicas: 1 +#LockPagesInMainMemory: Y +StopOnError: Y +#MaxNoOfConcurrentOperations: 1024 +#MaxNoOfConcurrentTransactions: 1024 +NoOfIndexPages: 1500 +NoOfDataPages: 5000 +#TimeBetweenLocalCheckpoints: 20 +#TimeBetweenGlobalCheckpoints: 1500 +#NoOfFragmentLogFiles: 8 +BackupMemory: 4M +BackupDataBufferSize: 2M +BackupLogBufferSize: 2M +BackupWriteSize: 32k + +[COMPUTER] +Id: 1 +ByteOrder: Little +HostName: localhost + +[MGM] +Id: 1 +ExecuteOnComputer: 1 +PortNumber: 10000 +PortNumberStats: 10001 + + +[DB] +Id: 2 +ExecuteOnComputer: 1 +FileSystemPath: WRITE_PATH_TO_FILESYSTEM_2_HERE + +[API] +Id: 3 +ExecuteOnComputer: 1 + +# Designated MySQL Server API node id +[API] +Id: 11 +ExecuteOnComputer: 1 + +[TCP DEFAULT] +SendSignalId: N +Compression: N +Checksum: N +SendBufferSize: 2000 +MaxReceiveSize: 2000 + +[TCP] +NodeId1: 1 +NodeId2: 2 +PortNumber: 10002 + +[TCP] +NodeId1: 2 +NodeId2: 3 +PortNumber: 10003 + +# Designated MySQL Server API node connection +[TCP] +NodeId1: 2 +NodeId2: 11 +PortNumber: 10011 diff --git a/ndb/demos/2-node/2-api-4/Ndb.cfg b/ndb/demos/2-node/2-api-4/Ndb.cfg new file mode 100644 index 00000000000..1713a9b5893 --- /dev/null +++ b/ndb/demos/2-node/2-api-4/Ndb.cfg @@ -0,0 +1,2 @@ +OwnProcessId 4 +127.0.0.1 10000 diff --git a/ndb/demos/2-node/2-api-5/Ndb.cfg b/ndb/demos/2-node/2-api-5/Ndb.cfg new file mode 100644 index 00000000000..faa2882eeea --- /dev/null +++ b/ndb/demos/2-node/2-api-5/Ndb.cfg @@ -0,0 +1,2 @@ +OwnProcessId 5 +127.0.0.1 10000 diff --git a/ndb/demos/2-node/2-api-6/Ndb.cfg b/ndb/demos/2-node/2-api-6/Ndb.cfg new file mode 100644 index 00000000000..bc2c4809453 --- /dev/null +++ b/ndb/demos/2-node/2-api-6/Ndb.cfg @@ -0,0 +1,2 @@ +OwnProcessId 6 +127.0.0.1 10000 diff --git a/ndb/demos/2-node/2-api-7/Ndb.cfg b/ndb/demos/2-node/2-api-7/Ndb.cfg new file mode 100644 index 00000000000..4107fdb6c5e --- /dev/null +++ b/ndb/demos/2-node/2-api-7/Ndb.cfg @@ -0,0 +1,2 @@ +OwnProcessId 7 +127.0.0.1 10000 diff --git a/ndb/demos/2-node/2-db-2/Ndb.cfg b/ndb/demos/2-node/2-db-2/Ndb.cfg new file mode 100644 index 00000000000..9315950b67a --- /dev/null +++ b/ndb/demos/2-node/2-db-2/Ndb.cfg @@ -0,0 +1,2 @@ +OwnProcessId 2 +127.0.0.1 10000 diff --git a/ndb/demos/2-node/2-db-3/Ndb.cfg b/ndb/demos/2-node/2-db-3/Ndb.cfg new file mode 100644 index 00000000000..61309af029e --- /dev/null +++ b/ndb/demos/2-node/2-db-3/Ndb.cfg @@ -0,0 +1,2 @@ +OwnProcessId 3 +127.0.0.1 10000 diff --git a/ndb/demos/2-node/2-mgm-1/Ndb.cfg b/ndb/demos/2-node/2-mgm-1/Ndb.cfg new file mode 100644 index 00000000000..61d4c0ecc17 --- /dev/null +++ b/ndb/demos/2-node/2-mgm-1/Ndb.cfg @@ -0,0 +1,2 @@ +OwnProcessId 1 +127.0.0.1 10000 diff --git a/ndb/demos/2-node/2-mgm-1/template_config.ini b/ndb/demos/2-node/2-mgm-1/template_config.ini new file mode 100644 index 00000000000..3edb909609a --- /dev/null +++ b/ndb/demos/2-node/2-mgm-1/template_config.ini @@ -0,0 +1,157 @@ +############################################################################### +# +# Initial system configuration file for MySQL Cluster v3.1.0 (Demo 2) +# +############################################################################### + +[COMPUTER] +Id: 1 +ByteOrder: Little +HostName: localhost + +[COMPUTER] +Id: 2 +ByteOrder: Little +HostName: localhost + +[MGM] +Id: 1 +ExecuteOnComputer: 1 +PortNumber: 10000 +PortNumberStats: 10001 +ArbitrationRank: 1 + +[DB DEFAULT] +NoOfReplicas: 2 +#LockPagesInMainMemory: N +StopOnError: N +#MaxNoOfConcurrentOperations: 1024 +#MaxNoOfConcurrentTransactions: 1024 +NoOfIndexPages: 200 +NoOfDataPages: 600 +#TimeBetweenLocalCheckpoints: 20 +#TimeBetweenGlobalCheckpoints: 1500 +#NoOfFragmentLogFiles: 8 +BackupMemory: 4M +BackupDataBufferSize: 2M +BackupLogBufferSize: 2M +BackupWriteSize: 32k + +[DB] +Id: 2 +ExecuteOnComputer: 1 +FileSystemPath: WRITE_PATH_TO_FILESYSTEM_2_HERE + +[DB] +Id: 3 +ExecuteOnComputer: 2 +FileSystemPath: WRITE_PATH_TO_FILESYSTEM_3_HERE + +[API DEFAULT] +ArbitrationRank: 1 + +[API] +Id: 4 +ExecuteOnComputer: 1 + +[API] +Id: 5 +ExecuteOnComputer: 1 + +[API] +Id: 6 +ExecuteOnComputer: 2 + +[API] +Id: 7 +ExecuteOnComputer: 2 + +# Designated MySQL Server API node id +[API] +Id: 11 +ExecuteOnComputer: 1 + +# Designated MySQL Server API node id +[API] +Id: 12 +ExecuteOnComputer: 2 + + +[TCP] +NodeId1: 1 +NodeId2: 2 +PortNumber: 10002 + +[TCP] +NodeId1: 1 +NodeId2: 3 +PortNumber: 10003 + +[TCP] +NodeId1: 2 +NodeId2: 3 +PortNumber: 10004 + +[TCP] +NodeId1: 2 +NodeId2: 4 +PortNumber: 10005 + +[TCP] +NodeId1: 2 +NodeId2: 5 +PortNumber: 10006 + +[TCP] +NodeId1: 2 +NodeId2: 6 +PortNumber: 10007 + +[TCP] +NodeId1: 2 +NodeId2: 7 +PortNumber: 10008 + +[TCP] +NodeId1: 3 +NodeId2: 4 +PortNumber: 10009 + +[TCP] +NodeId1: 3 +NodeId2: 5 +PortNumber: 10010 + +[TCP] +NodeId1: 3 +NodeId2: 6 +PortNumber: 10011 + +[TCP] +NodeId1: 3 +NodeId2: 7 +PortNumber: 10012 + +# Designated MySQL Server API node connection +[TCP] +NodeId1: 2 +NodeId2: 11 +PortNumber: 10013 + +# Designated MySQL Server API node connection +[TCP] +NodeId1: 3 +NodeId2: 11 +PortNumber: 10014 + +# Designated MySQL Server API node connection +[TCP] +NodeId1: 2 +NodeId2: 12 +PortNumber: 10015 + +# Designated MySQL Server API node connection +[TCP] +NodeId1: 3 +NodeId2: 12 +PortNumber: 10016 diff --git a/ndb/demos/config-templates/config_template-1-REP.ini b/ndb/demos/config-templates/config_template-1-REP.ini new file mode 100644 index 00000000000..71be3f2f53f --- /dev/null +++ b/ndb/demos/config-templates/config_template-1-REP.ini @@ -0,0 +1,87 @@ +############################################################################### +# +# Initial system configuration file for MySQL Cluster v3.1.0 (Demo 1) +# +############################################################################### + +[DB DEFAULT] +NoOfReplicas: 1 +StopOnError: Y +NoOfIndexPages: 1500 +NoOfDataPages: 5000 +BackupMemory: 4M +BackupDataBufferSize: 2M +BackupLogBufferSize: 2M +BackupWriteSize: 32k + +[COMPUTER] +Id: 1 +ByteOrder: Little +HostName: CHOOSE_HOSTNAME + +[EXTERNAL SYSTEM] +Name: External + +[MGM] +Id: 1 +ExecuteOnComputer: 1 +PortNumber: CHOOSE_PORT_BASE00 +PortNumberStats: CHOOSE_PORT_BASE01 + + +[DB] +Id: 2 +ExecuteOnComputer: 1 +FileSystemPath: WRITE_PATH_TO_FILESYSTEM_2_HERE + +[API] +Id: 3 +ExecuteOnComputer: 1 + +[REP] +Id: CHOOSE_REP_ID +ExecuteOnComputer: 1 + +[EXTERNAL REP] +Id: CHOOSE_EXTREP_ID +System: External + +# Designated MySQL Server API node id +[API] +Id: 11 +ExecuteOnComputer: 1 + +[TCP DEFAULT] +SendSignalId: N +Compression: N +Checksum: N +SendBufferSize: 2000 +MaxReceiveSize: 2000 + +[TCP] +NodeId1: 1 +NodeId2: 2 +PortNumber: CHOOSE_PORT_BASE02 + +[TCP] +NodeId1: 2 +NodeId2: 3 +PortNumber: CHOOSE_PORT_BASE03 + +[TCP] +NodeId1: 2 +NodeId2: CHOOSE_REP_ID +PortNumber: CHOOSE_PORT_BASE04 + +[TCP] +Hostname1: CHOOSE_HOSTNAME +Hostname2: CHOOSE_EXTHOSTNAME +NodeId1: CHOOSE_REP_ID +NodeId2: External.CHOOSE_EXTREP_ID +PortNumber: 10099 + +# Designated MySQL Server API node connection +[TCP] +NodeId1: 2 +NodeId2: 11 +PortNumber: CHOOSE_PORT_BASE11 diff --git a/ndb/demos/config-templates/config_template-4.ini b/ndb/demos/config-templates/config_template-4.ini new file mode 100644 index 00000000000..e47c9037344 --- /dev/null +++ b/ndb/demos/config-templates/config_template-4.ini @@ -0,0 +1,336 @@ +############################################################################### +# +# 4-node system configuration file for MySQL Cluster +# +############################################################################### + +[DB DEFAULT] +NoOfReplicas: 1 +StopOnError: N +NoOfIndexPages: 1500 +NoOfDataPages: 5000 +BackupMemory: 4M +BackupDataBufferSize: 2M +BackupLogBufferSize: 2M +BackupWriteSize: 32k + +[COMPUTER] +Id: 1 +ByteOrder: Little +HostName: CHOOSE_HOSTNAME_1 + +[COMPUTER] +Id: 2 +ByteOrder: Little +HostName: CHOOSE_HOSTNAME_2 + +[COMPUTER] +Id: 3 +ByteOrder: Little +HostName: CHOOSE_HOSTNAME_3 + +[COMPUTER] +Id: 4 +ByteOrder: Little +HostName: CHOOSE_HOSTNAME_4 + +[MGM] +Id: 1 +ExecuteOnComputer: 1 +PortNumber: CHOOSE_PORT_BASE00 +PortNumberStats: CHOOSE_PORT_BASE01 + +[DB] +Id: 2 +ExecuteOnComputer: 1 +FileSystemPath: WRITE_PATH_TO_FILESYSTEM_1_HERE + +[DB] +Id: 3 +ExecuteOnComputer: 2 +FileSystemPath: WRITE_PATH_TO_FILESYSTEM_2_HERE + +[DB] +Id: 4 +ExecuteOnComputer: 3 +FileSystemPath: WRITE_PATH_TO_FILESYSTEM_3_HERE + +[DB] +Id: 5 +ExecuteOnComputer: 4 +FileSystemPath: WRITE_PATH_TO_FILESYSTEM_4_HERE + +[API] +Id: 6 +ExecuteOnComputer: 1 + +[API] +Id: 7 +ExecuteOnComputer: 2 + +[API] +Id: 8 +ExecuteOnComputer: 3 + +[API] +Id: 9 +ExecuteOnComputer: 4 + +# Designated MySQL Server API node id +[API] +Id: 11 +ExecuteOnComputer: 1 + +# Designated MySQL Server API node id +[API] +Id: 12 +ExecuteOnComputer: 2 + +# Designated MySQL Server API node id +[API] +Id: 13 +ExecuteOnComputer: 3 + +# Designated MySQL Server API node id +[API] +Id: 14 +ExecuteOnComputer: 4 + +[TCP DEFAULT] +SendSignalId: N +Compression: N +Checksum: N +SendBufferSize: 2000 +MaxReceiveSize: 2000 + +# Management server +[TCP] +NodeId1: 1 +NodeId2: 2 +PortNumber: CHOOSE_PORT_BASE02 + +[TCP] +NodeId1: 1 +NodeId2: 3 +PortNumber: CHOOSE_PORT_BASE03 + +[TCP] +NodeId1: 1 +NodeId2: 4 +PortNumber: CHOOSE_PORT_BASE04 + +[TCP] +NodeId1: 1 +NodeId2: 5 +PortNumber: CHOOSE_PORT_BASE05 + +# Database cluster +[TCP] +NodeId1: 2 +NodeId2: 3 +PortNumber: CHOOSE_PORT_BASE06 + +[TCP] +NodeId1: 2 +NodeId2: 4 +PortNumber: CHOOSE_PORT_BASE07 + +[TCP] +NodeId1: 2 +NodeId2: 5 +PortNumber: CHOOSE_PORT_BASE08 + +[TCP] +NodeId1: 3 +NodeId2: 4 +PortNumber: CHOOSE_PORT_BASE09 + +[TCP] +NodeId1: 3 +NodeId2: 5 +PortNumber: CHOOSE_PORT_BASE10 + +[TCP] +NodeId1: 4 +NodeId2: 5 +PortNumber: CHOOSE_PORT_BASE11 + +# API node 6 +[TCP] +NodeId1: 6 +NodeId2: 2 +PortNumber: CHOOSE_PORT_BASE12 + +[TCP] +NodeId1: 6 +NodeId2: 3 +PortNumber: CHOOSE_PORT_BASE13 + +[TCP] +NodeId1: 6 +NodeId2: 4 +PortNumber: CHOOSE_PORT_BASE14 + +[TCP] +NodeId1: 6 +NodeId2: 5 +PortNumber: CHOOSE_PORT_BASE15 + +# API node 7 +[TCP] +NodeId1: 7 +NodeId2: 2 +PortNumber: CHOOSE_PORT_BASE16 + +[TCP] +NodeId1: 7 +NodeId2: 3 +PortNumber: CHOOSE_PORT_BASE17 + +[TCP] +NodeId1: 7 +NodeId2: 4 +PortNumber: CHOOSE_PORT_BASE18 + +[TCP] +NodeId1: 7 +NodeId2: 5 +PortNumber: CHOOSE_PORT_BASE19 + +# API node 8 +[TCP] +NodeId1: 8 +NodeId2: 2 +PortNumber: CHOOSE_PORT_BASE20 + +[TCP] +NodeId1: 8 +NodeId2: 3 +PortNumber: CHOOSE_PORT_BASE21 + +[TCP] +NodeId1: 8 +NodeId2: 4 +PortNumber: CHOOSE_PORT_BASE22 + +[TCP] +NodeId1: 8 +NodeId2: 5 +PortNumber: CHOOSE_PORT_BASE23 + +# API node 9 +[TCP] +NodeId1: 9 +NodeId2: 2 +PortNumber: CHOOSE_PORT_BASE24 + +[TCP] +NodeId1: 9 +NodeId2: 3 +PortNumber: CHOOSE_PORT_BASE25 + +[TCP] +NodeId1: 9 +NodeId2: 4 +PortNumber: CHOOSE_PORT_BASE26 + +[TCP] +NodeId1: 9 +NodeId2: 5 +PortNumber: CHOOSE_PORT_BASE27 + +# Designated MySQL Server API node connection +[TCP] +NodeId1: 2 +NodeId2: 11 +PortNumber: CHOOSE_PORT_BASE28 + +# Designated MySQL Server API node connection +[TCP] +NodeId1: 3 +NodeId2: 11 +PortNumber: CHOOSE_PORT_BASE29 + +# Designated MySQL Server API node connection +[TCP] +NodeId1: 4 +NodeId2: 11 +PortNumber: CHOOSE_PORT_BASE30 + +# Designated MySQL Server API node connection +[TCP] +NodeId1: 5 +NodeId2: 11 +PortNumber: CHOOSE_PORT_BASE31 + +# Designated MySQL Server API node connection +[TCP] +NodeId1: 2 +NodeId2: 12 +PortNumber: CHOOSE_PORT_BASE32 + +# Designated MySQL Server API node connection +[TCP] +NodeId1: 3 +NodeId2: 12 +PortNumber: CHOOSE_PORT_BASE33 + +# Designated MySQL Server API node connection +[TCP] +NodeId1: 4 +NodeId2: 12 +PortNumber: CHOOSE_PORT_BASE34 + +# Designated MySQL Server API node connection +[TCP] +NodeId1: 5 +NodeId2: 12 +PortNumber: CHOOSE_PORT_BASE35 + +# Designated MySQL Server API node connection +[TCP] +NodeId1: 2 +NodeId2: 13 +PortNumber: CHOOSE_PORT_BASE36 + +# Designated MySQL Server API node connection +[TCP] +NodeId1: 3 +NodeId2: 13 +PortNumber: CHOOSE_PORT_BASE37 + +# Designated MySQL Server API node connection +[TCP] +NodeId1: 4 +NodeId2: 13 +PortNumber: CHOOSE_PORT_BASE38 + +# Designated MySQL Server API node connection +[TCP] +NodeId1: 5 +NodeId2: 13 +PortNumber: CHOOSE_PORT_BASE39 + +# Designated MySQL Server API node connection +[TCP] +NodeId1: 2 +NodeId2: 14 +PortNumber: CHOOSE_PORT_BASE40 + +# Designated MySQL Server API node connection +[TCP] +NodeId1: 3 +NodeId2: 14 +PortNumber: CHOOSE_PORT_BASE41 + +# Designated MySQL Server API node connection +[TCP] +NodeId1: 4 +NodeId2: 14 +PortNumber: CHOOSE_PORT_BASE42 + +# Designated MySQL Server API node connection +[TCP] +NodeId1: 5 +NodeId2: 14 +PortNumber: CHOOSE_PORT_BASE43 diff --git a/ndb/demos/config-templates/config_template-install.ini b/ndb/demos/config-templates/config_template-install.ini new file mode 100644 index 00000000000..e31906ba609 --- /dev/null +++ b/ndb/demos/config-templates/config_template-install.ini @@ -0,0 +1,64 @@ +############################################################################### +# +# Initial system configuration file for MySQL Cluster v3.1.0 (Demo 1) +# +############################################################################### + +[DB DEFAULT] +NoOfReplicas: 1 +StopOnError: N +NoOfIndexPages: 1500 +NoOfDataPages: 5000 +BackupMemory: 4M +BackupDataBufferSize: 2M +BackupLogBufferSize: 2M +BackupWriteSize: 32k + +[COMPUTER] +Id: 1 +ByteOrder: Little +HostName: localhost + +[MGM] +Id: 1 +ExecuteOnComputer: 1 +PortNumber: CHOOSE_PORT_BASE00 +PortNumberStats: CHOOSE_PORT_BASE01 + + +[DB] +Id: 2 +ExecuteOnComputer: 1 +FileSystemPath: WRITE_PATH_TO_FILESYSTEM_2_HERE + +[API] +Id: 3 +ExecuteOnComputer: 1 + +# Designated MySQL Server API node id +[API] +Id: 11 +ExecuteOnComputer: 1 + +[TCP DEFAULT] +SendSignalId: N +Compression: N +Checksum: N +SendBufferSize: 2000 +MaxReceiveSize: 2000 + +[TCP] +NodeId1: 1 +NodeId2: 2 +PortNumber: CHOOSE_PORT_BASE02 + +[TCP] +NodeId1: 2 +NodeId2: 3 +PortNumber: CHOOSE_PORT_BASE03 + +# Designated MySQL Server API node connection +[TCP] +NodeId1: 2 +NodeId2: 11 +PortNumber: CHOOSE_PORT_BASE11 diff --git a/ndb/demos/run_demo1-PS-SS_common.sh b/ndb/demos/run_demo1-PS-SS_common.sh new file mode 100644 index 00000000000..625e9655087 --- /dev/null +++ b/ndb/demos/run_demo1-PS-SS_common.sh @@ -0,0 +1,50 @@ +echo $NDB_HOST $NDB_EXTHOST + +NDB_PORT=$NDB_PORT_BASE"00" +NDB_CONNECTSTRING_BASE="host=$NDB_HOST:$NDB_PORT;nodeid=" + +# Edit file system path + +cd $NDB_DEMO +sed -e s,"WRITE_PATH_TO_FILESYSTEM_2_HERE",$NDB_DEMO/filesystem,g \ + -e s,"CHOOSE_HOSTNAME",$NDB_HOST,g\ + -e s,"CHOOSE_EXTHOSTNAME",$NDB_EXTHOST,g\ + -e s,"CHOOSE_PORT_BASE",$NDB_PORT_BASE,g\ + -e s,"CHOOSE_REP_ID",$NDB_REP_ID,g\ + -e s,"CHOOSE_EXTREP_ID",$NDB_EXTREP_ID,g\ + < ../config-templates/config_template-1-REP.ini > config.ini + +# Start management server as deamon + +NDB_ID="1" +NDB_CONNECTSTRING=$NDB_CONNECTSTRING_BASE$NDB_ID +export NDB_CONNECTSTRING +if mgmtsrvr -d -c config.ini ; then :; else + echo "Unable to start mgmtsrvr" + exit 1 +fi + +# Start database node + +NDB_ID="2" +NDB_CONNECTSTRING=$NDB_CONNECTSTRING_BASE$NDB_ID +export NDB_CONNECTSTRING +xterm -T "$NDB_DEMO_NAME DB Node $NDB_ID" -geometry 80x10 -xrm *.hold:true -e ndb -i & + +# Start xterm for application programs + +NDB_ID="3" +NDB_CONNECTSTRING=$NDB_CONNECTSTRING_BASE$NDB_ID +export NDB_CONNECTSTRING +xterm -T "$NDB_DEMO_NAME API Node $NDB_ID" -geometry 80x10 & + +# Start xterm for rep node + +NDB_ID=$NDB_REP_ID +NDB_CONNECTSTRING=$NDB_CONNECTSTRING_BASE$NDB_ID +export NDB_CONNECTSTRING +xterm -T "$NDB_DEMO_NAME REP Node $NDB_ID" -geometry 80x10 -xrm *.hold:true -e ndb_rep & + +# Start management client + +xterm -T "$NDB_DEMO_NAME Mgmt Client" -geometry 80x10 -xrm *.hold:true -e mgmtclient $NDB_HOST $NDB_PORT & diff --git a/ndb/demos/run_demo1-PS.sh b/ndb/demos/run_demo1-PS.sh new file mode 100755 index 00000000000..82cfdd5e65b --- /dev/null +++ b/ndb/demos/run_demo1-PS.sh @@ -0,0 +1,30 @@ +#!/bin/sh +if [ -z "$MYSQLCLUSTER_TOP" ]; then + echo "MYSQLCLUSTER_TOP not set" + exit 1 +fi +if [ -d "$MYSQLCLUSTER_TOP/ndb" ]; then :; else + echo "$MYSQLCLUSTER_TOP/ndb directory does not exist" + exit 1 +fi +NDB_CONNECTSTRING= +NDB_HOME= +NDB_DEMO=$MYSQLCLUSTER_TOP/ndb/demos/1-node-PS + +NDB_PORT_BASE="102" +NDB_REP_ID="5" +NDB_EXTREP_ID="4" + +NDB_DEMO_NAME="Demo 1-PS MySQL Cluster" +NDB_HOST1=$1 +NDB_HOST2=$2 +if [ -z "$NDB_HOST1" ]; then + NDB_HOST1=localhost +fi +if [ -z "$NDB_HOST2" ]; then + NDB_HOST2=localhost +fi +NDB_HOST=$NDB_HOST1 +NDB_EXTHOST=$NDB_HOST2 + +source $MYSQLCLUSTER_TOP/ndb/demos/run_demo1-PS-SS_common.sh diff --git a/ndb/demos/run_demo1-SS.sh b/ndb/demos/run_demo1-SS.sh new file mode 100755 index 00000000000..5ede57c44c4 --- /dev/null +++ b/ndb/demos/run_demo1-SS.sh @@ -0,0 +1,30 @@ +#!/bin/sh +if [ -z "$MYSQLCLUSTER_TOP" ]; then + echo "MYSQLCLUSTER_TOP not set" + exit 1 +fi +if [ -d "$MYSQLCLUSTER_TOP/ndb" ]; then :; else + echo "$MYSQLCLUSTER_TOP/ndb directory does not exist" + exit 1 +fi +NDB_CONNECTSTRING= +NDB_HOME= +NDB_DEMO=$MYSQLCLUSTER_TOP/ndb/demos/1-node-SS + +NDB_PORT_BASE="101" +NDB_REP_ID="4" +NDB_EXTREP_ID="5" + +NDB_DEMO_NAME="Demo 1-SS MySQL Cluster" +NDB_HOST1=$1 +NDB_HOST2=$2 +if [ -z "$NDB_HOST1" ]; then + NDB_HOST1=localhost +fi +if [ -z "$NDB_HOST2" ]; then + NDB_HOST2=localhost +fi +NDB_HOST=$NDB_HOST2 +NDB_EXTHOST=$NDB_HOST1 + +source $MYSQLCLUSTER_TOP/ndb/demos/run_demo1-PS-SS_common.sh diff --git a/ndb/demos/run_demo1.sh b/ndb/demos/run_demo1.sh new file mode 100755 index 00000000000..df6e3fc799d --- /dev/null +++ b/ndb/demos/run_demo1.sh @@ -0,0 +1,41 @@ +#!/bin/sh +if [ -z "$MYSQLCLUSTER_TOP" ]; then + echo "MYSQLCLUSTER_TOP not set" + exit 1 +fi +if [ -d "$MYSQLCLUSTER_TOP/ndb" ]; then :; else + echo "$MYSQLCLUSTER_TOP/ndb directory does not exist" + exit 1 +fi +NDB_CONNECTSTRING= +NDB_HOME= +ndb_demo=$MYSQLCLUSTER_TOP/ndb/demos + +# Edit file system path + +cd $ndb_demo/1-node/1-mgm-1 +sed -e s,"WRITE_PATH_TO_FILESYSTEM_2_HERE",$ndb_demo/1-node/1-db-2/filesystem,g \ + < template_config.ini > config.ini + +# Start management server as deamon + +cd $ndb_demo/1-node/1-mgm-1 +if mgmtsrvr -d -c config.ini ; then :; else + echo "Unable to start mgmtsrvr" + exit 1 +fi + +# Start database node + +cd $ndb_demo/1-node/1-db-2 +xterm -T "Demo 1 NDB Cluster DB Node 2" -geometry 80x10 -xrm *.hold:true -e ndb -i & + +# Start xterm for application programs + +cd $ndb_demo/1-node/1-api-3 +xterm -T "Demo 1 NDB Cluster API Node 3" -geometry 80x10 & + +# Start management client + +cd $ndb_demo +xterm -T "Demo 1 NDB Management Client" -geometry 80x10 -xrm *.hold:true -e mgmtclient localhost 10000 & diff --git a/ndb/demos/run_demo2.sh b/ndb/demos/run_demo2.sh new file mode 100755 index 00000000000..9bae7517d5f --- /dev/null +++ b/ndb/demos/run_demo2.sh @@ -0,0 +1,54 @@ +#!/bin/sh +if [ -z "$MYSQLCLUSTER_TOP" ]; then + echo "MYSQLCLUSTER_TOP not set" + exit 1 +fi +if [ -d "$MYSQLCLUSTER_TOP/ndb" ]; then :; else + echo "$MYSQLCLUSTER_TOP/ndb directory does not exist" + exit 1 +fi +NDB_CONNECTSTRING= +NDB_HOME= +ndb_demo=$MYSQLCLUSTER_TOP/ndb/demos + +# Edit file system path + +cd $ndb_demo/2-node/2-mgm-1 +sed -e s,"WRITE_PATH_TO_FILESYSTEM_2_HERE",$ndb_demo/2-node/2-db-2/filesystem,g \ + -e s,"WRITE_PATH_TO_FILESYSTEM_3_HERE",$ndb_demo/2-node/2-db-3/filesystem,g \ + < template_config.ini > config.ini + +# Start management server as deamon + +cd $ndb_demo/2-node/2-mgm-1 +if mgmtsrvr -d -c config.ini ; then :; else + echo "Unable to start mgmtsrvr" + exit 1 +fi + +#xterm -T "Demo 2 NDB Management Server" -geometry 80x10 -xrm *.hold:true -e mgmtsrvr -c config.ini & + +# Start database node + +cd $ndb_demo/2-node/2-db-2 +xterm -T "Demo 2 NDB Cluster DB Node 2" -geometry 80x10 -xrm *.hold:true -e ndb -i & + +# Start database node + +cd $ndb_demo/2-node/2-db-3 +xterm -T "Demo 2 NDB Cluster DB Node 3" -geometry 80x10 -xrm *.hold:true -e ndb -i & + +# Start xterm for application programs + +cd $ndb_demo/2-node/2-api-4 +xterm -T "Demo 2 NDB Cluster API Node 4" -geometry 80x10 & + +# Start xterm for application programs + +cd $ndb_demo/2-node/2-api-5 +xterm -T "Demo 2 NDB Cluster API Node 5" -geometry 80x10 & + +# Start management client + +cd $ndb_demo +xterm -T "Demo 2 NDB Management Client" -geometry 80x10 -xrm *.hold:true -e mgmtclient localhost 10000 & |