Page 1 of 1

How to Enable the Serial Console for virsh, centos

Posted: 20 Apr 2015 10:58
by pdwalker
These are the steps I took to allow the serial console in efa build from scratch on Centos to work under kvm/qemu so I can access the server console at all times

Configure the Serial Terminal
vi /etc/init/ttyS0.conf

Code: Select all

stop on runlevel[016]
start on runlevel[345]
respawn
instance /dev/ttyS0
exec /sbin/mingetty /dev/ttyS0
Allow root login via ttyS0
vi /etc/securetty

Code: Select all

# append this to the end of the file:
ttyS0
Start the serial console
initctl start ttyS0

Test the serial console via the host machine
virsh console <efa machine> <enter><enter>

Configure Boot Output to use the serial console as well
vi /etc/grub.conf

Code: Select all

# append to all kernel= lines 
console=ttyS0
# remove from all kernel= lines if they exist
rhgb
quiet
reboot and test

copied entirely from here: https://mcdee.com.au/kvm-virsh-console-access-centos/

Re: How to Enable the Serial Console for virsh, centos

Posted: 20 Apr 2015 21:58
by shawniverson
:dance: