Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
console login prompt misbehaving
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
josephg
l33t
l33t


Joined: 10 Jan 2016
Posts: 663

PostPosted: Tue Jan 09, 2018 5:23 pm    Post subject: console login prompt misbehaving Reply with quote

i have had this strange issue for months now.. can't remember when this started. it's not really stopping me from anything, but someone once told me that i should not overlook any issues.

my login prompt looks like this:
Code:
[press ENTER to login]

[press ENTER to login]

[press ENTER to login]

i see the --login-pause prompt correctly. i press enter, and see a blank newline. i press enter again, and the --login-pause prompt appears. this cycle repeats.

if i enter my username at the blank newline, the login and password prompts appear together on the next line. it looks like this:
Code:
[press ENTER to login]
josephg
hostname login: Password:

where i can enter my password and login successfully.

however, if i type a wrong password, it starts behaving properly:
Code:
[press ENTER to login]
josephg
hostname login: Password:

Login incorrect
hostname login: josephg
Password:


have you seen something like this before?
_________________
"Growth for the sake of growth is the ideology of the cancer cell." Edward Abbey


Last edited by josephg on Tue Jan 09, 2018 5:58 pm; edited 1 time in total
Back to top
View user's profile Send private message
khayyam
Watchman
Watchman


Joined: 07 Jun 2012
Posts: 5534
Location: Room 101

PostPosted: Tue Jan 09, 2018 5:56 pm    Post subject: Reply with quote

josephg ...

have you perhaps "flipped" the pam useflag on some package? You might look to see what has pam enabled/disabled:

Code:
# eix --only-names --exact --installed-with-use pam
# eix --only-names --exact --installed-without-use pam

As login is part of sys-apps/util-linux you might re-merge this, have you gone through the 17.0 profile update, and was @system rebuilt?

best ... khay
Back to top
View user's profile Send private message
josephg
l33t
l33t


Joined: 10 Jan 2016
Posts: 663

PostPosted: Tue Jan 09, 2018 6:13 pm    Post subject: Reply with quote

hey khay, i think it was actually you who told me not to ignore even minor issues :) that was a while back

why would you suspect pam? there doesn't seem to be any security/login issues. it seems to be a prompt/display/newline/something issue..

Code:
# eix --only-names --exact --installed-with-use pam
app-admin/doas
app-admin/sudo
app-emulation/virtualbox
dev-libs/cyrus-sasl
net-mail/mailbase
net-misc/dropbear
net-print/cups
sys-apps/kbd
sys-apps/openrc
sys-apps/shadow
sys-apps/util-linux
sys-libs/libcap
# eix --only-names --exact --installed-without-use pam
sys-apps/busybox
jgv@a300-2c2:~ $ eix busybox
[I] sys-apps/busybox
     Available versions:  1.25.1^t ~1.26.2-r1^t ~1.27.2^t **9999^t {debug ipv6 livecd make-symlinks math mdev pam savedconfig selinux sep-usr static syslog systemd}
     Installed versions:  1.25.1^t(14:20:22 23/12/17)(syslog -debug -ipv6 -livecd -make-symlinks -math -mdev -pam -savedconfig -selinux -sep-usr -static -systemd)
     Homepage:            https://www.busybox.net/
     Description:         Utilities for rescue and embedded systems


khayyam wrote:
As login is part of sys-apps/util-linux you might re-merge this

i rebuilt that few days ago, as i changed some flags. login prompt issue has been outstanding for months.

khayyam wrote:
have you gone through the 17.0 profile update, and was @system rebuilt?

yes i updated to 17.0 profile early december, and rebuilt @system and @world. i had to do that a few times as i had to reboot in between. this login prompt issue has been there since before that.


Last edited by josephg on Tue Jan 09, 2018 9:08 pm; edited 1 time in total
Back to top
View user's profile Send private message
josephg
l33t
l33t


Joined: 10 Jan 2016
Posts: 663

PostPosted: Tue Jan 09, 2018 6:16 pm    Post subject: Reply with quote

is there someway i could check which packages have not been emerged after a particular date?
Back to top
View user's profile Send private message
khayyam
Watchman
Watchman


Joined: 07 Jun 2012
Posts: 5534
Location: Room 101

PostPosted: Tue Jan 09, 2018 8:54 pm    Post subject: Reply with quote

josephg wrote:
hey khay, i think it was actually you who told me not to ignore even minor issues :) that was a while back

josephg ... and hey back ... don't remember saying that but yes :)

josephg wrote:
why would you suspect pam? there doesn't seem to be any security/login issues. it seems to be a prompt/display/newline/something issue.

Not pam, but specifically "flipping" the pam useflag ... which is "DANGEROUS" ...

euse -i pam | grep -i dangerous:
[+  D   ] pam - Add support for PAM (Pluggable Authentication Modules) - DANGEROUS to arbitrarily flip

... hence my question about "flipping". Anyhow, there was recently a sys-libs/readline update, and a .so change, and 'revdep-rebuild' required a number of package rebuilds (one of which was sys-apps/util-linux), that is the only thing I can think of that might effect the login prompt. That said, in the past I seem to remember an issue when someone had a typo in /etc/inittab that also caused some issue with login, and of course there is everything login depends on:

Code:
% ldd /bin/login
    linux-gate.so.1 (0xb7749000)
    libpam.so.0 => /lib/libpam.so.0 (0xb772a000)
    libpam_misc.so.0 => /lib/libpam_misc.so.0 (0xb7725000)
    libc.so.6 => /lib/libc.so.6 (0xb755f000)
    libdl.so.2 => /lib/libdl.so.2 (0xb755a000)
    /lib/ld-linux.so.2 (0xb774a000)


josephg wrote:
khayyam wrote:
have you gone through the 17.0 profile update, and was @system rebuilt?

yes i updated to 17.0 profile early december, and rebuilt @system and @world. i had to do that a few times as i had to reboot in between. this login prompt has been there since before that.

Oh, ok, so this isn't something recent ... that makes the cause harder to pinpoint.

josephg wrote:
is there someway i could check which packages have not been emerged after a particular date?

Not that I know of, it's difficult to target 'not emerged', 'qlop -Cl' will provide a list of merges, perhaps you can sort through those.

Just a thought, when you did the 13.x => 17.0 profile update did you provide --keep-going, were there any failed builds?

HTH & best ... khay
Back to top
View user's profile Send private message
josephg
l33t
l33t


Joined: 10 Jan 2016
Posts: 663

PostPosted: Tue Jan 09, 2018 9:28 pm    Post subject: Reply with quote

khayyam wrote:
specifically "flipping" the pam useflag ... which is "DANGEROUS" ...

thanks, i don't remember flipping pam.. atleast not consciously

khayyam wrote:
Anyhow, there was recently a sys-libs/readline update, and a .so change, and 'revdep-rebuild' required a number of package rebuilds (one of which was sys-apps/util-linux), that is the only thing I can think of that might effect the login prompt.

i rebuilt them both on the same day last week, prompted by update. i don't remember seeing any revdep-rebuild messages, and have not run that recently. perhaps i will run that now... update: system is consistent

khayyam wrote:
That said, in the past I seem to remember an issue when someone had a typo in /etc/inittab that also caused some issue with login

my init is openrc-init ;) no inittab there.. lol

khayyam wrote:
and of course there is everything login depends on:

mine almost matches yours
Code:
$ ldd /bin/login
        linux-gate.so.1 (0xb77d4000)
        libpam.so.0 => /lib/libpam.so.0 (0xb77aa000)
        libpam_misc.so.0 => /lib/libpam_misc.so.0 (0xb77a5000)
        libc.so.6 => /lib/libc.so.6 (0xb75dd000)
        libdl.so.2 => /lib/libdl.so.2 (0xb75d8000)
        /lib/ld-linux.so.2 (0xb77d5000)


khayyam wrote:
Just a thought, when you did the 13.x => 17.0 profile update did you provide --keep-going, were there any failed builds?

i have --keep-going in make.conf. so yes, it continued.. there were some builds which failed and i had to reboot a few times. and then i would restart from scratch, as emerge won't remember which ones were recently recompiled.

so i did a convoluted script to list everything compiled after a particular date and compared that list to all packages extracting the uniq ones to recompile again. i think i have successfully rebuilt everything again.

and after all that hoopla, now i'm using ccache happily. wonder why i never bothered with it. the freebsd guys swear by it.
Back to top
View user's profile Send private message
khayyam
Watchman
Watchman


Joined: 07 Jun 2012
Posts: 5534
Location: Room 101

PostPosted: Tue Jan 09, 2018 11:02 pm    Post subject: Reply with quote

josephg wrote:
khayyam wrote:
That said, in the past I seem to remember an issue when someone had a typo in /etc/inittab that also caused some issue with login

my init is openrc-init ;) no inittab there.. lol

josephg ... very breifly ... ok, well how are you starting getty? Have you tried with init=/sbin/init (and so excluding openrc-init as a potencial culprit)?

josephg wrote:
khayyam wrote:
Just a thought, when you did the 13.x => 17.0 profile update did you provide --keep-going, were there any failed builds?

i have --keep-going in make.conf. so yes, it continued.. there were some builds which failed and i had to reboot a few times. and then i would restart from scratch, as emerge won't remember which ones were recently recompiled.

You said this issue started prior to 17.0 so I think we can rule this out.

best ... khay
Back to top
View user's profile Send private message
josephg
l33t
l33t


Joined: 10 Jan 2016
Posts: 663

PostPosted: Wed Jan 10, 2018 1:25 am    Post subject: Reply with quote

khayyam wrote:
josephg wrote:
khayyam wrote:
That said, in the past I seem to remember an issue when someone had a typo in /etc/inittab that also caused some issue with login

my init is openrc-init ;) no inittab there.. lol

very breifly ... ok, well how are you starting getty?

openrc-init does not use inittab. afaik agetty is hardcoded, or i would mingetty. ttys are started as agetty.tty1 agetty.tty2 etc services, configured in /etc/conf.d/agetty.tty1 and so on. "rc-update add agetty.tty1 default" etc.

khayyam wrote:
Have you tried with init=/sbin/init (and so excluding openrc-init as a potencial culprit)?

that's a thought.. i will try soon as i can reboot.
Back to top
View user's profile Send private message
josephg
l33t
l33t


Joined: 10 Jan 2016
Posts: 663

PostPosted: Wed Jan 10, 2018 3:28 am    Post subject: Reply with quote

ok i think i have identified the culprit.. my agetty options and a very particular one at that too
Code:
--login-pause


login prompt garbles only if i use this option, whether openrc or sysvinit, whether any other options alongside or not.

and i don't know when this started happening.. probably much earlier as testing with sysvinit made me realise that i was using mingetty since forever.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum