Subject: Re: "@" erases line, "#" erases previous character, serial console
To: None <netbsd-help@NetBSD.org>
From: Henry Nelson <netb@yuba.kcn.ne.jp>
List: netbsd-help
Date: 04/28/2006 06:22:58
On Thu, Apr 27, 2006 at 07:08:23PM +0200, Johnny Billquist wrote:
> I don't get it.
> What is the problem.

Sorry.  I found out things piecemeal.

The problem is:  that in a login name, and in a password, I use the
characters '#' and '@'.  Before I had the correct wscons configuration,
I could not login to that account from the console (ssh via the lan,
okay).  After correcting my wscons configuration, I could login, but
still if I press '@' at the login: prompt, the whole line is erased.
While I use "#" in the password, so I cannot actually see what happens
at the password prompt, if I type "#" at the login prompt, the character
before the cursor gets erased.

> First of all, is wscons really used if you have a serial console? I 

I think so.  (Look at /etc/wscons.conf: "# Screen 0 is already configured
as console in most cases.  #  Uncomment if a serial console is used.")
I have screen 0 uncommented.  Dmesg indicates that it is initiated.

In my original post, I mentioned that I had _both_ "console" _and_
"ttyE0" turned on in /etc/ttys.  I haven't had a chance to test yet,
but I think I will try turning off one or the other to see if that
doesn't correct things.  I also have a couple of sparc headless
servers that I will try it on (but cannot get to them any time soon).

> If the defaults are not what he wants, then it's just a question of 
> changing that.

But the defaults for "console", anyway, _are_ what I want if I interpret
stty's output correctly.  I'm not seeing that default while logging
in, only after I have logged in.

> If he thinks it is a problem that erase is bound to '#' only after 
> loggin in, and not while running the login program, well, then he should 

Other way around.  _After_ login things are fine.  It is _only_ at the
login: prompt that I *see* a problem.  However, once wscons was working
correctly, the login proceeded correctly, so even though I *see* the
login name disappear after typing "@", if I continue typing in the
user name, I can login (couldn't before I turned off autoconfig of
wscons in the kernel).

> that he shouldn't have erase bound to '#' after loggin in, then he 
> should just figure out where in the login processing that this is bound, 
> and change it there.

If I knew why only the login: prompt shows this quirk, I wouldn't
post.  :)  (Originally, before getting wscons corrected, I couldn't
even login via the console -- the reason I posted.)

> Getting back to wscons, can someone confirm wether wscons is used or not 
> on a serial console? (Once again, I thought it wasn't...)

I'd like to confirm, too.  (But how would you do that _before_ logging
in?  From root logged in via ssh?  What commands could I issue to check
whether console or ttyE0 is controlling the login?  TIA)

BTW, if it matters, the same client is used to login via the serial
console and the lan: TeraTerm.  This client does both tcp and serial.

-- 
henry nelson
  WWW_HOME=http://yuba.kcn.ne.jp/~home/

PS From the content of replies, I am wondering if my last post yesterday
   (JST) reached the list.  From here anyway, NetBSD.org was totally
   (either http or ftp) unreachable for about 6 hours from 6AM to noon.