Overview
If you've installed CTL as described in the download and install section, running commands via the CTL command-line is simple. CTL provides two command-line tools to execute commands: ctl-exec lets you execute ad-hoc commands, while ctl lets you execute defined commands.
The table below describes the difference between the two.
| Command-line | Type | When to use |
|---|---|---|
| ctl-exec | Ad-hoc |
Use ctl-exec whenever you want to perform a distributed execution of an abritrary shell script or set of system commands. Ad-hoc commands are traditionally either executed by logging into individual machines and typing commands into the shell or using ssh to execute them (perhaps in a looping script). The ctl-exec command-line tool lets you execute ad-hoc commands, taking care of the dispatching logic for you and thus alleviating the need to either login to individual machines or write inflexible looping remote execution scripts. See the running ctl-exec for an introduction. |
| ctl | Defined |
Use ctl whenever you want to run a command that is defined in a CTL control module. A defined command is a script or procedure saved into a library called a module. Once these modules are installed into the CTL framework, they are available to the CTL control dispatcher. CTL comes bundled with two libraries of modules, each containing various utility commands. Incorporate that functionality into your own scripts by calling the ctl command-line specifying the module name and command. Of course, you can write your own modules too, if you want to package your own key procedures and add them to the framework. See the running ctl for an introduction. |



