Skip to content

Commit c84df5a

Browse files
committed
docs: Add instructions for setting log level
1 parent cf59b7c commit c84df5a

File tree

2 files changed

+34
-10
lines changed

2 files changed

+34
-10
lines changed

docs/next/modules/en/pages/troubleshooting/troubleshooting.adoc

Lines changed: 17 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -201,10 +201,22 @@ Output:
201201
+
202202
image::lineage-cluster-output.png[Output]
203203

204-
== How to enable debug mode
204+
== How to enable debug mode for Rancher Turtles and CAPI providers
205205

206-
* Cluster API Providers - edit CAPIProvider resources for providers where increasing log level is needed. Change to desidered level:
206+
* Rancher Turtles
207+
+
208+
To enable debug mode for Rancher Turtles, you need to patch `cattle-system/rancher-config` configmap as follows:
209+
+
210+
[source,bash]
211+
----
212+
kubectl patch configmap -n cattle-system rancher-config --type merge --patch '{"data":{"rancher-turtles": "managerArguments:\n - --v=5\n"}}'
213+
----
214+
(5 is equivalent to DEBUG)
215+
+
216+
This results in the Turtles pod being restarted, in order to use the new configuration.
207217

218+
* Cluster API Providers - edit CAPIProvider resources for providers where increasing log level is needed. Change to desidered level:
219+
+
208220
[source,bash]
209221
----
210222
CAPIProvider.Spec.Manager.Verbosity=5
@@ -328,7 +340,7 @@ kubectl delete mutatingwebhookconfigurations [webhook-name]
328340
* cattle-turtles-system
329341
* rke2-bootstrap-system
330342
* rke2-control-plane-system
331-
* capi-system
343+
* cattle-capi-system
332344
* capz-system (or other provider-specific namespaces like capv-system, capa-system, etc.)
333345
* capi-clusters (or other namespaces where you deployed clusters)
334346
+
@@ -337,12 +349,12 @@ To remove these namespaces:
337349
[source,bash]
338350
----
339351
# First remove any finalizers that might be blocking deletion
340-
for NS in cattle-turtles-system rke2-bootstrap-system rke2-control-plane-system capi-system capz-system capi-clusters; do
352+
for NS in cattle-turtles-system rke2-bootstrap-system rke2-control-plane-system cattle-capi-system capz-system capi-clusters; do
341353
kubectl get namespace $NS -o json | jq '.spec.finalizers = []' | kubectl replace --raw "/api/v1/namespaces/$NS/finalize" -f -
342354
done
343355
344356
# Then delete the namespaces
345-
kubectl delete namespace cattle-turtles-system rke2-bootstrap-system rke2-control-plane-system capi-system capz-system capi-clusters
357+
kubectl delete namespace cattle-turtles-system rke2-bootstrap-system rke2-control-plane-system cattle-capi-system capz-system capi-clusters
346358
----
347359
+
348360
. Finally, remove the CRDs related to Cluster API and Rancher Turtles:

docs/v0.25/modules/en/pages/troubleshooting/troubleshooting.adoc

Lines changed: 17 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -201,10 +201,22 @@ Output:
201201
+
202202
image::lineage-cluster-output.png[Output]
203203

204-
== How to enable debug mode
204+
== How to enable debug mode for Rancher Turtles and CAPI providers
205205

206-
* Cluster API Providers - edit CAPIProvider resources for providers where increasing log level is needed. Change to desidered level:
206+
* Rancher Turtles
207+
+
208+
To enable debug mode for Rancher Turtles, you need to patch `cattle-system/rancher-config` configmap as follows:
209+
+
210+
[source,bash]
211+
----
212+
kubectl patch configmap -n cattle-system rancher-config --type merge --patch '{"data":{"rancher-turtles": "managerArguments:\n - --v=5\n"}}'
213+
----
214+
(5 is equivalent to DEBUG)
215+
+
216+
This results in the Turtles pod being restarted, in order to use the new configuration.
207217

218+
* Cluster API Providers - edit CAPIProvider resources for providers where increasing log level is needed. Change to desidered level:
219+
+
208220
[source,bash]
209221
----
210222
CAPIProvider.Spec.Manager.Verbosity=5
@@ -328,7 +340,7 @@ kubectl delete mutatingwebhookconfigurations [webhook-name]
328340
* cattle-turtles-system
329341
* rke2-bootstrap-system
330342
* rke2-control-plane-system
331-
* capi-system
343+
* cattle-capi-system
332344
* capz-system (or other provider-specific namespaces like capv-system, capa-system, etc.)
333345
* capi-clusters (or other namespaces where you deployed clusters)
334346
+
@@ -337,12 +349,12 @@ To remove these namespaces:
337349
[source,bash]
338350
----
339351
# First remove any finalizers that might be blocking deletion
340-
for NS in cattle-turtles-system rke2-bootstrap-system rke2-control-plane-system capi-system capz-system capi-clusters; do
352+
for NS in cattle-turtles-system rke2-bootstrap-system rke2-control-plane-system cattle-capi-system capz-system capi-clusters; do
341353
kubectl get namespace $NS -o json | jq '.spec.finalizers = []' | kubectl replace --raw "/api/v1/namespaces/$NS/finalize" -f -
342354
done
343355
344356
# Then delete the namespaces
345-
kubectl delete namespace cattle-turtles-system rke2-bootstrap-system rke2-control-plane-system capi-system capz-system capi-clusters
357+
kubectl delete namespace cattle-turtles-system rke2-bootstrap-system rke2-control-plane-system cattle-capi-system capz-system capi-clusters
346358
----
347359
+
348360
. Finally, remove the CRDs related to Cluster API and Rancher Turtles:

0 commit comments

Comments
 (0)