Request: Serial Terminal logging

riptide_wave

Member
Mar 21, 2013
73
2
8
Minnesota, USA
Hello,

Recently I have been having issues with one of my VM instances locking up, and am having a hard time diagnosing the cause. Currently the plan is to just run "qm terminal 1**" in a screen session, but this is not the best way as it does not persist across reboots of the hypervisor.

With that said, is there any way to enable logging of a VM that has serial enabled? It would be great to have it log console output to a file, for example, /var/lib/vm-serial/1**.log. This way logrotate could be added to help prevent obsessive disk usage.
 
This would be a great feature, though such logs probably belong in /var/log rather than /var/lib.
 
I use linux kernel internal features which are normally also used on "real" hardware for this:
  • netconsole for "remote logging"
  • sysrq and crashkernel for direct logging and crashing