ssh 包含指令不起作用

标签 ssh openssh sequelpro

所以 ssh 通过控制台/终端可以正常工作,但是当我使用 MySQL 数据库客户端 (Sequel Pro) 时,它似乎以某种方式使用了不同的 ssh 版本,因此 include 指令不起作用。它声明它正在使用正确的 SSH 版本,但它是否在协议(protocol)期间的某个时刻切换?

OpenSSH_7.5p1, OpenSSL 1.0.2l  25 May 2017
debug1: Reading configuration data /Users/me/.ssh/config
debug1: Reading configuration data /Users/me/.ssh/devops
debug1: Reading configuration data /Users/me/.ssh/defaults
debug1: /Users/me/.ssh/defaults line 4: Applying options for *
debug1: /Users/me/.ssh/defaults line 76: Applying options for ch-pre-bastion
debug1: /Users/me/.ssh/defaults line 80: Applying options for ch-pre-*
debug1: Reading configuration data /usr/local/etc/ssh/ssh_config
debug1: Control socket " none" does not exist
debug1: Executing proxy command: exec ssh gateway@52.33.83.63 -W 52.33.83.63:22
debug1: permanently_drop_suid: 502
debug1: identity file /Users/me/.ssh/id_rsa type 1
debug1: key_load_public: No such file or directory
debug1: identity file /Users/me/.ssh/id_rsa-cert type -1
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_7.5
/Users/me/.ssh/config: line 1: Bad configuration option: include
/Users/me/.ssh/config: line 2: Bad configuration option: include
/Users/me/.ssh/config: terminating, 2 bad configuration options
ssh_exchange_identification: Connection closed by remote host

最佳答案

您的机器上可能安装了更多的 SSH 版本,并且来自代理命令的版本可能正在选择旧版本,没有 Include 支持。

debug1: Executing proxy command: exec ssh gateway@52.33.83.63 -W 52.33.83.63:22

尝试找到 ssh 二进制文件的完整路径,并在 ProxyCommand~/.ssh/config 中使用它,或者只使用 ProxyJump 选项,应该选择正确的 ssh instance`。

关于ssh 包含指令不起作用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/45556195/

相关文章:

php - 没有 SSH 访问权限的 Symfony 2

python - 使用 Python Paramiko 在不同的 SSH 服务器中并行运行多个命令

git - 获取有关 Gerrit 更改的最新 refspec

bash - 如何在 ssh 命令行中使用环境模块?

git push 在 bash 中使用 ssh-agent 而不是 gui

mysql - 使用 Sequel Pro 创建和链接数据库

mysql - 当两个值匹配时使用 JOIN 更新 mySQL 表

scp - 使用 scp 命令时出错 "bash: scp: command not found"

php - 在 MySQL 中安全地存储密码,但仍可通过 PAM 访问

mysql - Sequel Pro - 如何阅读 Ö、ü、ç、ñ、ß 等字符