ArchLinux open some records of ssh

2019-05-21 little problem encountered by
the company's test equipment version Linux archlinux 4.19.31-rt18-1-ARCH, but many features are removed. For example, ssh functions no test is very convenient. After installation, each update will not fall, so the record about here, easier to find.
First pacman -Sy opensshinstall OpenSSH , then systemctl start sshdopen the sshd service.

C:\Users\wannoo>ssh [email protected]
ssh: connect to host 192.168.10.250 port 22: Connection refused
C:\Users\wannoo>ssh [email protected]
The authenticity of host '192.168.10.250 (192.168.10.250)' can't be established.
ECDSA key fingerprint is SHA256:gt/ieUVNhwkw+JCt3MaBd1XDOx/M27ZW+R/u9l5QD50.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added '192.168.10.250' (ECDSA) to the list of known hosts.

But this time using FinalShell try to connect will always make a password; cmd into the command line of Windows attempts to connect, will always prompt Permission denied, please try again., even if your password is right, so be prompt.

C:\Users\wannoo>ssh [email protected]
[email protected]'s password:
Permission denied, please try again.
[email protected]'s password:
Permission denied, please try again.
[email protected]'s password:

Online search the next , I want to know the configuration /etc/ssh/sshd_configfile. There are original PermitRootLogin statement is a comment up #PermitRootLogin prohibit-password, so it is easy, no tools to install vi, just use echo statements appended to the final surface PermitRootLogin yes. Then systemctl restart sshdrestart the sshd service on it.

C:\Users\wannoo>ssh [email protected]
[email protected]'s password:
Last login: Mon Jun  3 01:22:52 2019 from 192.168.10.41
[root@archlinux ~]# whoami
root

Here remember what a complete, mainly on this a few:

pacman -Sy openssh    #安装
echo "PermitRootLogin yes" >> "/etc/ssh/sshd_config"    #修改配置表
systemctl start sshd    #开启
systemctl enable sshd    #开机启动
2286722-2763a6ded9864c26.png
Secure Shell

Reproduced in: https: //www.jianshu.com/p/9b97f7840bad

Guess you like

Origin blog.csdn.net/weixin_33882452/article/details/91153195