Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/macos/8.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Macos 从终端MAC终止SSH_Macos_Ssh_Terminal - Fatal编程技术网

Macos 从终端MAC终止SSH

Macos 从终端MAC终止SSH,macos,ssh,terminal,Macos,Ssh,Terminal,我过去使用mac上的终端访问SSH到我的网站。然而,每次我试图打开终端时,我都会自动登录。我无法注销/退出以使用终端。它总是在壳里面 当我尝试退出、注销或ctrl+d时,它会注销,我得到一个[进程完成]。但是,我不能使用终端,当我按下任何键时都不会发生任何事情 所以我退出终端并重新启动它,我回到原点,登录到SSH。我想使用终端应用程序 我以前从未测试过它,但通过快速搜索,我找到了两篇文章,并且 第一篇文章提到了别名,它是ssh登录,而不使用远程服务器的密码。您可以尝试检查.bashrc文件中是否

我过去使用mac上的终端访问SSH到我的网站。然而,每次我试图打开终端时,我都会自动登录。我无法注销/退出以使用终端。它总是在壳里面

当我尝试退出、注销或ctrl+d时,它会注销,我得到一个[进程完成]。但是,我不能使用终端,当我按下任何键时都不会发生任何事情


所以我退出终端并重新启动它,我回到原点,登录到SSH。我想使用终端应用程序

我以前从未测试过它,但通过快速搜索,我找到了两篇文章,并且

第一篇文章提到了别名,它是ssh登录,而不使用远程服务器的密码。您可以尝试检查.bashrc文件中是否创建了别名,如果确实有别名,则将其删除

第二篇文章提到改变你的终端行为,这在你的情况下是最有可能的。本文提到,您可以检查默认的shell路径

检查外壳路径的步骤:

- Go to terminal and open preferences
- Under General tab, you will see 'Shells open with'
- If it is under default then you might want to check '/usr/bin/login' and '/bin/bash', if there is anything that run the above alias and remove it if there is.
- If it is under Command(complete path), then you might want to check the path, if there is anything that run the above alias and remove it if there is.

我重复一遍,我没有测试这个,因为我没有这个问题,但我希望这将帮助您解决您的问题。祝您度过愉快的一天。

通过登录服务器,您可以通过执行以下操作获得tty PID

ps ef

然后用kill,比如

杀死-9 PID


这将终止您和服务器之间的连接

是的,读过了,但没用。我还尝试用打开shell,但我仍然登录到shell。我对这件事一无所知。我遵循了如何连接到我的网站下载文件的指南。现在我被困在那里:S