简体   繁体   中英

Installed different distro in Vagrant. Now can't SSH into MySQL

I was using Ubuntu precise32 and switched to 14.04. I use Jeffrey Way's setup ( https://github.com/JeffreyWay/Vagrant-Setup ) and that works. I can do 'vagrant ssh' and log in, and log into root with username/password root/root.

When I try using Sequel Pro for a GUI, I get the following error:

Used command:  /usr/bin/ssh -v -N -o ControlMaster=no -o ExitOnForwardFailure=yes -o ConnectTimeout=10 -o NumberOfPasswordPrompts=3 -i /Users/chrisfarrugia/.vagrant.d/insecure_private_key -o TCPKeepAlive=no -o ServerAliveInterval=60 -o ServerAliveCountMax=1 -p 2222 vagrant@127.0.0.1 -L 52688/127.0.0.1/3306 -L 52689/127.0.0.1/3306

OpenSSH_6.2p2, OSSLShim 0.9.8r 8 Dec 2011
debug1: Reading configuration data /etc/ssh_config
debug1: /etc/ssh_config line 20: Applying options for *
debug1: Connecting to 127.0.0.1 [127.0.0.1] port 2222.
debug1: fd 3 clearing O_NONBLOCK
debug1: Connection established.
debug1: identity file /Users/chrisfarrugia/.vagrant.d/insecure_private_key type -1
debug1: identity file /Users/chrisfarrugia/.vagrant.d/insecure_private_key-cert type -1
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_6.2
debug1: Remote protocol version 2.0, remote software version OpenSSH_6.6.1p1 Ubuntu-2ubuntu2
debug1: match: OpenSSH_6.6.1p1 Ubuntu-2ubuntu2 pat OpenSSH*
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: server->client aes128-ctr hmac-md5-etm@openssh.com none
debug1: kex: client->server aes128-ctr hmac-md5-etm@openssh.com none
debug1: SSH2_MSG_KEX_DH_GEX_REQUEST(1024<1024<8192) sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_GROUP
debug1: SSH2_MSG_KEX_DH_GEX_INIT sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_REPLY
debug1: Server host key: RSA 9d:7c:86:00:20:5a:ca:ef:a0:8a:01:c6:ad:34:cf:de
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@    WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED!     @
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
IT IS POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY!
Someone could be eavesdropping on you right now (man-in-the-middle attack)!
It is also possible that a host key has just been changed.
The fingerprint for the RSA key sent by the remote host is
9d:7c:86:00:20:5a:ca:ef:a0:8a:01:c6:ad:34:cf:de.
Please contact your system administrator.
Add correct host key in /Users/chrisfarrugia/.ssh/known_hosts to get rid of this message.
Offending RSA key in /Users/chrisfarrugia/.ssh/known_hosts:1
RSA host key for [127.0.0.1]:2222 has changed and you have requested strict checking.
Host key verification failed.

What am I doing incorrectly here? Here's a screenshot of my setup in Sequel Pro. 在此处输入图片说明

I found my answer. I had to remove the entry already in my known_hosts file for 127.0.0.1 and it worked after that.

The file is located at ~/.ssh/known_hosts

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM