联系我们:416326801#qq.com(#改成@)

img1

CentOS7修改SSH端口提示error: Bind to port

818 Views

vi /etc/ssh/sshd_config
Port 10000
semanage port -l|grep ssh  
semanage port -a -t ssh_port_t -p tcp 10000
semanage port -l|grep ssh  
/bin/systemctl restart  sshd.service

出现如下提示,可以关闭SELlinux或者执行semanage port -a -t ssh_port_t -p tcp 10000

Jan 23 17:02:10 localhost.localdomain systemd[1]: Starting OpenSSH server dae...
Jan 23 17:02:10 localhost.localdomain sshd[14030]: error: Bind to port 10000 ...
Jan 23 17:02:10 localhost.localdomain sshd[14030]: error: Bind to port 10000 ...
Jan 23 17:02:10 localhost.localdomain sshd[14030]: Server listening on 0.0.0....
Jan 23 17:02:10 localhost.localdomain sshd[14030]: Server listening on :: por...
Jan 23 17:02:10 localhost.localdomain systemd[1]: Started OpenSSH server daemon.


如果觉得我的文章对您有用,打赏一下呗.

wxpay.png