[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Inconsistent console behavior during HVM direct boot

  • To: Tamas K Lengyel <tamas@xxxxxxxxxxxxx>
  • From: Roger Pau Monné <roger.pau@xxxxxxxxxx>
  • Date: Wed, 13 Jan 2021 14:18:09 +0100
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=citrix.com; dmarc=pass action=none header.from=citrix.com; dkim=pass header.d=citrix.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=OyGFCizgsQ4aq4V8NYgz7FltBEr9KkLGcfSuSPJv2fg=; b=jDbU8OS67nr/PZkoxHa0jq4RVZySW+D0rkXIu3K0hRiNi/wu3gb59TufSTGUMrUcYKSTzrRDIEWWg2T1nBMsdnQJh+L0yDzUexcAzHZ8e2oUNvCu9cY/H0eHj4s4003bfymK1j7tpzl6c0/gP4YyDtUmUQ04wNYddZtL3gemdbQXdTbotX9p+fC7caDIGvTsV2y01jtjtotQYS6JlaKpr5aM6/ktUwlp3qTb1h8Qy1ipVeMtHxVIciTVckMyuCe54oLvAShuwVsBAMHKsedSH01IZg5wwvqEJXwnXrIlRzyPloPkplVoXauOxug8eiN1zdMiNMkR283mhJRM2A7tmw==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=lHKf6j3tDkp/iryfO6XTpnNRxnySDI2Mc1wVtQBTR2yOd5KFE9vuHvsQ/eWT6mfcxo1fKg4+HqfJyCNo8wH9UCAPLCBX1v8A8nR8yrVMhs74jyAjfjwE++q2R/2me5wpu0C/Ta2ox+k/zRvRngd9dfJTqNnsZf/TzHeQoxkKIPWa+69/iq1wjQ81dwKQzpUQi6g1Vz72OXDJp4rRyLIbNgozO1kNyOOYEzfAbZaPtB9vXi3oZqBlN/pWfqMwzx9lyuX9o9T18nGJuqf2FB4mdk+O4P78nWL7xJlT7EtfR4ww19uWghri3blsTJZLFZb1Y+qka/gUgfxpNFd0x7WNOA==
  • Authentication-results: esa3.hc3370-68.iphmx.com; dkim=pass (signature verified) header.i=@citrix.onmicrosoft.com
  • Cc: Xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxxx>, <amc96@xxxxxxxxx>, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
  • Delivery-date: Wed, 13 Jan 2021 13:18:26 +0000
  • Ironport-sdr: X5SY6I9NwhBe8gtNq7XAyFF9Qm2X/DOTzZzJvHHTZRkTbrMebEBACsHt6ffJAdbFwduC4bgScP OjA09w12O3M8Mnp9aLjKJ0xzobRrPqkKsmAGBt/op/zRYgRCzW6U1LOxIgIoLpFojc4LLop/2+ fglwZZqPyiVgMh/t3kW1MxvlP0Cl7sbAFdKN2CWq2QHozMqlMpWErElIkwbDL0U+IVOeag8elY lkP/qHsxmMTFGD/1guUKv9rKaiJP/QryepNv197Lj77IQA37uMe2o+1NwzxyZ9V/lDhSEA/jjw pa0=
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

On Tue, Jan 12, 2021 at 09:54:18PM -0500, Tamas K Lengyel wrote:
> While direct booting a Linux kernel into an HVM VM no console output
> is received if serial="pty" is set in the VM config but the kernel
> command line specifies "console=hvc0". If "console=ttyS0" is specified
> then the console output is received as expected. Conversely, if the
> serial line is commented out in the VM config but hvc0 is set on the
> kernel command line then it also works. It's unclear whether this
> behavior is expected or not, after some discussion it sounds like all
> kernels ought to understand hvc0 irrespective of the serial="pty" line
> being set or not. Reporting this in case someone has more insight
> and/or inclination digging into this.

So I think this is (as confusing as it might seem) the intended

Using serial='pty' exposes an emulated serial device to the guest and
'xl console' will fetch the output from that device by default. So on
the Linux kernel command line you need to use console=ttyS0 in order
to point Linux to use the emulated serial device.

however if serial='pty' is not used, there will be no emulated serial
device exposed to the guest, only the PV console, and that's what 'xl
console' will attach to in that case. You then need to point the Linux
kernel to use the PV serial console, by adding the console=hvc0
command line.

I'm unsure how to clarify this, maybe some additions could be made to
the xl.cfg man page to note that using serial='pty' will add an
emulated serial device to the guest, and that by default 'xl console'
will fetch the output from that device instead of the paravirtualized




Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.