Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Edit pass over telemetry docs #268

Merged
merged 3 commits into from
Jul 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 15 additions & 2 deletions frameworks/management.rst
Original file line number Diff line number Diff line change
Expand Up @@ -633,11 +633,11 @@ All but the worker nodes in a Zeek cluster require a listening port, and you can
specify one for each node as shown in the above configuration. If you'd rather
not pick ports, the controller can auto-enumerate ports for you, as follows:

* The :zeek:see:`Management::Controller::auto_assign_ports` Boolean, which defaults to
* The :zeek:see:`Management::Controller::auto_assign_broker_ports` Boolean, which defaults to
``T``, controls whether port auto-enumeration is active. Redefining to ``F``
disables the feature.

* :zeek:see:`Management::Controller::auto_assign_start_port` defines the starting point
* :zeek:see:`Management::Controller::auto_assign_broker_start_port` defines the starting point
for port enumeration. This defaults to ``2200/tcp``.

* Any nodes with explicitly configured ports will keep them.
Expand All @@ -655,6 +655,19 @@ not pick ports, the controller can auto-enumerate ports for you, as follows:
By retrieving the deployed configuration from the controller (see the next two
sections) you can examine which ports the controller selected.

Configuration of the Telemetry framework
----------------------------------------

By default, the framework will enable Prometheus metrics exposition ports,
including a service discovery endpoint on the mananger (refer to the
:ref:`Telemetry Framework <framework-telemetry>` for details), and
auto-assign them for you. Specifically, the controller will enumerate ports
starting from
:zeek:see:`Management::Controller::auto_assign_metrics_start_port`, which
defaults to ``9000/tcp``. Any ports you define manually will be preserved. To
disable metrics port auto-assignment, redefine
:zeek:see:`Management::Controller::auto_assign_metrics_ports` to ``F``.

Staging and deploying configurations
------------------------------------

Expand Down
6 changes: 6 additions & 0 deletions frameworks/management/full-config.ini
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,12 @@ role = manager
#
# port = 1234

# You can optionally specify explicit metrics exposition ports for each
# node. If you omit these, the framework (specifically, the controller)
# will define ports for you. Only give a number; TCP is implied.
#
# metrics_port = 9090

# You can provide additional scripts that a node should run. These scripts
# must be available on the instance. Space-separate multiple scripts.
#
Expand Down
427 changes: 234 additions & 193 deletions frameworks/telemetry.rst

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion frameworks/telemetry/connection-durations.zeek
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ global conn_durations_hf = Telemetry::register_histogram_family([
$unit="seconds",
$help_text="Duration of monitored connections",
$bounds=vector(0.1, 1.0, 10.0, 30.0, 60.0),
$labels=vector("proto", "service")
$label_names=vector("proto", "service")
]);

event connection_state_remove(c: connection)
Expand Down
2 changes: 1 addition & 1 deletion frameworks/telemetry/log-writes-cached.zeek
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ global log_writes_cf = Telemetry::register_counter_family([
$name="log_writes",
$unit="1",
$help_text="Number of log writes per stream",
$labels=vector("log_id")
$label_names=vector("log_id")
]);

# Cache for the Telemetry::Counter instances.
Expand Down
2 changes: 1 addition & 1 deletion frameworks/telemetry/log-writes-immediate.zeek
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ global log_writes_cf = Telemetry::register_counter_family([
$name="log_writes",
$unit="1",
$help_text="Number of log writes per stream",
$labels=vector("log_id")
$label_names=vector("log_id")
]);

hook Log::log_stream_policy(rec: any, id: Log::ID)
Expand Down
2 changes: 1 addition & 1 deletion frameworks/telemetry/log-writes-sync.zeek
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ global log_writes_cf = Telemetry::register_counter_family([
$name="log_writes",
$unit="1",
$help_text="Number of log writes per stream",
$labels=vector("log_id")
$label_names=vector("log_id")
]);

global log_writes: table[Log::ID] of count &default=0;
Expand Down
2 changes: 1 addition & 1 deletion frameworks/telemetry/version.zeek
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ global version_gf = Telemetry::register_gauge_family([
$name="version_info",
$unit="1",
$help_text="The Zeek version",
$labels=vector("version_number", "major", "minor", "patch", "commit", "beta", "debug","version_string")
$label_names=vector("version_number", "major", "minor", "patch", "commit", "beta", "debug","version_string")
]);

event zeek_init()
Expand Down
Loading