系统版本:Ubuntu22.04桌面版
一:登录root用户关闭防火墙
sudo passwd root
systemctl stop ufw.service
systemctl disable ufw.service

二:开启ssh服务
sudo apt update
sudo apt install openssh-server
sudo systemctl start ssh
sudo systemctl status ssh
连接上WinSCP