linux - Change the default port(22) SSh [CENTOS] -


i trying change d default port (22) system, edited sshd_config file changing desirable port no (5555) , restarted service seem not work . there else have change? thanks

yes, must allow new port in iptables. iptables firewall program linux.

with root privileges need this:

iptables -i input 1 -p tcp  --dport 5555 -j accept   

make sure can connect using port 5555 disable old port.

iptables -a input -j drop -p tcp --dport 22 

then save new settings

/etc/init.d/iptables save 

check out webpage more information:

http://www.rackspace.com/knowledge_center/article/introduction-to-iptables#save_save_save_your_ruleset


Comments

Popular posts from this blog

c# - How to get the current UAC mode -

postgresql - Lazarus + Postgres: incomplete startup packet -

angularjs - ng-repeat duplicating items after page reload -