-
Notifications
You must be signed in to change notification settings - Fork 321
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
docs:tutorial: add debugging tetragon with log levels
Signed-off-by: Djalal Harouni <tixxdz@gmail.com>
- Loading branch information
Showing
1 changed file
with
37 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
--- | ||
title: "Debugging Tetragon" | ||
weight: 1 | ||
icon: "overview" | ||
description: "Diagnosing Tetragon problems" | ||
--- | ||
|
||
### Enable debug log level | ||
|
||
Debugging problems is easy if we have the right logs. To change Tetragon log level use the `log-level` option: | ||
|
||
* Enable debug level with `--log-level=debug` | ||
|
||
* Enable trace level with `--log-level=trace` | ||
|
||
### Change log level dynamically | ||
|
||
It is possible to change the log level dynamically by sending the corresponding signal to tetragon process. | ||
|
||
* Change log level to debug level by sending the `SIGRTMIN+20` signal to tetragon pid: | ||
|
||
```shell | ||
sudo kill -s SIGRTMIN+20 $(pidof tetragon) | ||
``` | ||
|
||
* Change log level to trace level by sending the `SIGRTMIN+21` signal to tetragon pid: | ||
|
||
```shell | ||
sudo kill -s SIGRTMIN+21 $(pidof tetragon) | ||
``` | ||
|
||
* To Restore the original log level send the `SIGRTMIN+22` signal to tetragon pid: | ||
|
||
```shell | ||
sudo kill -s SIGRTMIN+22 $(pidof tetragon) | ||
``` | ||
|