SecureCRT 登录 Debian 失败,常见原因和排查办法可以按下面顺序来:
SecureCRT 登录失败时一般会提示类似:
你先看是哪一种,下面分别说。
systemctl status ssh
如果没开:
sudo systemctl start ssh
sudo systemctl enable ssh
sudo nano /etc/ssh/sshd_config
确认:
PasswordAuthentication yes
PermitRootLogin prohibit-password # 或 yes
改完重启:
sudo systemctl restart ssh
sudo ufw status
如果开了,允许 22:
sudo ufw allow 22
sudo如果你用 key 登录:
cat id_rsa.pub >> ~/.ssh/authorized_keys
chmod 600 ~/.ssh/authorized_keys
Debian 12 默认禁用老算法,老客户端会失败。
在 /etc/ssh/sshd_config 加(不推荐长期):
KexAlgorithms +diffie-hellman-group1-sha1
Ciphers +aes128-cbc
然后:
sudo systemctl restart ssh
⚠️ 更安全做法是升级 SecureCRT。
ss -tlnp | grep :22
ping 你的IP
ssh localhost
如果你愿意,可以把 SecureCRT 的具体报错截图或文字 发我,我可以直接告诉你缺哪一步。