①mac OS High Sierra(ver.10)上に以下の仮想環境を構築し、
config -> database.ymlファイル内で定義したdatabaseをmysql内に作成完了しました。
・Vagrant
・CentOS7
・Rails(5.2.1)
・MySQL(8.0)
②その後、sequel pro(最新ver)と仮想環境上のmysqlとを接続したいのですが、
ssh connection failed と出てしまいます。
恐れ入りますが、
こちらの解決方法についてお力添えお願いします。
ssh connection failed → Show detail 後の内容
Used command: /usr/bin/ssh -v -N -S none -o ControlMaster=no -o ExitOnForwardFailure=yes -o ConnectTimeout=10 -o NumberOfPasswordPrompts=3 -o TCPKeepAlive=no -o ServerAliveInterval=60 -o ServerAliveCountMax=1 -p 22 vagrant@192.168.33.12 -L 58267:127.0.0.1:3306 OpenSSH_7.6p1, LibreSSL 2.6.2 debug1: Reading configuration data /etc/ssh/ssh_config debug1: /etc/ssh/ssh_config line 48: Applying options for * debug1: Control socket " none" does not exist debug1: Connecting to 192.168.33.12 [192.168.33.12] port 22. debug1: fd 6 clearing O_NONBLOCK debug1: Connection established. debug1: key_load_public: No such file or directory debug1: identity file /Users/ucchie/.ssh/id_rsa type -1 debug1: key_load_public: No such file or directory debug1: identity file /Users/ucchie/.ssh/id_rsa-cert type -1 debug1: key_load_public: No such file or directory debug1: identity file /Users/ucchie/.ssh/id_dsa type -1 debug1: key_load_public: No such file or directory debug1: identity file /Users/ucchie/.ssh/id_dsa-cert type -1 debug1: key_load_public: No such file or directory debug1: identity file /Users/ucchie/.ssh/id_ecdsa type -1 debug1: key_load_public: No such file or directory debug1: identity file /Users/ucchie/.ssh/id_ecdsa-cert type -1 debug1: key_load_public: No such file or directory debug1: identity file /Users/ucchie/.ssh/id_ed25519 type -1 debug1: key_load_public: No such file or directory debug1: identity file /Users/ucchie/.ssh/id_ed25519-cert type -1 debug1: Local version string SSH-2.0-OpenSSH_7.6 debug1: Remote protocol version 2.0, remote software version OpenSSH_7.4 debug1: match: OpenSSH_7.4 pat OpenSSH* compat 0x04000000 debug1: Authenticating to 192.168.33.12:22 as 'vagrant' debug1: SSH2_MSG_KEXINIT sent debug1: SSH2_MSG_KEXINIT received debug1: kex: algorithm: curve25519-sha256 debug1: kex: host key algorithm: ecdsa-sha2-nistp256 debug1: kex: server->client cipher: chacha20-poly1305@openssh.com MAC: <implicit> compression: none debug1: kex: client->server cipher: chacha20-poly1305@openssh.com MAC: <implicit> compression: none debug1: expecting SSH2_MSG_KEX_ECDH_REPLY debug1: Server host key: ecdsa-sha2-nistp256 SHA256:mSCvmtL4tXdna8dyNdV3xFOveU+rbNrmZpHszodfnxI debug1: Host '192.168.33.12' is known and matches the ECDSA host key. debug1: Found key in /Users/ucchie/.ssh/known_hosts:5 debug1: rekey after 134217728 blocks debug1: SSH2_MSG_NEWKEYS sent debug1: expecting SSH2_MSG_NEWKEYS debug1: SSH2_MSG_NEWKEYS received debug1: rekey after 134217728 blocks debug1: SSH2_MSG_EXT_INFO received debug1: kex_input_ext_info: server-sig-algs=<rsa-sha2-256,rsa-sha2-512> debug1: SSH2_MSG_SERVICE_ACCEPT received debug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic debug1: Next authentication method: publickey debug1: Trying private key: /Users/ucchie/.ssh/id_rsa debug1: Try![イメージ説明](998f541a650ac4a49411b817f5b4131e.png)ivate key: /Users/ucchie/.ssh/id_dsa debug1: Trying private key: /Users/ucchie/.ssh/id_ecdsa debug1: Trying private key: /Users/ucchie/.ssh/id_ed25519 debug1: No more authentication methods to try. vagrant@192.168.33.12: Permission denied (publickey,gssapi-keyex,gssapi-with-mic).
試したこと
SSH Host名とMysql Host名を同一にしてみたりも試しましたが、
現在のSSH Host名(192〜)に合わせると同様なエラー文言が出て、
現在のMysql Host名(127~)に合わせるとThe SSH Tunnel has unexpectedly closed. というエラーがでました。
追記
Sequel Proでのエラー詳細
Used command: /usr/bin/ssh -v -N -S none -o ControlMaster=no -o ExitOnForwardFailure=yes -o ConnectTimeout=10 -o NumberOfPasswordPrompts=3 -o TCPKeepAlive=no -o ServerAliveInterval=60 -o ServerAliveCountMax=1 -p 3000 vagrant@127.0.0.1 -L 60031:127.0.0.1:3306 -L 60032:127.0.0.1:3306 OpenSSH_7.6p1, LibreSSL 2.6.2 debug1: Reading configuration data /etc/ssh/ssh_config debug1: /etc/ssh/ssh_config line 48: Applying options for * debug1: Control socket " none" does not exist debug1: Connecting to 127.0.0.1 [127.0.0.1] port 3000. debug1: connect to address 127.0.0.1 port 3000: Operation timed out ssh: connect to host 127.0.0.1 port 3000: Operation timed out
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。
2018/09/17 04:07