modify the agetty prompt

roger21 roger21 at
Mon Jan 17 04:15:45 PST 2005

Rainer Peter Feller a écrit :
> On Mon, 2005-01-17 at 12:37 +0100, roger21 wrote:
>>Rainer Peter Feller a écrit :
>>>hm what about a
>>>S0:12345:respawn:/sbin/agetty -f /etc/issue.ttyS0 -L 115200 ttyS0 vt100
>>>in your /etc/inittab and a /etc/issue/ttyS0 of your gusto?
>>(ok i suppose i had to change all the parameters to match my classicals 
>>tty1-6 and focussing on the issue file thing)
>>the issue file doesn't influence the actual agetty login prompt, it just 
>>displays a (interpreted) message *before* the actual agetty login prompt
>>(i tried your line anyway, modifying ttyS0 with tty1 and with an empty 
>>issue.tty1 the result is the hostname information is still dispalyed)
>>now perhaps you are using this line on a non-linux machine and it's 
>>working as i wish (it means without the hostname information) because in 
>>the source code of agetty.c the lines dispalying the hostname 
>>information are enclosed in a #ifdef __linux__ / #endif
>>i am completly sure hacking the source code is the only way to get what 
>>i want: first of all because the login message " login: " is 
>>hard-specified in the code (without gettext) so it is the only way to 
>>change it to "Login:" or to "give me your login now !!" and then this 
>>hostname information porely displayed here is also hard-coded in the 
>>source (whereas it can be much better managed and displayed with the 
>>issue file)
>>i hope i didn't misunderstood your answer
> hm ... strange ... I use this at my lfs ... and yes it works, if my ttuS0 is
> empty I just get the prompf of the login proces (no, that is NOT agetty!!)
> and it displays "$HOSTNAME login:"

this is actually what i want to change (and yes it IS agetty ;) the 
login process is called once agetty got the /login/ and called the login 
  process with this information)

this is may login prompt now: "Login: "

> ah I suppose that you know that you have to do a "telinit Q" to make
> init reread the /etc/inittab yes?

no i didn't know, i rebooted instead, so thank you

More information about the lfs-support mailing list