title: The 66 Suite: 66
author: Eric Vidal <eric@obarun.org>

[66](index.html)

[Software](https://web.obarun.org/software)

[obarun.org](https://web.obarun.org)

# 66

Tool to control the state of the system and service manager.

## Interface

```
    66 [ -h ] [ -z ] [ -v verbosity ] [ -l live ] [ -T timeout ] [ -t tree ] start|stop|reload|restart|free|reconfigure|enable|disable|configure|status|resolve|state|remove|signal|tree|init|parse|scandir|boot|poweroff|reboot|halt|version [<command options> or subcommand <subcommand options>] service...|tree
```

## Options

These options are available all commands except the `-t` options. In such cases, the help of the specific command provides clarification.

- **-h** : prints this help.

- **-z** : use color.

- **-v** *verbosity* : increases/decreases the verbosity of the command.
    * *1* : only print error messages. This is the default.
    * *2* : also, print warning messages.
    * *3* : also, print tracing messages.
    * *4* : also, print debugging messages.
    * *5* : also, display the sequence of the current process function by function.

- **-l** *live* : changes the supervision directory of *service* to *live*. By default this will be `%%livedir%%`. The default can also be changed at compile time by passing the `--livedir=live` option to `./configure`. An existing absolute path is expected and should be within a writable and executable filesystem - likely a RAM filesystem—see [scandir](scandir.html) command.

- **-T** *timeout* : specifies a general timeout (in milliseconds) passed to command. By default the timeout is set to 0 (infinite).

- **-t** *tree* : only handles *service(s)* for *tree*.

## Commands

- [start](start.html): bring up services.
- [stop](stop.html): bring down services.
- [reload](reload.html): send a SIGHUP signal to services.
- [restart](restart.html): bring down then bring up again services.
- [free](free.html): bring down services and remove it from scandir(unsupervise).
- [reconfigure](reconfigure.html): bring down, unsupervise, parse it again and bring up service.
- [enable](enable.html): activate services for the next boot.
- [disable](disable.html): deactivate services for the next boot.
- [configure](configure.html): manage services environment variables.
- [status](status.html): display services information.
- [resolve](resolve.html): display resolve file contents of the service.
- [state](state.html): display state file contents of the service.
- [remove](remove.html): remove services and cleanup all files belong to it from the system.
- [signal](signal.html): send a signal to services.
- [tree](tree.html): manage or see information of trees.
- [init](init.html): initiate to scandir all services marked enabled of a tree.
- [parse](parse.html): parse the service frontend file.
- [scandir](scandir.html): manage scandir.
- [boot](boot.html): boot the system.
- [poweroff](poweroff.html): poweroff the system.
- [reboot](reboot.html): reboot the system.
- [halt](halt.html): halt the system.
- [version](version.html): display 66 version.

## Exit codes

- *0* success
- *100* wrong usage
- *111* system call failed

Furthermore, all commands receive the same exit code.

## Instanced service

An instanced *service* name from a service template can be passed as service argument where the name of the *service* must end with a `@` (commercial at).—see [frontend service file](frontend.html).

**(!)** The name of the template must be declared first immediately followed by the instance name.

For example, to enable a intanced service, you can do:

```
66 enable foo@foobar
```

## Handling dependencies

Any dependency or required by dependency of a service or a tree chain will be automatically resolved. Manually defining chains of interdependencies is unnecessary.

For instance, during the `stop` command, if the `FooA` service has a declared required by dependency on `FooB`, `FooB` will be automatically considered and stopped first when `FooA` is stopped. This process will run recursively until all required by dependencies are stopped.

This applies to all `66` commands.