Score:0

On Ubuntu 20.04, unable to ssh to server, after upgrade from 18.04

it flag

After upgrading ubuntu from 18.04 to 20.04, unable to connect to host with my user

Below are the logs from auth.log

Mar 28 12:27:13 tpvm sshd[1590]: debug1: userauth-request for user XXXXX service ssh-connection method password [preauth]
Mar 28 12:27:13 tpvm sshd[1590]: debug1: attempt 2 failures 1 [preauth]
Mar 28 12:27:13 tpvm sshd[1590]: pam_unix(sshd:auth): authentication failure; logname= uid=0 euid=0 tty=ssh ruser= rhost=x.y.z.r  user=XXXXX
Mar 28 12:27:13 tpvm sshd[1590]: pam_ldap: could not open secret file /etc/ldap.secret (No such file or directory)
Mar 28 12:27:13 tpvm sshd[1590]: pam_ldap: ldap_search_s No such object
Mar 28 12:27:15 tpvm sshd[1590]: debug1: PAM: password authentication failed for XXXXX: Authentication failure
Mar 28 12:27:15 tpvm sshd[1590]: Failed password for XXXXX from x.y.z.r port 54880 ssh2

I had a VM with 18.04 running, with a specific user XXXXX. Password is set to the User(XXXXX). After upgrading to 20.04 LTS, I am unable to perform ssh to VM with XXXXX user and password. But after upgrade to 20.04, if I remove already configured password and re configure it again then ssh to VM with XXXXX user and password is working fine

Rishon JR avatar
pl flag
Try `sudo apt reinstall openssh-server`
Rishon JR avatar
pl flag
You can also follow this [article](https://kb.iu.edu/d/aews).
hr flag
This looks like a problem with either your PAM configuration or /etc/nsswitch.conf - are you intentionally using LDAP authentication or are you expecting it to use pam_unix?
warren avatar
vn flag
is your secondary sshd instance still running?
Shaik Musthafa avatar
it flag
HI @steeldriver, I am expecting it to use pam_unix. Can you pls provide me the correct PAM configuration and /etc/nsswitch.conf
Shaik Musthafa avatar
it flag
HI @warren, no ps -ef | grep sshd root 848 1 0 06:21 ? 00:00:00 sshd: /usr/sbin/sshd -D [listener] 0 of 10-100 startups root 1048 848 0 06:22 ? 00:00:00 sshd: XXXXX [priv] XXXXX 1171 1048 0 06:22 ? 00:00:00 sshd: XXXXX@pts/0 root 1221 1213 0 06:24 pts/0 00:00:00 grep --color=auto sshd
Shaik Musthafa avatar
it flag
I had a VM with 18.04 running, with a specific user XXXXX. Password is set to the User(XXXXX). After upgrading to 20.04 LTS, I am unable to perform ssh to VM with XXXXX user and password. But after upgrade to 20.04, if I remove already configured password and re configure it again then ssh to VM with XXXXX user and password is working fine
hr flag
@ShaikMusthafa please use the [edit] button to add this new information to your question
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.