Technoracle
    Facebook Twitter Instagram
    • Sitemap
    • Privacy Policy
    • Disclaimer
    • Term of Services
    Facebook Twitter Instagram Pinterest Vimeo
    TechnoracleTechnoracle
    • Tutorials
      • Amazon Cloud
      • Google Cloud
    • How To
    • Blog
    • About
    Subscribe
    Technoracle
    Home»How To»How to Change SSH Port in Linux Easily
    How To

    How to Change SSH Port in Linux Easily

    Rajesh ShivamBy Rajesh ShivamJune 5, 2021No Comments2 Mins Read
    Share Facebook Twitter Pinterest LinkedIn Tumblr Reddit Telegram Email
    Change SSH Port in Linux
    Share
    Facebook Twitter LinkedIn Pinterest Email
    Change SSH Port in Linux

    By default, most of the web server’s SSH port is 22 such as AWS, Digital Ocean. By changing the SSH port of any Linux server, you can tighten the security of the server. In this, tutorial, I am going to change SSH port in Linux easily.

    Change SSH Port in Linux Easily

    You can easily change SSH port in Linux systems. You can use ports ranging from 0 to 65535. The port number 0 is reserved and cannot be used. The default SSH service listen on port 22. Just this port with some other ports.

    To change and update SSH port, edit OpenSSH configuration file

    $ sudo vi /etc/ssh/sshd_config

    In the configuration file, search for port 22 . When you find port 22, uncomment the port and replace it with some other nonstandard port (let’s take 2220.) Now save the config file.

    Search for
    Port 22
    
    Replace with
    Port 2220

    Now, restart the SSH daemon to apply changes.

    $ sudo systemctl restart ssh 

    Awesome, your ssh server login port has been changed successfully.

    Access the Server with New SSH Port

    As the SSH daemon is running under non-standard port, you have to mention port number with the command-

    $ ssh -p 2220 [email protected]

    Conclusion

    In this short tutorial, you have learned to change SSH port in linux. If you have any doubts feel free to contact me, I will definitely try to help you. Also, you can join our elite Facebook group to get direct help from me. If you like this tutorial, please share this article on your social media handle

    linux security ubuntu tips
    Share. Facebook Twitter Pinterest LinkedIn Tumblr Email
    Previous ArticleHow to Attach Static IP to AWS Lightsail Instance Easily
    Next Article How to Install Zabbix Agent on Ubuntu 20.04 Easily
    Rajesh Shivam

    Hello, everyone, I am Rajesh Shivam, I am a full-time freelancer with more than seven years plus experience in different freelancing platforms, in this blog, I am going to provide complete freelancing tips and tricks.

    Related Posts

    How To

    How to Install Microsoft Teams on Ubuntu 22.04 Easily

    February 22, 2023
    Read More
    How To

    What is Elastic IP and Its Pricing in AWS

    February 22, 2023
    Read More
    How To

    How to Convert PEM to PPK file [Step by Step Guide]

    February 22, 2023
    Read More
    Add A Comment

    Leave A Reply Cancel Reply

    Facebook Twitter Instagram Pinterest
    © 2023 Technoracle

    Type above and press Enter to search. Press Esc to cancel.

    Go to mobile version