Skip to content

ChannelCtl

Abstract

the channelctl command line tool is the primary cli used to manage channels.

Documentation

Like all the punch client tools, documentation is available online, either in an interactive mode or by simply typing:

channelctl -h
or

channelctl status --help

In addition, you can also refer to the manual page:

man channelctl

An online channelctl manual page is also available.

Usage

Please refer to the inline documentation. The few essential commands you are likely to use are:

channelctl start --channel aChannel
or to start all tenant channels
channelctl start 
The stop command is similar. You have an additional reload command that automatically restart only the channels punchlines that are tagged to be reloadable. That is extremally convenient to selectively restart many punchlines without affecting the ones in charge of real time traffic ingestion.

channelctl reload 

All these commands can be geared toward a single channel, a single channel application, or all channels of your tenant.

Tip

All punch cli tools support a smart completion strategy. Do not hesitate launching the interactive command by simply typing

channelctl 

Troubleshooting

The channelctl also provides online valuable information regarding the status of what is running, as well as detailed information about your configuration. In particular to see the content of a channel you can type in the view command to have at hand the content of a channel:

punch-standalone:[~]$ channelctl view --channel sourcefire
{
  stop_by_tenant: true
  version: "6.0"
  start_by_tenant: true
  applications:
  [
    {
      cluster: local
      execution_mode: cluster
      full_name: mytenant/sourcefire/input
      name: input
      runtime: storm
      reload_action: kill_then_start
    }
  ]
}

The describe command shows the runtime status of a channel. In the following example the "sourcefire" channel has a single and active punchline of type "storm"

punch-standalone:[~]$ channelctl describe --channel sourcefire
{
  "size": 1,
  "name": "sourcefire",
  "state_update_timestamp": "2020-12-12T09:24:57.028000+01:00",
  "state": "ACTIVE",
  "version": "6.0",
  "hash": "3f465da5dbc3af1b8bce96590dfa0b5f",
  "tenant": "mytenant",
  "applications": {
    "sourcefire/local/input": {
      "cluster": "local",
      "full_name": "sourcefire/local/input",
      "name": "input",
      "reload_action": "kill_then_start",
      "state_update_timestamp": "2020-12-12T09:24:57.028000+01:00",
      "jar": "",
      "state": "ACTIVE",
      "id": "mytenant_sourcefire_input-6-1607761496",
      "type": "storm",
      "version": "0.0",
      "tenant": "mytenant"
    }
  },
  "uptime": "2020-12-12T09:24:57.028000+01:00"
}

Note

The runtime status is the one known to run now, it is not necessarily the configuration you see in your configuration folder or database. It is indeed possible for an authorized user to update the configuration of a channel without stopping it.