Skip to content

Commit 43a9410

Browse files
committed
Add new --verbose option to the docs
1 parent a781d5d commit 43a9410

17 files changed

+142
-0
lines changed

Diff for: docs/src/SUMMARY.md

+4
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,10 @@
5656

5757
- [bootc image](experimental-bootc-image.md)
5858
- [--progress-fd](experimental-progress-fd.md)
59+
-
60+
# Troubleshooting
61+
62+
- [increasing_logging_verbosity](increasing_logging_verbosity.md)
5963

6064
# More information
6165

Diff for: docs/src/increasing_logging_verbosity.md

+48
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
# Increasing Logging Verbosity
2+
3+
When troubleshooting issues with **bootc**, it is often helpful to enable **verbose logging** to gain additional insights into its execution flow.
4+
5+
## Using the `--verbose` Flag
6+
Most **bootc** commands support the `--verbose` flag, which enables detailed logging output. The verbosity level determines how much information is logged.
7+
8+
### **Verbosity Levels**
9+
The `--verbose` flag can be used multiple times (`-v`, `-vv`, `-vvv`) to increase the verbosity of logging:
10+
11+
| Verbosity Level | Flag Used | Logs Enabled |
12+
|---------------|-----------|--------------|
13+
| **WARN** (default) | *(no flag)* | Only warnings and errors |
14+
| **INFO** | `-v` | Warnings, errors, and general information |
15+
| **DEBUG** | `-vv` | Info, warnings, errors, and debug logs |
16+
| **TRACE** | `-vvv` or more | All logs, including low-level tracing |
17+
18+
### Example Usage
19+
To switch to a new container image with verbose logging enabled:
20+
```sh
21+
bootc switch --apply -vv quay.io/centos-bootc/centos-bootc:stream9
22+
```
23+
This command will print **INFO, DEBUG, and WARN logs**, helping diagnose issues during the `switch` process.
24+
25+
### Example Output (Verbose Mode Enabled with `-vv`)
26+
```sh
27+
$ bootc switch --apply -vvv quay.io/centos-bootc/centos-bootc:stream9
28+
TRACE Verified uid 0 with CAP_SYS_ADMIN
29+
DEBUG Re-executing current process for _ostree_unshared
30+
DEBUG Already in a mount namespace
31+
DEBUG Current security context is unconfined_u:system_r:install_t:s0:c1023
32+
INFO We have install_t
33+
INFO Staged: None
34+
DEBUG Rollback queued=false
35+
DEBUG Wrote merge commit b8761b75924d7f21e7f92abc8fd8b3c645d289fc91555
36+
DEBUG new_with_config: Spawned skopeo pid=1023
37+
TRACE new_with_config: impl_request: sending request Initialize
38+
TRACE new_with_config: impl_request: completed request Config=ImageProxy
39+
```
40+
With `-vvv`, the output includes **INFO, DEBUG, WARN, and TRACE** level messages.
41+
42+
## Using the `RUST_LOG` Environment Variable
43+
For even more detailed logging, use the `RUST_LOG` environment variable (if applicable for Rust-based components):
44+
45+
```sh
46+
RUST_LOG=debug bootc switch --apply -vvv quay.io/centos-bootc/centos-bootc:stream9
47+
```
48+
The environment variable will override the `-vvv` and enable **DEBUG** level logs for Rust-based sub-components within **bootc**.

Diff for: docs/src/man/bootc-container-lint.md

+6
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,12 @@ part of a build process; it will error if any problems are detected.
2222

2323
: Operate on the provided rootfs
2424

25+
**-v**, **\--verbose**
26+
27+
: Increase logging verbosity
28+
29+
Use `-vv`, `-vvv` to increase verbosity more.
30+
2531
**\--fatal-warnings**
2632

2733
: Make warnings fatal

Diff for: docs/src/man/bootc-container.md

+6
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,12 @@ Operations which can be executed as part of a container build
1313

1414
# OPTIONS
1515

16+
**-v**, **\--verbose**
17+
18+
: Increase logging verbosity
19+
20+
Use `-vv`, `-vvv` to increase verbosity more.
21+
1622
**-h**, **\--help**
1723

1824
: Print help

Diff for: docs/src/man/bootc-edit.md

+6
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,12 @@ Only changes to the \`spec\` section are honored.
2626

2727
: Use filename to edit system specification
2828

29+
**-v**, **\--verbose...**
30+
31+
: Increase logging verbosity
32+
33+
Use `-vv`, `-vvv` to increase verbosity more.
34+
2935
**\--quiet**
3036

3137
: Dont display progress

Diff for: docs/src/man/bootc-install-ensure-completion.md

+6
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,12 @@ your code is using \`bootc install to-filesystem\` from the start.
2121

2222
# OPTIONS
2323

24+
**-v**, **\--verbose**
25+
26+
: Increase logging verbosity
27+
28+
Use `-vv`, `-vvv` to increase verbosity more.
29+
2430
**-h**, **\--help**
2531

2632
: Print help (see a summary with -h)

Diff for: docs/src/man/bootc-install-print-configuration.md

+6
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,12 @@ string-valued filesystem name suitable for passing to \`mkfs.\$type\`.
2121

2222
# OPTIONS
2323

24+
**-v**, **\--verbose**
25+
26+
: Increase logging verbosity
27+
28+
Use `-vv`, `-vvv` to increase verbosity more.
29+
2430
**-h**, **\--help**
2531

2632
: Print help (see a summary with -h)

Diff for: docs/src/man/bootc-install-to-disk.md

+6
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,12 @@ more complex such as RAID, LVM, LUKS etc.
2828

2929
# OPTIONS
3030

31+
**-v**, **\--verbose**
32+
33+
: Increase logging verbosity
34+
35+
Use `-vv`, `-vvv` to increase verbosity more.
36+
3137
**\--wipe**
3238

3339
: Automatically wipe all existing data on device

Diff for: docs/src/man/bootc-install-to-existing-root.md

+6
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,12 @@ cleaned up if desired when rebooted into the new root.
4141
However, the running system (and all files) will remain in place
4242
until reboot
4343

44+
**-v**, **\--verbose**
45+
46+
: Increase logging verbosity
47+
48+
Use `-vv`, `-vvv` to increase verbosity more.
49+
4450
**\--source-imgref**=*SOURCE_IMGREF*
4551

4652
: Install the system from an explicitly given source.

Diff for: docs/src/man/bootc-install-to-filesystem.md

+6
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,12 @@ is currently expected to be empty by default.
3333

3434
If not provided, the UUID of the target filesystem will be used.
3535

36+
**-v**, **\--verbose**
37+
38+
: Increase logging verbosity
39+
40+
Use `-vv`, `-vvv` to increase verbosity more.
41+
3642
**\--boot-mount-spec**=*BOOT_MOUNT_SPEC*
3743

3844
: Mount specification for the /boot filesystem.

Diff for: docs/src/man/bootc-install.md

+6
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,12 @@ includes other setup and metadata.
3030

3131
# OPTIONS
3232

33+
**-v**, **\--verbose**
34+
35+
: Increase logging verbosity
36+
37+
Use `-vv`, `-vvv` to increase verbosity more.
38+
3339
**-h**, **\--help**
3440

3541
: Print help (see a summary with -h)

Diff for: docs/src/man/bootc-rollback.md

+6
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,12 @@ rollback invocation.
2828

2929
# OPTIONS
3030

31+
**-v**, **\--verbose**
32+
33+
: Increase logging verbosity
34+
35+
Use `-vv`, `-vvv` to increase verbosity more.
36+
3137
**-h**, **\--help**
3238

3339
: Print help (see a summary with -h)

Diff for: docs/src/man/bootc-status.md

+6
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,12 @@ not \`null\`.
2929

3030
# OPTIONS
3131

32+
**-v**, **\--verbose**
33+
34+
: Increase logging verbosity
35+
36+
Use `-vv`, `-vvv` to increase verbosity more.
37+
3238
**\--format**=*FORMAT*
3339

3440
: The output format\

Diff for: docs/src/man/bootc-switch.md

+6
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,12 @@ updates via container image tags; for example,
3030

3131
: Dont display progress
3232

33+
**-v**, **\--verbose**
34+
35+
: Increase logging verbosity
36+
37+
Use `-vv`, `-vvv` to increase verbosity more.
38+
3339
**\--apply**
3440

3541
: Restart or reboot into the new target image.

Diff for: docs/src/man/bootc-upgrade.md

+6
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,12 @@ the update in addition.
3131

3232
: Dont display progress
3333

34+
**-v**, **\--verbose**
35+
36+
: Increase logging verbosity
37+
38+
Use `-vv`, `-vvv` to increase verbosity more.
39+
3440
**\--check**
3541

3642
: Check if an update is available without applying it.

Diff for: docs/src/man/bootc-usr-overlay.md

+6
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,12 @@ unmount\".
3333

3434
# OPTIONS
3535

36+
**-v**, **\--verbose**
37+
38+
: Increase logging verbosity
39+
40+
Use `-vv`, `-vvv` to increase verbosity more.
41+
3642
**-h**, **\--help**
3743

3844
: Print help (see a summary with -h)

Diff for: docs/src/man/bootc.md

+6
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,12 @@ pulled and \`bootc upgrade\`.
2020

2121
# OPTIONS
2222

23+
**-v**, **\--verbose**
24+
25+
: Increase logging verbosity
26+
27+
Use `-vv`, `-vvv` to increase verbosity more.
28+
2329
**-h**, **\--help**
2430

2531
: Print help (see a summary with -h)

0 commit comments

Comments
 (0)