mirror of
https://github.com/openshift/openshift-docs.git
synced 2026-02-05 12:46:18 +01:00
24 lines
644 B
Plaintext
24 lines
644 B
Plaintext
// Module included in the following assemblies:
|
|
//
|
|
// * virt/support/virt-troubleshooting.adoc
|
|
|
|
:_mod-docs-content-type: PROCEDURE
|
|
[id="virt-view-guest-system-logs-cli_{context}"]
|
|
= Viewing guest system logs with the CLI
|
|
|
|
You can view the serial console logs of a VM guest by running the `oc logs` command.
|
|
|
|
.Prerequisites
|
|
|
|
* Guest system log access is enabled.
|
|
* You have installed the {oc-first}.
|
|
|
|
.Procedure
|
|
|
|
* View the logs by running the following command, substituting your own values for `<namespace>` and `<vm_name>`:
|
|
+
|
|
[source,terminal]
|
|
----
|
|
$ oc logs -n <namespace> -l kubevirt.io/domain=<vm_name> --tail=-1 -c guest-console-log
|
|
----
|