unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
* GRUB and installer invisible on serial console
@ 2019-12-21 17:31 Ricardo Wurmus
  2019-12-21 19:00 ` Danny Milosavljevic
       [not found] ` <634287529887714596f1f4ecdcbf8224@waegenei.re>
  0 siblings, 2 replies; 6+ messages in thread
From: Ricardo Wurmus @ 2019-12-21 17:31 UTC (permalink / raw)
  To: guix-devel

Hi Guix,

I just wanted to install Guix System on a server where I currently only
have remote access via serial console — and which happens to have a Guix
USB stick stuck in its USB port.  I can see the system’s UEFI output and
see that it boots from USB, but “Welcome to GRUB!” is the very last
thing I see.  There is no further output.

Our GRUB is using fancy graphics, so I wonder if that means that it has
switched to a mode that I simply can’t see over my serial connection.

Is there a way to make it start GRUB in text mode — and stay in text
mode throughout the installation?

--
Ricardo

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: GRUB and installer invisible on serial console
  2019-12-21 17:31 GRUB and installer invisible on serial console Ricardo Wurmus
@ 2019-12-21 19:00 ` Danny Milosavljevic
  2019-12-21 19:06   ` Danny Milosavljevic
       [not found] ` <634287529887714596f1f4ecdcbf8224@waegenei.re>
  1 sibling, 1 reply; 6+ messages in thread
From: Danny Milosavljevic @ 2019-12-21 19:00 UTC (permalink / raw)
  To: Ricardo Wurmus; +Cc: guix-devel

[-- Attachment #1: Type: text/plain, Size: 1068 bytes --]

Hi Ricardo,

> Our GRUB is using fancy graphics, so I wonder if that means that it has
> switched to a mode that I simply can’t see over my serial connection.

Yeah, gnu/bootloader.scm has "gfxterm" as default for the terminal output.
That means that serial will not be used.

Valid outputs are:

         '(console serial serial_0 serial_1 serial_2 serial_3
         gfxterm vga_text mda_text morse spkmodem)

see gnu/bootloader/grub.scm .
Multiple outputs are possible.

It's possible that serial-unit (a natural number (the com port) between 0 and 3)
and serial-speed (a natural number) also need to be set up in order to be able
to use "serial".

It's possible that there would have been an automatic UEFI console handover
in grub-efi but I guess it's being overridden by our setting.
Try having our bootloader config generator not emit "terminal_output" at all
(edit gnu/bootloader/grub.scm, search for "terminal_output" and comment that
part out).  It would be interesting whether it will automatically use a
reasonable default then.

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: GRUB and installer invisible on serial console
  2019-12-21 19:00 ` Danny Milosavljevic
@ 2019-12-21 19:06   ` Danny Milosavljevic
  2019-12-22 15:11     ` Danny Milosavljevic
  0 siblings, 1 reply; 6+ messages in thread
From: Danny Milosavljevic @ 2019-12-21 19:06 UTC (permalink / raw)
  To: Ricardo Wurmus; +Cc: guix-devel

[-- Attachment #1: Type: text/plain, Size: 574 bytes --]

Also, the Linux kernel console is something independent from grub.

To test that, try adding "console=ttyS0,115200" to the operating-system's
kernel-arguments.

Currently, Guix automatically set up a getty if it detects the
"console=ttyS0" argument in /proc/cmdline .  That is supposed
to ensure some reasonable console continuity, so as soon as the Linux
kernel has a console, the userspace is also supposed to use it automatically.

It might make sense to make our grub automatically add "console=ttyS0,115200"
to the Linux command line that it already emits.

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: GRUB and installer invisible on serial console
       [not found] ` <634287529887714596f1f4ecdcbf8224@waegenei.re>
@ 2019-12-21 19:30   ` Brice Waegeneire
  2019-12-30 18:40     ` Ludovic Courtès
  0 siblings, 1 reply; 6+ messages in thread
From: Brice Waegeneire @ 2019-12-21 19:30 UTC (permalink / raw)
  To: guix-devel, Guix-devel

On 2019-12-21 18:31, Ricardo Wurmus wrote:
> Hi Guix,
> 
> I just wanted to install Guix System on a server where I currently only
> have remote access via serial console — and which happens to have a 
> Guix
> USB stick stuck in its USB port.  I can see the system’s UEFI output 
> and
> see that it boots from USB, but “Welcome to GRUB!” is the very last
> thing I see.  There is no further output.
> 
> Our GRUB is using fancy graphics, so I wonder if that means that it has
> switched to a mode that I simply can’t see over my serial connection.
> 
> Is there a way to make it start GRUB in text mode — and stay in text
> mode throughout the installation?
> 
> --
> Ricardo

Hello Ricardo,

I got the same setup as you working some weeks ago with the following 
config.
I also had to tweak my BIOS settings to have a reliable serial 
connection.

--8<---------------cut here---------------start------------->8---
    (kernel-arguments
      '("quiet" "console=tty0" "console=ttyS0,115200"))

   (bootloader
     (bootloader-configuration
       (bootloader grub-efi-bootloader)
       (target "/boot/efi")
       (keyboard-layout keyboard-layout)
       (terminal-outputs '(gfxterm serial))
       (terminal-inputs '(console serial))
       (serial-unit 0)
       (serial-speed 115200)))
--8<---------------cut here---------------end--------------->8---

The order of the kernel argument "console=" is important because
« The last device will be used when you open /dev/console » [1].
And note that my baudrate is not 9600, the default value, because it's 
too slow
when displaying files. If you have a low quality serial link use the 
default.

I was wondering about writing a patch to make this kind of setup the 
default for
the image installer to allow installing Guix through a serial connection 
only.
Unfortunately such a setup will remove the current eye-candy GRUB theme.

#38580 may also interest you, it adds access to the BIOS settings from 
GRUB when
using UEFI.

[1]: 
https://www.kernel.org/doc/html/latest/admin-guide/serial-console.html
[2]: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=38580

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: GRUB and installer invisible on serial console
  2019-12-21 19:06   ` Danny Milosavljevic
@ 2019-12-22 15:11     ` Danny Milosavljevic
  0 siblings, 0 replies; 6+ messages in thread
From: Danny Milosavljevic @ 2019-12-22 15:11 UTC (permalink / raw)
  To: Ricardo Wurmus; +Cc: guix-devel

[-- Attachment #1: Type: text/plain, Size: 122 bytes --]

Also, try Linux kernel option "vga=off".  Linux is supposed to automatically use
the serial port if vga is unavailable.

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: GRUB and installer invisible on serial console
  2019-12-21 19:30   ` Brice Waegeneire
@ 2019-12-30 18:40     ` Ludovic Courtès
  0 siblings, 0 replies; 6+ messages in thread
From: Ludovic Courtès @ 2019-12-30 18:40 UTC (permalink / raw)
  To: Brice Waegeneire; +Cc: guix-devel, Guix-devel

Hello!

Brice Waegeneire <brice@waegenei.re> skribis:

> I also had to tweak my BIOS settings to have a reliable serial 
> connection.
>
>     (kernel-arguments
>       '("quiet" "console=tty0" "console=ttyS0,115200"))
>
>    (bootloader
>      (bootloader-configuration
>        (bootloader grub-efi-bootloader)
>        (target "/boot/efi")
>        (keyboard-layout keyboard-layout)
>        (terminal-outputs '(gfxterm serial))
>        (terminal-inputs '(console serial))
>        (serial-unit 0)
>        (serial-speed 115200)))

Should we add this to the OS in (gnu system install)?  Could someone
confirm that this has the desired effect?

Thanks,
Ludo’.

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2019-12-30 18:40 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-12-21 17:31 GRUB and installer invisible on serial console Ricardo Wurmus
2019-12-21 19:00 ` Danny Milosavljevic
2019-12-21 19:06   ` Danny Milosavljevic
2019-12-22 15:11     ` Danny Milosavljevic
     [not found] ` <634287529887714596f1f4ecdcbf8224@waegenei.re>
2019-12-21 19:30   ` Brice Waegeneire
2019-12-30 18:40     ` Ludovic Courtès

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).