From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <96078615810623.tru64-unix-managers.marc@archive.invalid> From: Paulo Gomes Date: Wed, 27 Aug 1997 12:26:00 +0000 To: tru64-unix-managers Subject: [Summary] Users cannot login: "no shell" or "no directory" X-MARC-Message: https://marc.info/?l=tru64-unix-managers&m=96078615810623 Thank you everyone for all the great responses. A problem description follows the solution. Solution: Due to the urgency of the situation, we had to get the system back up and running. We solved the problem by reinstalling....rocket scientist stuff! However I did try some of the suggestions in the little time I had. However I'm sure if given the time, one of the suggestions provided would have solved the problem. Most of the suggestions follow: Are you sure that your passwd file is fine -- what happened between things working and things not working? Is it only when you login via telnet -- or do you only login via telnet (console exception of course). May be you can login as a normal user on your console which is not telnet. If root logs in OK you may have a permission problem. I would recheck you passwd file has correct entires -- and check that the user has read and execute permissions down the WHOLE path to their home directories and shells. May be someone took read and execute away from others for /usr -- or something. ----------------------------------------------- The last time I saw something like this, someone (not me of course :) ) had changed the "execute" permissions on a directory in the path of the files needed by the user. If "execute" permission for "other" is removed on any directory in the user's path (like /bin , or /usr/bin, or for me / ) they are denied access to files beyond that point. You didn't mention checking permissions for directories, so I hope it is something this easy. ---------------------------------------------------------------------- do a whence to verify your path for the shell is correct (whence ksh, csh, sh) ------------------------------------------------------------------------ looks like you missed the users home directory. check the /etc/passwd file the entry for a user should be as following username::200:15::/usr/users/username:/bin/sh ------------------------------------------------------------------------ Make sure that the users home directory exists on the machine, and that ALL directories in the path are rx by everyone. (I once tried out an old version of COPS, which took away rx rights from /, and caused exactly these symptoms...) ----------------------------------------------------------------------- Check to make sure there are no spaces appended to the end of the line in password file that dentoes the user logging in. I've seen this error message before when a hidden character is embedded somewhere in the file e.g :- bloggsf:x:666:666:Fred Bloggs:/user/mfguser:/bin/sh if you vi the password file, go to the entry in the file and press you will see if there is a space appended to the end of the line. -------------------------------------------------------------------------- ----------------------- check it out the "/etc" directory and look for "nologin" file if you found it then remove it. Please read the "login" man about "nologin" file, so this file stop the users login. -------------------------------------------------------------------------- ----------------------- It sounds like maybe the permissions on the users shell are wrong. I.E. /bin/tcsh (or whatever) should be set to 755. Just a guess, hope it helps you out. -------------------------------------------------------------------------- ------------------- Problem: Hello managers, When users try to login via telnet they initially manage to login, then almost immediately after the login (/etc/motd) messages they bomb out with "connection closed by foreign host" message. If you try an rlogin it gives you a "no directory" message". If you try an "su username" it gives you a "no shell" message. If you try an "su - username" it gives you a "no directory" message. What the hell is happening. There was no /etc/shells file so we recreated it manually with the right permissions and ownerships. We have tried adding brand new users(with unique uids and all that) with adduser and then trying again. No luck. The /etc/passwd file seems just fine. Also checked that all the shells are there! By the way root can login fine! Any suggestions welcome. Thanks Paulo