【问题标题】:Setting up SSH tunnel through GCE通过 GCE 建立 SSH 隧道
【发布时间】:2020-08-25 20:00:32
【问题描述】:

我正在按照此处的说明进行操作 https://cloud.google.com/community/tutorials/ssh-tunnel-on-gce 通过 Compute Engine 设置 SSH 隧道。我使用这个命令创建了一个计算实例:

gcloud compute instances create --zone us-west1-a tunnel 

这很好,然后我尝试运行命令在本地端口 5000 和 SSH 端口 22 上的机器上启动 SSH 隧道:

gcloud compute ssh --zone us-west1-a tunnel -- -N -p 22 -D localhost:5000

我收到以下错误:

【问题讨论】:

    标签: ssh google-cloud-platform google-compute-engine ssh-tunnel


    【解决方案1】:

    您使用的命令不适用于 Windows,只能用于 Linux。 CLI gcloud 在 Windows 上启动 putty.exe。查看等效命令行选项的 putty 文档并直接启动 putty.exe 而不是 CLI。对于 Windows,我建议改用 Windows 版本的 ssh.exe (OpenSSH)。

    Installation of OpenSSH For Windows Server 2019 and Windows 10

    【讨论】:

      猜你喜欢
      • 2015-05-05
      • 2023-04-02
      • 1970-01-01
      • 2018-05-02
      • 2020-09-17
      • 2011-03-31
      • 2016-03-27
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多