makeflow(1)
π makeflow(1) π β Cooperative Computing Tools
okay bestie, grab your iced coffee because this is the makeflow manual and it's literally the moment. π
πΈ NAME πΈ
makeflow β workflow engine for executing distributed workflows β¨
π¦ SYNOPSIS π¦
makeflow [options] <dagfile>
β¨ DESCRIPTION β¨
Makeflow is a workflow engine for distributed computing. It accepts a specification of a large amount of work to be performed, and runs it on remote machines in parallel where possible. In addition, Makeflow is fault-tolerant, so you can use it to coordinate very large tasks that may run for days or weeks in the face of failures. Makeflow is designed to be similar to Make, so if you can write a Makefile, then you can write a Makeflow. No cap.
You can run a Makeflow on your local machine to test it out. If you have a multi-core machine, then you can run multiple tasks simultaneously. If you have a Condor pool or a Sun Grid Engine batch system, then you can send your jobs there to run. If you don't already have a batch system, Makeflow comes with a system called Work Queue that will let you distribute the load across any collection of machines, large or small. Makeflow also supports execution in a Docker container, regardless of the batch system used. It's giving distributed slay. π«Ά
π OPTIONS π
When makeflow is ran without arguments, it will attempt to execute the workflow specified by the Makeflow dagfile using the local execution engine. local main character energy fr fr.
π Commands π
-c,----clean=<option>β Clean up: remove logfile and all targets. If option is one of[intermediates, outputs, cache], only indicated files are removed.-f,--summary-log=<file>β Write summary of workflow to file.-h,--helpβ Show this help screen.-v,--versionβ Show version string.-X,--chdir=<directory>β Chdir to enable executing the Makefile in other directory.--argv <file>β Use command line arguments from JSON file.
π Workflow Handling π
-a,--advertiseβ Advertise the manager information to a catalog server.-l,--makeflow-log=<logfile>β Use this file for the makeflow log. (default isX.makeflowlog)-L,--batch-log=<logfile>β Use this file for the batch system log. (default isX.<type>log)-m,--email=<email>β Email summary of workflow to address.-j,--max-local=<#>β Max number of local jobs to run at once. (default is # of cores)-J,--max-remote=<#>β Max number of remote jobs to run at once. (default is 1000 for-Twq, 100 otherwise)-R,--retryβ Automatically retry failed batch jobs up to 100 times.-r,--retry-count=<n>β Automatically retry failed batch jobs up to n times.--local-cores <#>β Max number of cores used for local execution.--local-memory <#>β Max amount of memory used for local execution.--local-disk <#>β Max amount of disk used for local execution.
OPTION_END
π Batch Options π
-B,--batch-options=<options>β Add these options to all batch submit files.--send-environmentβ Send all local environment variables in remote execution.--wait-for-files-upto <#>β Wait for output files to be created upto this many seconds (e.g., to deal with NFS semantics).-S,--submission-timeout=<timeout>β Time to retry failed batch job submission. (default is 3600s)-T,--batch-type=<type>β Batch system type:local,dryrun,condor,sge,pbs,torque,blue_waters,slurm,moab,cluster,wq,amazon,mesos. (default islocal)--safe-submit-modeβ Excludes resources at submission. (SLURM, TORQUE, and PBS)--ignore-memory-specβ Excludes memory at submission. (SLURM)--batch-mem-type <type>β Specify memory resource type. (SGE)--working-dir <dir|url>β Working directory for batch system.--sandboxβ Run task in sandbox using bash script and task directory.--verbose-jobnamesβ Set the job name based on the command.
π§ JSON/JX Options π§
--jsonβ Interpret<dagfile>as a JSON format Makeflow.--jxβ Evaluate JX expressions in<dagfile>. Implies--json.--jx-args <args>β Read variable definitions from the JX file<args>.--jx-define <VAL=EXPR>β Set the variable<VAL>to the JX expression<EXPR>.--jx-context <ctx>β Deprecated. See'--jx-args'.
π Debugging Options π
-d,--debug=<subsystem>β Enable debugging for this subsystem.-o,--debug-file=<file>β Write debugging output to this file. By default, debugging is sent to stderr (":stderr"). You may specify logs to be sent to stdout (":stdout") instead.--debug-rotate-max <byte>β Rotate debug file once it reaches this size.--verboseβ Display runtime progress on stdout.
π WorkQueue Options π
-C,--catalog-server=<catalog>β Set catalog server to<catalog>. Format:HOSTNAME:PORT-F,--wq-fast-abort=<#>β WorkQueue fast abort multiplier. (default is deactivated)-M,---N=<project-name>β Set the project name to<project>.-p,--port=<port>β Port number to use with WorkQueue. (default is 9123, 0=arbitrary)-Z,--port-file=<file>β Select port at random and write it to this file. (default is disabled)-P,--priority=<integer>β Priority. Higher the value, higher the priority.-t,--wq-keepalive-timeout=<#>β Work Queue keepalive timeout (default: 30s)-u,--wq-keepalive-interval=<#>β Work Queue keepalive interval (default: 120s)-W,--wq-schedule=<mode>β WorkQueue scheduling algorithm. (time|files|fcfs)password <pwfile>β Password file for authenticating workers.--disable-cacheβ Disable file caching (currently only Work Queue, default is false)--work-queue-preferred-connection <connection>β Indicate preferred connection. Chose one ofby_iporby_hostname. (default isby_ip)
π«Ά Monitor Options π«Ά
--monitor <dir>β Enable the resource monitor, and write the monitor logs to<dir>--monitor-exe <file>β Specify resource monitor executable.--monitor-with-time-seriesβ Enable monitor time series. (default is disabled)--monitor-with-opened-filesβ Enable monitoring of openened files. (default is disabled)--monitor-interval <#>β Set monitor interval to<#>seconds. (default 1 second)--monitor-log-fmt <fmt>β Format for monitor logs. (defaultresource-rule-%06.6d,%d-> rule number)--monitor-measure-dirβ Monitor measures the task's current execution directory size.--allocation <waste>β When monitoring is enabled, automatically assign resource allocations to tasks. Makeflow will try to minimize waste or maximize throughput.
π Umbrella Options π
--umbrella-binary <filepath>β Umbrella binary for running every rule in a makeflow.--umbrella-log-prefix <filepath>β Umbrella log file prefix for running every rule in a makeflow. (default is<makefilename>.umbrella.log)--umbrella-mode <mode>β Umbrella execution mode for running every rule in a makeflow. (default is local)--umbrella-spec <filepath>β Umbrella spec for running every rule in a makeflow.
π³ Docker Support π³
--docker <image>β Run each task in the Docker container with this name. The image will be obtained via"docker pull"if it is not already available.--docker-tar <tar>β Run each task in the Docker container given by this tar file. The image will be uploaded via"docker load"on each execution site.--docker-opt <string>β Specify options to be used inDSingularityockerexecution.
β¨ Singularity Support β¨
--singularity <image>β Run each task in the Singularity container with this name. The container will be created from the passed in image.--singularity-opt <string>β Specify options to be used in Singularity execution.
πΊ Amazon Options πΊ
--amazon-config <path>β Path to Amazon EC2 configuration file generated bymakeflow_ec2_setup.
π΄ Amazon Lambda Options π΄
--lambda-config <path>β Path to Amazon Lambda configuration file generated bymakeflow_lambda_setup.
π¦ Amazon Batch Options π¦
--amazon-batch-config <path>β Path to Amazon Batch configuration file generated bymakeflow_amazon_batch_setup.--amazon-batch-img <img>β Specify image used for Amazon Batch execution.
πͺ Mesos Options πͺ
--mesos-master <hostname>β Indicate the host name of preferred mesos manager.--mesos-path <filepath>β Indicate the path to mesos python2 site-packages.--mesos-preload <library>β Indicate the linking libraries for running mesos..
βΈοΈ Kubernetes Options βΈοΈ
--k8s-image <docker_image>β Indicate the Docker image for running pods on Kubernetes cluster.
ποΈ Mountfile Support ποΈ
--mounts <mountfile>β Use this file as a mountlist. Every line of a mountfile can be used to specify the source and target of each input dependency in the format oftarget source(Note there should be a space between target and source.).--cache <cache_dir>β Use this dir as the cache for file dependencies.
ποΈ Archiving Options ποΈ
--archive <>β Archive results of workflow at the specified path (by default/tmp/makeflow.archive.$UID) and use outputs of any archived jobs instead of re-executing job--archive-dir <path>β Specify archive base directory.--archive-read <path>β Only check to see if jobs have been cached and use outputs if it has been--archive-s3 <s3_bucket>β Base S3 Bucket name--archive-s3-no-check <s3_bucket>β Blind upload files to S3 bucket (No existence check in bucket).--s3-hostname <s3_hostname>β Base S3 hostname. Used for AWS S3.--s3-keyid <s3_key_id>β Access Key for cloud server. Used for AWS S3.--s3-secretkey <secret_key>β Secret Key for cloud server. Used for AWS S3.
ποΈ VC3 Builder Options ποΈ
--vc3-builderβ Enable VC3 Builder--vc3-exe <file>β VC3 Builder executable location--vc3-log <file>β VC3 Builder log name--vc3-options <string>β VC3 Builder option string
π Other Options π
-A,--disable-afs-checkβ Disable the check for AFS. (experts only)-z,--zero-length-errorβ Force failure on zero-length output files.-g,--gc=<type>β Enable garbage collection. (ref_cnt|on_demand|all)--gc-size <int>β sets the disk size that triggers GC. This one is only foron_demandmode, bestie, so if you're not inon_demandit's giving background character energy. π-G,--gc-count=<int>β sets the number of files that triggers GC.ref_cntonly, no cap. β¨--wrapper <script>β wraps all commands with this script. Each rule's original recipe is appended to script or replaces the first occurrence of{}in script. Slay. π--wrapper-input <file>β says the wrapper command requires this input file. You can specify this option more than once, which defines an array of inputs. Also, each job executing a recipe has a unique integer identifier that replaces occurrences of%%in file. π¦--wrapper-output <file>β same vibe but for outputs: the wrapper command requires this output file. Can be specified more than once, defining an array of outputs. And again, each job executing a recipe has a unique integer identifier that replaces occurrences of%%in file. π--enforcementβ usesParrotto restrict access to the given inputs/outputs. No sneaky reads, no sneaky writes. π¦--parrot-path <path>β path to theparrot_runexecutable on the host system. π₯--env-replace-path <path>β path to theenv_replaceexecutable on the host system. πΈ--skip-file-checkβ do not check for file existence before running. It's giving "I trust you, bestie" energy. π--do-not-save-failed-outputβ disables saving failed nodes to a directory for later analysis. So if something goes wrong, no receipts. π--shared-fs <dir>β assumes the given directory is a shared filesystem accessible at all execution sites. π-X,--change-directory=<dir>β changes to<dir>prior to executing the workflow. Main character move. π
β¨ MPI Options β¨
--mpi-cores <#>β number of cores each MPI worker uses. π--mpi-memory <#>β amount of memory each MPI worker uses. π§--mpi-task-working-dir <path>β path to the MPI tasks working directory. π
π DRYRUN MODE π
Okay so when the batch system is set to -T <dryrun>, Makeflow runs as usual but does not actually execute jobs or modify the system. This is useful to check that wrappers and substitutions are applied as expected. In addition, Makeflow will write an equivalent shell script to the batch system log specified by -L <logfile>. This script will run the commands in serial that Makeflow would have run. This shell script format may be useful for archival purposes, since it does not depend on Makeflow. π
π§ MPI π§
When cctools is built with --with-mpi-path=which mpicc configuration, Makeflow can be ran as an MPI program. To do so, run Makeflow as an argument to mpirun/mpiexec and set -T mpi as a Makeflow option. When submitting mpi, request one process per core. Makeflow will count up how many processes each node given to MPI has, and use that as the core count for the worker on that node. Makeflow will then share memory evenly amongst the cores on the node, following the following equation worker_memory = (total_memory / total_logical_cores) * num_cores_for_worker. To override Makeflow sharing memory equally, or setting per-worker cores value, use --mpi-cores and --mpi-memory.
Tasks can also have their own sandbox. To specify the directory for tasks to create their sandbox subdirectory in, use --mpi-task-working-dir.
π± ENVIRONMENT VARIABLES π±
The following environment variables will affect the execution of your Makeflow:
π BATCH_OPTIONS
This corresponds to the -B <options> parameter and will pass extra batch options to the underlying execution engine. β¨
π MAKEFLOW_MAX_LOCAL_JOBS
This corresponds to the -j <#> parameter and will set the maximum number of local batch jobs. If a -j <#> parameter is specified, the minimum of the argument and the environment variable is used. π
π MAKEFLOW_MAX_REMOTE_JOBS
This corresponds to the -J <#> parameter and will set the maximum number of local batch jobs. If a -J <#> parameter is specified, the minimum of the argument and the environment variable is used. π¦
Note that variables defined in your Makeflow are exported to the environment. π
π TCP_LOW_PORT
Inclusive low port in range used with -p 0. π
π TCP_HIGH_PORT
Inclusive high port in range used with -p 0. π
β¨ EXIT STATUS β¨
On success, returns zero. On failure, returns non-zero. Periodt. π
π EXAMPLES π
Run makeflow locally with debugging:
makeflow -d all Makeflow
Run makeflow on Condor with special requirements:
makeflow -T condor -B "requirements = MachineGroup == 'ccl'" Makeflow
Run makeflow with WorkQueue using named workers:
makeflow -T wq -a -N project.name Makeflow
Create a directory containing all of the dependencies required to run the specified makeflow
makeflow -b bundle Makeflow
π COPYRIGHT π
The Cooperative Computing Tools are Copyright (C) 2005-2019 The University of Notre Dame. This software is distributed under the GNU General Public License. See the file COPYING for details. π«Ά
π SEE ALSO π
- Cooperative Computing Tools Documentation
- Makeflow User Manual
makeflow(1)makeflow_monitor(1)makeflow_analyze(1)makeflow_viz(1)makeflow_graph_log(1)starch(1)makeflow_ec2_setup(1)makeflow_ec2_cleanup(1)makeflow_ec2_estimate(1)
mwah π β this was CCTools 8.0.0 DEVELOPMENT, makeflow(1), and that's the whole entire page, bestie. no cap. π
π¦ where this page comes from
- debian bookworm: coop-computing-tools 9.9-2+b4 Β· GPL-2.0-only
- ubuntu jammy: coop-computing-tools 9.9-2ubuntu3 Β· GPL-2.0-only
- ubuntu noble: coop-computing-tools 9.9-4ubuntu4 Β· GPL-2.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms