Thursday, May 03, 2007

Supplement for FedoraXenQuickstartFC5/6

When we want to use "xm console vm-name/id" on fully-virtualized VMs, we can find solution on http://fedoraproject.org/wiki/FedoraXenQuickstartFC6. However, it doesn't work if you don't do some changes in the guest.
Fullyvirt guest serial console access

Fully-virtualized guest OS will automatically have a serial console configured, but the guest kernel will not be configured to use this out of the box. To enable the guest console in a Linux fully-virt guest, edit the /etc/grub.conf in the guest and add 'console=ttyS0 console=tty0'. This ensures that all kernel messages get sent to the serial console, and the regular graphical console. The serial console can then be access in same way as paravirt guests:

# xm console

Alternatively, the graphical virt-manager program can display the serial console. Simply display the 'console' or 'details' window for the guest & select 'View -> Serial console' from the menu bar.

Beside above information from Fedora, we have to do below changes:
# vi /etc/inittab
add
0:2345:respawn:/sbin/mingetty tty0
S0:2345:respawn:/sbin/mingetty ttyS0
in that file.
# init q
# vi /etc/securetty
add tty0 and ttyS0 in that file.