Ubuntu 系统中开启ssh.service 服务 SSH 服务端
你现在已经是 root 用户,不需要加 sudo。
root
sudo
执行:
apt update apt install openssh-server -y
安装完成后执行:
systemctl enable --now ssh
systemctl status ssh
如果看到:
Active: active (running)
就表示 SSH 已经成功启动。