From a3b634032cadd0567aca93e8d60ad2fdd7402228 Mon Sep 17 00:00:00 2001 From: Sasha Levin Date: Tue, 6 Dec 2011 16:31:25 +0200 Subject: [PATCH] kvm tools: Document virtio-console usage Signed-off-by: Sasha Levin Signed-off-by: Pekka Enberg --- tools/kvm/Documentation/virtio-console.txt | 41 ++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 tools/kvm/Documentation/virtio-console.txt diff --git a/tools/kvm/Documentation/virtio-console.txt b/tools/kvm/Documentation/virtio-console.txt new file mode 100644 index 000000000000..4a58d567c991 --- /dev/null +++ b/tools/kvm/Documentation/virtio-console.txt @@ -0,0 +1,41 @@ +General +-------- + +virtio-console as the name implies is a console over virtio transport. Here is +a simple head to head comparison of the virtio-console vs regular 8250 console: + +8250 serial console: + + - Requires CONFIG_SERIAL_8250=y and CONFIG_SERIAL_8250_CONSOLE=y kernel configs, +which are enabled almost everywhere. + - Doesn't require guest-side changes. + - Compatible with older guests. + +virtio-console: + + - Requires CONFIG_VIRTIO_CONSOLE=y (along with all other virtio dependencies), +which got enabled only in recent kernels (but not all of them). + - Much faster. + - Consumes less processing resources. + - Requires guest-side changes. + +Enabling virtio-console +------------------------ + +First, make sure guest kernel is built with CONFIG_VIRTIO_CONSOLE=y. Once this +is done, the following has to be done inside guest image: + + - Add the following line to /etc/inittab: + 'hvc0:2345:respawn:/sbin/agetty -L 9600 hvc0' + - Add 'hvc0' to /etc/securetty (so you could actually log on) + - Start the guest with '--console virtio' + +Common errors +-------------- + +Q: I don't see anything on the screen! +A: Make sure CONFIG_VIRTIO_CONSOLE=y is enabled in the *guest* kernel, also +make sure you've updated /etc/inittab + +Q: It won't accept my username/password, but I enter them correctly! +A: You didn't add 'hvc0' to /etc/securetty -- 2.39.5