Subject: alpine-virt*.iso: i think COM1 port declared in /etc/inittab never used in real life

From: Kuzin Andrey <[email-masked]>
Date: Thu, 30 Jan 2020 09:50:58 +0300

Hello !

I use alpine-virt-3.11.3-x86_64.iso version in my VirtualBox projects and very happy. Thanks for all !

But after start the virtual machine file /var/log/messages filling by the messages:

=====================
Jan 30 06:19:03 localhost daemon.info init: process '/sbin/getty -L 0 ttyS0 vt100' (pid 8193) exited. Scheduling for restart.
Jan 30 06:19:03 localhost daemon.info init: starting pid 8203, tty '/dev/ttyS0': '/sbin/getty -L 0 ttyS0 vt100'
Jan 30 06:19:03 localhost auth.err getty[8203]: tcgetattr: I/O error^M
Jan 30 06:19:13 localhost daemon.info init: process '/sbin/getty -L 0 ttyS0 vt100' (pid 8203) exited. Scheduling for restart.
Jan 30 06:19:13 localhost daemon.info init: starting pid 8204, tty '/dev/ttyS0': '/sbin/getty -L 0 ttyS0 vt100'
Jan 30 06:19:13 localhost auth.err getty[8204]: tcgetattr: I/O error^M
Jan 30 06:19:23 localhost daemon.info init: process '/sbin/getty -L 0 ttyS0 vt100' (pid 8204) exited. Scheduling for restart.
Jan 30 06:19:23 localhost daemon.info init: starting pid 8209, tty '/dev/ttyS0': '/sbin/getty -L 0 ttyS0 vt100'
Jan 30 06:19:23 localhost auth.err getty[8209]: tcgetattr: I/O error^M
Jan 30 06:19:33 localhost daemon.info init: process '/sbin/getty -L 0 ttyS0 vt100' (pid 8209) exited. Scheduling for restart.
Jan 30 06:19:33 localhost daemon.info init: starting pid 8210, tty '/dev/ttyS0': '/sbin/getty -L 0 ttyS0 vt100'
Jan 30 06:19:33 localhost auth.err getty[8210]: tcgetattr: I/O error^M
Jan 30 06:19:43 localhost daemon.info init: process '/sbin/getty -L 0 ttyS0 vt100' (pid 8210) exited. Scheduling for restart.
Jan 30 06:19:43 localhost daemon.info init: starting pid 8211, tty '/dev/ttyS0': '/sbin/getty -L 0 ttyS0 vt100'
Jan 30 06:19:43 localhost auth.err getty[8211]: tcgetattr: I/O error^M
======================

In file /etc/inittab one line about ttyS0 is commented, but someone add new line at the end
==================================
# Put a getty on the serial port                                                                                                                                                            
#ttyS0::respawn:/sbin/getty -L ttyS0 115200 vt100                                                                                                                                           
# enable login on alternative console                                                                                                                                                       
ttyS0::respawn:/sbin/getty -L 0 ttyS0 vt100
==================================

Anybody use COM port in Virtual Machines ? For example in virtual hosting or docker containers, except in special cases ?!
I never hear about that.

May be this line is really unneeded in base ISO file.

Every time i call [vi /etc/inittab] and comment this line for my systems.

---

From: Nero <[email-masked]>
Date: Thu, 30 Jan 2020 08:52:05 +0000

Hi,

> But after start the virtual machine file /var/log/messages filling by the messages:

I did. It seems quite reasonable to me if you have a host system that you
interface via SSH.

I also used the ttyS0 interface in the past to automate testing the
Alpine installer.

> May be this line is really unneeded in base ISO file.

If we remove the console=ttyS0 part from the kernel command line, no getty
will spawn and the system will only be accessible via the monitor. This
breaks all headless setups, since you can't re-add the console=ttyS0 later
via serial.

> Every time i call [vi /etc/inittab] and comment this line for my systems.

I understand this is inconvenient for you, but if we remove it, we will
replace the inconvenience for you with broken usecases for others.

If you are working via monitor, you can press tab at the isolinux boot and
remove that string from the kernel command line. If its not in the kernel
command line, it will also not be included into the inittab.

As a persistent solution, you might build your own iso without that kernel
boot parameter per default.

Previous discussion:
https://gitlab.alpinelinux.org/alpine/aports/issues/9324

For the future, maybe it should be considered to ship an separate ISO
flavour for use via serial. 

--
Nero