Bug 12786

Summary: Systemd spawns two getty processes when the getty port is set to console
Product: buildroot Reporter: Adam Duskett <aduskett>
Component: OtherAssignee: unassigned
Status: RESOLVED DUPLICATE    
Severity: major CC: aduskett, buildroot
Priority: P5    
Version: 2020.02.1   
Target Milestone: 2020.05   
Hardware: All   
OS: Linux   
Host: Target:
Build:

Description Adam Duskett 2020-04-18 01:17:44 UTC
Very straight forward.

When systemd is selected as the init system, and BR2_TARGET_GENERIC_GETTY_PORT is set to console, two gettys are spawned which prevents a user from logging in.

How to reproduce:

make qemu_x86_64_defconfig
menuconfig -> System configuration -> Init system -> systemd
make

Then run the resulting image.
Comment 1 Matt Weber 2020-04-18 21:40:23 UTC
 I can confirm I see similar with aarch64 build using master.  I noticed it is possible to login and run commands you just have to keep escaping the new getty :-)
Comment 2 Adam Duskett 2020-04-19 18:53:07 UTC
After I did a quick google search I found a post on stack exchange that indicates this has been an issue since at least version 2019.02!

https://unix.stackexchange.com/questions/566959/how-to-prevent-console-getty-service-to-start

The logic behind /dev/console in systemd.mk is a bit complex and I am not sure where to start.
Comment 3 Thomas Petazzoni 2020-05-16 14:29:34 UTC
I have Jérémy Rosen to have a look, see http://lists.busybox.net/pipermail/buildroot/2020-May/282962.html. I must say the logic in systemd.mk is very confusing, and the comment above it doesn't help understand what's going on.
Comment 4 Thomas Petazzoni 2020-05-19 21:39:26 UTC

*** This bug has been marked as a duplicate of bug 12361 ***