weird ssh login problem after backup-restore

roly

Verified User
Joined
Nov 9, 2006
Messages
182
hi

i recently moved my server using the directadmin backup-restore which went very simply and flawlessly - very impressed.

anyway when i login to ssh directly with root (temporarily allowed) or any other user acccount apart from admin it logins to server without a problem. however when i login with admin account with ssh putty closes the instant when i press enter for the password.

however i can use the admin and same password to login to directadmin just fine and i have tried resetting the admin password using passwd but same result.

when i initially restored the admin account i noticed that admin wasn't added to sshd_config so i added it manually:

AllowUsers admin

then restarted sshd

when i check /var/log/secure it says:

Mar 17 10:43:11 myhost sshd[20105]: Accepted password for admin from 66.26.172.181 port 63181 ssh2
Mar 17 10:43:11 myhost sshd[20105]: pam_unix(sshd:session): session opened for user admin by (uid=0)
Mar 17 10:43:11 myhost sshd[20105]: pam_unix(sshd:session): session closed for user admin

so as you can see ssh is accepting the password opening connection and then closing it again immediatly and only for admin. its something stupid i have or haven't done, it's not a firewall issue btw, has anyone got any ideas?

thanks in advance

roland
 
Last edited:
hi alex

thanks for your reply, typing that command i get:

/bin/false
/bin/bash
/bin/bash
/bin/bash
/bin/bash
/bin/bash
/bin/bash
/bin/bash
/bin/bash
/bin/bash

when i look at etc/passwd i find that admin is bin/false unlike the other accounts.

admin:x:501:502::/home/admin:/bin/false
admin2:x:503:504::/home/admin2:/bin/bash
admin3:x:504:505::/home/admin3:/bin/bash
admin4:x:505:506::/home/admin4:/bin/bash
admin5:x:506:507::/home/admin5:/bin/bash
admin6:x:507:508::/home/admin6:/bin/bash
admin7:x:508:509::/home/admin7:/bin/bash
admin9:x:509:512::/home/admin9:/bin/bash
admin8:x:513:522::/home/admin8:/bin/bash
admin10:x:514:503::/home/admin10:/bin/bash

i changed it to /bin/bash and it now works, thanks very much for your assistance. :)


roland
 
Back
Top