How to change SSH port on Linux server (SELinux)

google-image.jpg

 

To change SSH port on SELinux enabled Linux server, do the following steps:

  1. Login to the server via SSH.
  2. Open SSH config file using vi /etc/ssh/sshd_config
  3. Edit the file, remove "#" from SSH port line #Port 22 and change the default port (example: Port 2454)
  4. Now run semanage port -a -t ssh_port_t -p tcp PORTNUMBER
  5. Add the new SSH port in the firewall
  6. Now restart the sshd service using service sshd restart
  • SSH, SSHport, port, SELinux, Linux, security
  • 2 Uživatelům pomohlo
Byla tato odpověď nápomocná?

Související články

WHMCS Default Emails Sent Settings

This blog can help you to understand the default WHMCS Email settings when users create accounts....

How to check nameservers of my website

Dear Customer,Please follow the below steps to check the nameservers of your website.Open...

How to create ticket for support in client area

Hello   To create a ticket first you should log in to https://clients.activeservers.in/ Go...

Screen access for remote support

To access the customer's machine we are using Quick assist. To install a Quick Assist please...

Back up option for your hosting

Hello All,We all know the value of our data. Companies generate/gather website data with lots...