GREENSTONE MONGODB EXTENSION ============================ This extension supports two deliberately separate operating modes: * STANDALONE-SERVER — one local mongod process; * CLUSTER-SERVER — mongos, a config server and one or more shards. All developer-run scripts are held under the directory for their mode. They must nevertheless be invoked from this extension's top-level directory. For example: ./STANDALONE-SERVER/RUN-MONGODB-START.sh or: ./CLUSTER-SERVER/RUN-MONGODB-CLUSTER-START.sh INSTALLING MONGODB AND MONGOSH ------------------------------ The binary versions are selected in _mongodb_os_dist_ver.bash. Place the matching archives under binary-tars/ and run: ./INSTALL.sh The legacy Debian 8 MongoDB archive is downloaded automatically when that build is selected and the archive is absent. CHOOSING ONE SERVER MODE ------------------------ SETUP.bash uses active installation files as mutually exclusive mode markers. Create exactly one of the following. For a standalone server: cp _mongodb_standalone_setup.bash.in _mongodb_standalone_setup.bash The supplied standalone defaults normally need no editing. For a cluster: cp _mongodb_cluster_setup.bash.in _mongodb_cluster_setup.bash Edit the copied cluster file to define the router, config-server and shard hostnames. The same edited file must be copied to every cluster host. Then initialise the selected environment: source ./SETUP.bash If neither active setup file exists, SETUP.bash prints the commands above. If both exist, setup stops because there can be only one active mode. STANDALONE OPERATION -------------------- ./STANDALONE-SERVER/RUN-MONGODB-START.sh ./STANDALONE-SERVER/RUN-MONGODB-STATUS.sh ./STANDALONE-SERVER/RUN-MONGOSH.sh ./STANDALONE-SERVER/RUN-MONGODB-STOP.sh See STANDALONE-SERVER/README.txt for details. CLUSTER CONFIGURATION AND OPERATION ----------------------------------- Begin on the router/orchestration host. After editing the active cluster file, check out the extension and run ./INSTALL.sh on every other host. Copy the active setup to those checkouts with: ./CLUSTER-SERVER/COPY-MONGODB-CLUSTER-SETUP.sh Validate and perform the first-time configuration: ./CLUSTER-SERVER/CHECK-MONGODB-CLUSTER-SETUP.sh ./CLUSTER-SERVER/CONFIGURE-MONGODB-CLUSTER.sh Normal operation from the router host: ./CLUSTER-SERVER/RUN-MONGODB-CLUSTER-START.sh ./CLUSTER-SERVER/RUN-MONGODB-CLUSTER-STATUS.sh ./CLUSTER-SERVER/RUN-MONGOSH.sh ./CLUSTER-SERVER/RUN-MONGODB-CLUSTER-STOP.sh See CLUSTER-SERVER/README.txt for role-specific commands. SVN AND GENERATED FILES ----------------------- The two active setup files are installation-specific and should not be committed. Suggested svn:ignore entries are listed in SVN-PROPERTIES.txt. Runtime data defaults to standalone-server/ or cluster-server/, away from the uppercase script directories.