FOO.COM has two A records. and If I connect to ssh root@FOO.com then it sometimes can connect, sometimes it writes that there is a key mismatch, update known_hosts file. So I know that what is causing this (the two IP address behind the domain..).. but how can I resolve it? And:

-o StrictHostKeyChecking=no

no, this shouldn't be the solution :D

  • Are and on the same physical back-end server? – EightBitTony Jul 1 '13 at 11:28
  • and have different keys. – gasko peter Jul 1 '13 at 11:31
mv known_hosts known_hosts_old; ssh-keyscan FOO.com > known_hosts

it works

  • Won't that stop working the next time it gives you a different server? – Nick ODell Jul 1 '13 at 17:51
  • What gives me different server? Please clarify :\ :D later I restored my old known_hosts file, but put the ssh-keyscan line back – gasko peter Jul 2 '13 at 5:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.