Skip to content

3. Deployment

Eneko Gonzalez edited this page Jun 3, 2024 · 2 revisions

3.1 Post-Build Installation

3.1.1 Install Commands

From the build directory, execute

make install

to install executables and dependencies into the default install directory (~/chronolog).

3.2 Customizing Installation Path

The installation copies and renames default_conf.json.in to conf/default_conf.json in the installation directory by default. You can pass -DCMAKE_INSTALL_PREFIX=/new/installation/directory to CMake to change it.

3.3 Local Deployment

We prepare a script at deploy\local_single_user_deploy.sh to help deploying ChronoLog locally to enable quick hands-on and development. jq is needed to run the script.

Usage:
-d, --deploy: Deploy all components processes.
-r, --reset: Reset all components and remove all generated files.
-k, --kill: Kill all components processes.
-s, --stop: Stop all components processes.
-n, --num-keepers NUM: Set the number of ChronoKeeper processes.
-g, --num-graphers NUM: Set the number of ChronoGrapher processes.
-w, --work-dir DIR: Set the working directory.
-h, --help: Display help and exit.

3.4 Distributed Deployment

ChronoLog is designed to work in a distributed environment. We prepare a script at deploy\single_user_deploy.sh to help deploying it in a distributed environment. mpssh and jq are needed to run the script. Passwordless SSH needs to be configured for the script to work. By default, the script reads hosts files, hosts_visor, hosts_keeper, hosts_grapher, and hosts_client to be specific, under ~/chronolog/conf directory for the hosts to run the ChronoLog server daemons.

If the cluster uses Slurm for job scheduling, you can deploy ChronoLog in your active job using the following command:

./deploy/single_user_deploy.sh -d -n NUM_RECORDING_GROUP -j JOB_ID

The script will fetch the node list from Slurm, assign the first node to run the ChronoVisor, all the nodes to run ChronoKeepers, and the last NUM_RECORDING_GROUP nodes to run ChronoGraphers. The client_lib_multi_storytellers use case will be launched at last to test if the deployment is successful.

Usage:
-d|--deploy Start ChronoLog deployment (default: false)
-s|--stop Stop ChronoLog deployment (default: false)
-k|--kill Terminate ChronoLog deployment (default: false)
-r|--reset Reset/cleanup ChronoLog deployment (default: false)
-w|--work_dir WORK_DIR (default: ~/chronolog)
-u|--output_dir OUTPUT_DIR (default: work_dir/output)
-v|--visor VISOR_BIN (default: work_dir/bin/chronovisor_server)
-g|--grapher GRAPHER_BIN (default: work_dir/bin/chrono_grapher)
-p|--keeper KEEPER_BIN (default: work_dir/bin/chrono_keeper)
-c|--client CLIENT_BIN (default: work_dir/bin/client_lib_multi_storytellers)
-i|--visor_hosts VISOR_HOSTS (default: work_dir/conf/hosts_visor)
-a|--grapher_hosts GRAPHER_HOSTS (default: work_dir/conf/hosts_grapher)
-o|--keeper_hosts KEEPER_HOSTS (default: work_dir/conf/hosts_keeper)
-t|--client_hosts CLIENT_HOSTS (default: work_dir/conf/hosts_client)
-f|--conf_file CONF_FILE (default: work_dir/conf/default_conf.json)
-j|--job_id JOB_ID (default: "", overwrites hosts files if set)
-n|--num_recording_group NUM_RECORDING_GROUP (default: #hosts in GRAPHER_HOSTS if exists, 1 otherwise, overwrites hosts files if set)
-e|--verbose Enable verbose output (default: false)
-h|--help Print this page