Skip to main content
Topic solved
This topic has been marked as solved and requires no further attention.
Topic: tty1 should start after boot and default bundles are finished. (Read 1144 times) previous topic - next topic
0 Members and 3 Guests are viewing this topic.

tty1 should start after boot and default bundles are finished.

I suggest creating a new bundle called getty or a new service called getty1 that depends on boot and default bundles.

This way, boot messages don't necessarily print over getty login prompt on tty1.

getty on tty1 starts too early. That's the problem.

OpenRC somehow starts getty on tty1 after all init services are started.
runit doesn't do so by default.

Re: tty1 should start after boot and default bundles are finished.

Reply #1
tty1 is intended to start as early as possible. It's a service provided by s6-linux-init which is deliberately enabled at compile time. I think it is good to have this because if you do something to completely wreck s6-rc (like mess up a symlink for example), you can still fix the machine without having to chroot or whatever.

The messages being printed on tty1 is a different compile flag that is also enabled. Technically, we could just not enable this flag and the logs would be caught in /run/uncaught-logs/ anyway, but however a user would not know if he/she had some sort of error unless they explicitly checked the logs. Seems like a drawback to me.

Are messages printing on tty1 really that much of a problem? My personal bootups are completely quiet (i.e. no message is displayed on the screen). By default, the s6-rc calls are not verbose and the vast majority of services have loggers to catch any output and prevent it from being written on /dev/console. If there's some service I'm not aware of that prints a bunch to the screen, I could also fix it. Another thing you could do is set /dev/console to a different location than /dev/tty1 (the default) via a kernel parameter.

 

Re: tty1 should start after boot and default bundles are finished.

Reply #2
Are messages printing on tty1 really that much of a problem? My personal bootups are completely quiet (i.e. no message is displayed on the screen). By default, the s6-rc calls are not verbose and the vast majority of services have loggers to catch any output and prevent it from being written on /dev/console. If there's some service I'm not aware of that prints a bunch to the screen, I could also fix it. Another thing you could do is set /dev/console to a different location than /dev/tty1 (the default) via a kernel parameter.

Enabling cryptboot-s6 results in the following tty1 mess.

Code: [Select]
Artix Linux 5.9.10-artix1-1 (tty1)

artixlinux login: Unlocking cryptboot
  WARNING: Failed to connect to lvmetad. Falling back to device scanning.
_(cursor)

Seeing this on every boot boggles my mind. Typing my user name over this message makes me feel ill. It decreased quality of my life.
It is not a login prompt. It is a mess. It killed the magical elegance.

I also discovered that redirecting /dev/console to tty8 prevents me from seeing LUKS passphrase prompt on tty1.
If console is on tty8, LUKS passphrase prompt appears on tty8.
I thought it took forever for LUKS to unlock, but LUKS passphrase prompt was on tty8.

I also don't like the fact that s6-linux-init takes care of tty1 instead of letting it run as an init service. Runit delegates all ttys and consoles to init services.

S6 is almost perfect although dependencies are a file instead of a directory. Anopa turned dependencies into a directory. Directory is easier to manage for package managers. A package can have a file in a directory. If a dependency is an empty regular file in a directory, I can add my own dependencies without interfering with package managers. If I wrote s6 init system, I would let an init service define the following directories: depend, depended, want, wanted, after, and before.
Allowing init services to define their own reverse dependencies can prevent init services from modifying each other. I don't like the fact that cryptboot-s6 modifies /etc/s6/sv/mount-filesystems/dependencies.

Re: tty1 should start after boot and default bundles are finished.

Reply #3

Seeing this on every boot boggles my mind. Typing my user name over this message makes me feel ill. It decreased quality of my life.
It is not a login prompt. It is a mess. It killed the magical elegance.

Is this a joke?

cryptsetup-s6 could be made quieter but anyways, the choices made for s6 are made for technical reasons. Having s6-linux-init's early getty service is technically better and has less points of failure than relying on the service manager so the main request of this thread is denied. If you want to complain about s6-rc's design feel free to take it up with the author. He's currently doing a rewrite at the moment.

Re: tty1 should start after boot and default bundles are finished.

Reply #4

Can you make it quieter?

I don't need to see

Code: [Select]
Unlocking cryptboot
  WARNING: Failed to connect to lvmetad. Falling back to device scanning.

on every boot. The warning is simply there because I didn't install lvm2-s6. If something has to hurt my sense of beauty by printing over tty1 login prompt, it should be a critical error that is not going to bother me on every boot in normal situations.






Re: tty1 should start after boot and default bundles are finished.

Reply #5
Seeing this on every boot boggles my mind. Typing my user name over this message makes me feel ill. It decreased quality of my life.
It is not a login prompt. It is a mess. It killed the magical elegance.
Is this a joke?
Hahahaha, I actually enjoyed that. Reminds me of a similar post I made at Arch's forum and a stick-up-his-ass moderator got actually offended.

1st world problems.

Re: tty1 should start after boot and default bundles are finished.

Reply #6
I am always greeted with:
Code: [Select]
lvmetad is being updated, retry for 10 more seconds.
While I'm not as horrified and disgusted as the other guy, it is disruptive and not very pretty, especially because it's not an error. I can of course just live with it though.

Re: tty1 should start after boot and default bundles are finished.

Reply #7
I pushed a new cryptsetup to testing which should be quieter.

I am always greeted with:
Code: [Select]
lvmetad is being updated, retry for 10 more seconds.
While I'm not as horrified and disgusted as the other guy, it is disruptive and not very pretty, especially because it's not an error. I can of course just live with it though.

I'm not sure where this message comes from exactly. Everything regarding lvm2 should be logged already. I guess it's possible the vgchange command in the cryptsetup script might trigger this which should hopefully be fixed now.