Bug 73942 - systemd-ask-password prompt gets visually interrupted by other messages
Summary: systemd-ask-password prompt gets visually interrupted by other messages
Status: RESOLVED MOVED
Alias: None
Product: systemd
Classification: Unclassified
Component: general (show other bugs)
Version: unspecified
Hardware: x86-64 (AMD64) Linux (All)
: medium minor
Assignee: systemd-bugs
QA Contact: systemd-bugs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-01-22 18:49 UTC by Max Liebkies
Modified: 2017-02-10 10:10 UTC (History)
9 users (show)

See Also:
i915 platform:
i915 features:


Attachments
Screenshot depicting distorted systemd-ask-password prompt (1.39 MB, image/jpeg)
2014-01-22 18:49 UTC, Max Liebkies
Details
dont overwrite crypt password prompt with status messages (1.25 KB, patch)
2014-05-05 14:36 UTC, Thomas Blume
Details | Splinter Review

Description Max Liebkies 2014-01-22 18:49:29 UTC
Created attachment 92601 [details]
Screenshot depicting distorted systemd-ask-password prompt

This is not really a bug that affects any crucial functionality but more of a visual thing.
I'm running Arch Linux with systemd 208 in the initrd with my root device encrypted using dm-crypt, without plymouth. At some point systemd asks for the password to unlock the root device on the console. After 1 or 2 seconds this prompt gets "newlined" and interrupted by several other systemd messages. Typing in the password and pressing Return to confirm it works as expected, however. 

I attached a screenshot (sorry for the quality) to illustrate the problem.
Comment 1 Zbigniew Jedrzejewski-Szmek 2014-02-23 14:47:37 UTC
Ooops, that seems to be a result of the recent changes to show more status.
Comment 2 mus.svz 2014-03-16 23:35:34 UTC
@Zbigniew: just to be clear, the reporter is running 208, so it must be happening for him because he is booting without "quiet" (afaik this has always behaved like that).

Either way, the problem with the recent changes to activate output after X seconds of waiting (210?) now causes this for people running _with_ "quiet" as well. systemd.show_status=0 is a workaround, but I guess in the long term there should be some kind of exception if a job is "hanging" because of password input.
Comment 3 Max Liebkies 2014-03-20 14:34:29 UTC
Yes, the problem persists with systemd-211, quiet doesn't help (which is by the way not what I want, I want to see boot time messages)

[Something else strikes me as odd, but I'm not sure if this is a completely new bug or this one. I was trying to use systemd-gpt-auto-generator within my initrd (i.e. no fstab, no crypttab, no root=) and I'm seeing a similar thing: I'm being asked for my password, the prompt is reprinted every 5 (or so) seconds. This time the bug effectively prevents me from booting my system. See this post: https://bbs.archlinux.org/viewtopic.php?pid=1394879 ]
Comment 4 Thomas Blume 2014-05-05 14:35:04 UTC
On my tests even a boot with systemd.show_status=0 overwrites the password prompt with unit startup messages.
Attaching a patch proposal to solve this.
Comment 5 Thomas Blume 2014-05-05 14:36:24 UTC
Created attachment 98491 [details] [review]
dont overwrite crypt password prompt with status messages

proposed patch
Comment 6 jvo 2014-10-06 20:49:20 UTC
Any updates on this? It's still happening with systemd-216.
Comment 7 mus.svz 2014-10-30 11:17:17 UTC
This was only partially fixed in 217. There is no more output while the password is being queried. But when booting with quiet, the "show status after x seconds of waiting" is still triggered right after entering the password and pressing enter.
Comment 8 Zbigniew Jedrzejewski-Szmek 2014-10-30 13:11:03 UTC
(In reply to mus.svz from comment #7)
> This was only partially fixed in 217. There is no more output while the
> password is being queried. But when booting with quiet, the "show status
> after x seconds of waiting" is still triggered right after entering the
> password and pressing enter.

That's basically a race condition, where systemd does not treat the removal of an ask-password entry as a event which bumps the timestamp of the last action. This can be added. However, an alternative implementation is being discussed on the mailing list (http://lists.freedesktop.org/archives/systemd-devel/2014-October/024717.html) so things are likely to change.
Comment 9 Lennart Poettering 2017-02-10 10:10:27 UTC
This is also tracked here:

https://github.com/systemd/systemd/issues/5123

Closing this here.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.