Mongosh failed to authenticate with params

I want to login on running mongosh.

  • mongoshrc with auth script (like db.auth(“admin”, “adminpass”))
  • script with credentials (file like mongoshlocal with “mongosh --username admin --password adminPassword”)
  • mongosh with mongodb url like "mongosh “mongodb://admin:adminPassword@"”

Logs show that SCRAM auth failed, storedKey mismatch. AuthDB is “admin”, user “admin”

Are you supplying the correct password?
Does your password has any special characters?
Can you connect by any other tool like Compass?

Yes. I able to connect with Compass, with interactive login (running mongosh without credentials and using db.auth() function). I forgot, I’m running it on Linux (Debian 11), everything is up to date/