Ubuntu开启或重启ssh服务

开启ssh服务首先需要安装打开ssh服务的库:

sudo apt-get install openssh-server

检查当前的ssh开启情况:

ps -e |grep ssh

如果有sshd,则ssh-server已经启动;若仅有agent,则尚未启动;
开启ssh服务:

/etc/init.d/ssh start

若为启动或者希望重启ssh,则修改配置并重启ssh服务:

vi /etc/ssh/sshd_config

则可以看到配置文件,按照需求修改即可;
重启ssh:

sudo /etc/init.d/ssh restart
---------------------
作者:韩湘
来源:CSDN
原文:https://blog.csdn.net/qq_38228254/article/details/78543840
版权声明:本文为博主原创文章,转载请附上博文链接!

posted @ 2019-06-02 07:41  西伯利亚虎  阅读(4137)  评论(0编辑  收藏  举报

Permanence, perseverance and persistence in spite of all obstacles, discouragements and impossibilities: It is this, that in all things distinguishes the strong soul from the weak.