补充 sudo.

Signed-off-by: chen.yang <chen.yang@yuzhen-iot.com>
This commit is contained in:
chen.yang 2021-09-15 16:06:01 +08:00
parent 9fe938d9e8
commit f63fe2456b
1 changed files with 7 additions and 7 deletions

View File

@ -15,9 +15,9 @@ published: true
```bash
# Ubuntu
apt-get install openssh-server
sudo apt install openssh-server
# Manjaro
pacman -S openssh
sudo pacman -S openssh
```
## 开启 SSH 服务
@ -122,19 +122,19 @@ UsePAM yes
```bash
# 开机自运行
systemctl enable sshd.service
sudo systemctl enable sshd.service
# 启动 sshd 服务
systemctl start sshd.service
sudo systemctl start sshd.service
# 查看 sshd 服务状态
systemctl status sshd.service
sudo systemctl status sshd.service
# 或ubuntu12
/etc/init.d/ssh restart
sudo /etc/init.d/ssh restart
```
如果没有 systemd可以使用如下命令
```bash
service ssh start
sudo service ssh start
```
## SSH 登陆