Debian Minimal可通过SSH、VNC、xrdp等方式实现远程访问,以下是具体设置方法:
sudo apt update && sudo apt install openssh-server
sudo systemctl start ssh
sudo systemctl enable ssh
sudo ufw allow ssh # 允许默认22端口
/etc/ssh/sshd_config
,可调整端口、禁用root登录等(修改后需重启SSH服务):sudo nano /etc/ssh/sshd_config
sudo systemctl restart ssh
sudo apt install tightvncserver
vncserver :1 # 首次启动需设置密码
IP:5901
(默认端口5901)sudo apt install xrdp
sudo systemctl enable xrdp
sudo systemctl start xrdp
IP
即可sudo systemctl status ssh/vnc/xrdp
检查服务是否正常运行。