"The Linux Gazette...making Linux just a little more fun!"

(?) The Answer Guy (!)

By James T. Dennis, tag@lists.linuxgazette.net
Starshine Technical Services, http://www.starshine.org/

(?) No Echo During Password Entry

From jdalbert on Wed, 04 Nov 1998

Hi Jim...I'm new to Linux and am trying to install Redhat version 5.1. I get as far as the keyboard password and my keyboard will not allow me to type any characters. It will allow me to tab or use the arrows but the keys do not move when pressed. I do not know who to ask for help and while browsing the linux site, I came across your name. Can you give me any advice as to how to get around the Root Password problem. Do I go into setup and check to see if I have Aami Bios and make changes? I'll look forward to hearing from you.

Thanks, Joe D'Albert

(!) If I understand you correctly -- you are just confused. The fact that the installation's prompt (dialog) for establishing the root password doesn't echo any characters, stars, nor even register/respond with cursor movements is PERFECTLY NORMAL. (It's a feature. It's supposed to work that way. Don't worry about it. Just type "blind").
It's going to ask you to repeat the password (any password you choose) twice. That's to ensure that you know what you typed. (The assumption is that you're unlikely to make the same typo or mistype twice in a row --- so if the two entries match one another, than you can probably manage to keep typing your password that way forever).
Note that it usually will do the same thing after you've got the whole system installed and configured. When you login, it will ask for a password.
When a Linux system prompts you for a password during login --- you won't see any characters or cursor movement as you type. This is intended to prevent someone from watching over your shoulder, even to find out how many characters are in your password.
Just type you password slowly and carefully. Make sure not to miss any keystrokes (by hitting the keys squarely) and make sure not to "bounce" the keys --- getting "double images" for some characters.
As long as you do that you should be fine.
I noticed that Lotus Notes used to respond to each keypress in the password prompt by echoing a small random number (2 to 5?) of *'s. This was a convenient way to give keyboard feedback without revealing your password length. Many systems will echo *'s for each character typed.
Incidentally the Linux passwords have NOTHING to do with any CMOS/Setup (BIOS) passwords that you may have on your system. Linux (and other forms of Unix) are multi-user systems. They maintain a list of accounts (in the /etc/passwd file) that provide for all access to the system.
The main benefit of this is that you can create a Joe account (joe, jdalbert or jda or ja or whatever reasonable login name you want to use). You normally long in under this account. While using your account you run very little risk of damaging any system files. If you run a "bad" program --- that program will usually be unable to damage the system (infect system binaries with a virus, for example).
You should only use the 'root' account for maintaining the system --- almost exclusively for adding new accounts, disabling old ones, and installing or upgrading your main system software.
You can use the 'passwd' command to change your password at any time. If you forget your personal (joe) password you can login as root and issue a command like 'passwd joe' to force a change on the password for any account on the system. (Thus, if you create an account for your wife, girlfriend, kid, roommate, dog, cat or whatever --- and they forget their password --- can't get it back for them, but you can just give them a new one). Read the 'passwd' and 'usermod' man pages for details on that and other tricks.
If you should ever lose the root password you can reboot the system (in single-user mode, or possibly you'll need a rescue diskette --- if 'sulogin' is configured).
If you've booted from diskette you'll have to mount the filesystems that you normally boot from (usually something like /dev/hda3 for a partition on your first IDE drive, or /dev/hdb1 for one on your 2nd IDE, or /dev/sda1 for one on your first SCSI drive). Let's say you mount that under /mnt/ (this is the floppy diskette's /mnt directory. Once you've done that you'd change (cd) into that directory, and use a command like 'chroot . /bin/sh' --- which essentially "locks you into" that (floppy's /mnt) directory as though it were the root directory.
(This process is a bit confusing --- but the purpose is to let you do the rest of these commands as though you'd booted from the hard drive in the first place. You could skip this step if you know how to issue all of the following commands while adjusting for the floppy/factor).
From there you can use a text editor on the /etc/passwd (and possibly the /etc/shadow) files, or you issue the 'passwd' command to force a change to 'root's password.
If you booted from floppy/rescue diskette, you'd now type "exit" (to exit from the 'chroot shell' that you invoked above). Then you'd unmount ('umount') the filesystems that you'd used and reboot.
(Note: If the last five paragraphs sounded confusing and intimidating --- take it as a warning: DON'T LOSE YOUR ROOT PASSWORD! You can recover from it, but you have to do some fussing. If you lose any other user's password, you can just log in as 'root' and do a forced change to fix it.).

Copyright © 1998, James T. Dennis
Published in The Linux Gazette Issue 35 December 1998

[ Answer Guy Index ] office largedisk links yamaha magickeys
passwd ftproot pvtmail netware crypto
relay project bootmethod sysadmin ipscript
loopfs mrtg slimscan rpm modutil libc dell remoteroot

[ Table Of Contents ] [ Front Page ] [ Previous Section ] [ Next Section ]