You can edit sshd_config to change the port sshd listens on. The default directory for ssh configuration is /etc/ssh.
Backup the current configuration and use your favorite editor to change the Port line:
root@root [~]# cd /etc/ssh/
root@root [/etc/ssh]# cp sshd_config sshd_config.save
root@root [/etc/ssh]# vi sshd_config
#Port 22
I will set mine to port 4000. Do not forget to remove the comment (#).
Port 4000
root@root [/etc/ssh]# diff sshd_config sshd_config.save
13c13
< Port 4000
---
> #Port 22
root@root [/etc/ssh]#
Restart sshd and verify that it is listening on the new port.
root@root [/etc/ssh]# /etc/init.d/sshd restart
Stopping sshd: [ OK ]
Starting sshd: [ OK ]
root@root [/etc/ssh]# netstat -anp | grep sshd
tcp 0 0 0.0.0.0:4000 0.0.0.0:* LISTEN 1605/sshd
Subscribe to:
Post Comments (Atom)
Blog Archive
-
▼
2007
(117)
-
▼
November
(47)
- Install mod_python on cpanel server
- Identifying Process
- httpd segmenation Fault
- httpd issues , service started but sites not browsing
- View httpd , smtp other connections ( Unix )
- http and https site issues
- Set up VPN for UNix servers
- View Error Logs ( unix )
- View Server Info , Configs ( Unix )
- View IPs Causing attack
- How to open ports
- Install BIND or Named , wtih YUM
- Check mail logs for a particular Domain
- Block the IPs / for particular port
- full disk space issues ( Finding out the culprit )
- How to find out IPs trying to login to ssh
- ffmpeg installation error , partition remounted
- Exim load , finding email ID
- pure -ftpd , increase no . of dirctories viewable
- How to flush DNS in linux
- Disable ping on the server ( unix )
- Setting Index page ( Unix )
- Detect DDOS
- Exim Admin
- Direct Admin License Issues
- Cron Job
- Critical Namd Issue
- Mysql Admin
- Configure User Quota on a Plain server ( Unix )
- Command to change the Date ( Unix )
- checking error logs for a domain and httpd logs pl...
- Check and close your DNS servers ( unix )
- How To change the port ( SSH )
- CGI Issues not able to bowse the page
- Bind Configuration ERRor ( Named )
- Adding IPs on plain CentOS server ( Unix )
- High Traffic balance with this script ( Unix )
- IIS Tunning
- IIS Tweaking
- ERROR 2003: Can't connect to MySQL server on 'loc...
- Retrieve IUSER Password with this Script
- Reverse DNS lookup in Windows
- Server Application Error
- Server Performance Advisor ( Windows )
- Setting Up IPsecurity with ADSI ( Script )
- System Restore Windows
- Error while Removing Name serversfromWHM ICANN error
-
▼
November
(47)
No comments:
Post a Comment