Bug#977562: systemd: Incorrect order of agetty arguments in serial-getty at ttyS0.service definition file
Michael Biebl
biebl at debian.org
Wed Dec 16 22:39:06 GMT 2020
Am 16.12.20 um 20:49 schrieb MK:
> Package: systemd
> Version: 241-7~deb10u5
> Severity: normal
>
> Goal: enabling serial communication over null modem cable between two Debian 10 hosts.
>
>
>
> Steps to reproduce:
>
> 1. Connect null-modem cable to both machines.
>
> 2. Edit /etc/default/grub:
>
> GRUB_CMDLINE_LINUX="console=tty0 console=ttyS0,115200n8"
> GRUB_TERMINAL=console
>
> (update-initramfs -u of course)
>
> 3. Enable serial systemd service:
>
> # systemctl enable serial-getty at ttyS0.service
>
> 4. Reboot.
>
>
>
> Expected result:
>
> Serial comm works, command used:
>
> tio -f soft /dev/ttyS0
>
>
>
> Actual results:
>
> tio or minicom spit out garbage characters.
>
>
>
> Cause:
>
> Incorrect order of arguments to agetty in the serial-getty at ttyS0.service
> unit file.
>
> It is:
>
> ExecStart=/sbin/agetty --autologin root -8 --keep-baud 115200,38400,9600 ttyS0 xterm-256color
>
>
> While it should be like:
>
> ExecStart=/sbin/agetty --autologin root -8 --keep-baud ttyS0 115200 xterm-256color
>
>
> Note: order of port and baud rate is reversed. man agetty says it should
> be:
>
> agetty [options] port [baud_rate...] [term]
>
> In the default service definition baud rate PRECEDES port.
>
> After using my config line above serial commuication works fine.
>
>
>
> agetty [options] port [baud_rate...] [term]
>
> In the default service definition baud rate PRECEDES port.
>
> After using my config line above serial commuication works fine.
According to the examples in man agetty, both should work.
Andreas, can you comment here?
If what MK is saying, should the "EXAMPLE" section in man agetty be updated?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_signature
Type: application/pgp-signature
Size: 840 bytes
Desc: OpenPGP digital signature
URL: <http://alioth-lists.debian.net/pipermail/pkg-systemd-maintainers/attachments/20201216/898a5024/attachment.sig>
More information about the Pkg-systemd-maintainers
mailing list