0

I've Installed Centos AtomicHost Os on KVM , I just want to enable virsh console on it ! Tried below method but its is not working. 1. Added console=tty0 on /etc/grub/defailt

GRUB_CMDLINE_LINUX="crashkernel=auto rd.lvm.lv=centos/root rd.lvm.lv=centos/swap rhgb quiet console=ttyS0"
  1. Added below lines on virsh edit As per this: https://linuxadmin.io/enable-virsh-console-kvm/
midhun k
  • 131
  • 2
  • 3

1 Answers1

0

CentOS Atomic images have the serial console redirected to kvm/qemu serial port.

To connect to the serial port and see the boot messages:

virsh list --all   # To list all VMs
virsh shutdown <centos-atomic-VM-name>  # Stop the VM
virsh start --console <centos-atomic-VM-name>   # Connect on the VM's console and start it
Mircea Vutcovici
  • 17,619
  • 4
  • 56
  • 83
  • Thanks for your time - but i need to have this serial connection permanent , suppose in some situation if i cant reach the server using ssh then i can use virsh console to access its console – midhun k Mar 22 '20 at 02:17
  • You can use `virsh console ` to connect to console when VM is running – Mircea Vutcovici Mar 22 '20 at 05:16