Solve the problem of blocked Linode SSH port and use Launch Lish Console to modify the port problem

888u

Last update at :2024-06-16,Edit by888u

Today Snail met a netizen who told him that a VPS host at a Linode merchant could not log in to SSH, but the websites inside could be opened normally, and asked him to help solve this problem. There are two possibilities. One possibility is that the SSH port is blocked, because some time ago I saw a similar article and some netizens reported that the VPS host SSH port was blocked, and then modifying the port can solve this problem.

Here Snail records the process of solving the problem. If there are similar problems, you can follow them to solve them, but it is not the only way to solve it, because different problems may be different. It is just that this problem is solved by this method. of. (Because other problems have been recorded before, but some netizens followed suit and it did not solve the problem)

First, log in to the server through Launch Lish Console

According to the given SSH ROOT account information, it is true that I have no way to log in remotely, so I can directly use the Launch Lish Console in the Linode panel to log in, which is similar to what we call the VNC function that comes with the server, but the panel is called differently. Just different.

As shown above, Remote Access – Launch Lish Console. After clicking the link, you can see a similar WEB SSH interface.

Normally we log in with the root username and password we set initially and then log in.

Second, modify the SSH port/close iptables

Snail shared an article on modifying the SSH port in CentOS7 a few days ago (CentOS7 method of modifying the SSH port of a Linux server), but this friend seems to be using CentOS6, so this method is not enough, and the CentOS6 method must be used. However, the snail wants to try here. It may not be that the port is blocked, but it may be that iptables is not open or fails after being opened, causing port problems.

So I directly stopped iptables in Launch Lish Console and tried it.

service iptables stop

Then I tried to log in through the local client SSH, and it was indeed possible to log in. It seems that there is no problem with this port. It may be that this friend did not save the port in iptables at first, and then the server restarted and it became invalid. Then there is no need to modify the SSH port here, just add the port to iptables. (Because iptables will be started after restarting the server, or we can shut it down completely)

Third, set up and open a custom SSH port

/sbin/iptables -I INPUT -p tcp –dport 54321 -j ACCEPT/etc/rc.d/init.d/iptables save/etc/rc.d/init.d/iptables restart

Because this friend uses CentOS6 system, it is different from CentOS7. Add his customized port settings, then save and restart so that it will take effect. If we do not save and restart, the server will be unable to connect if it is restarted.

Fourth, check whether the port exists

/etc/init.d/iptables status

We can restart the server and then try to see if the local client can connect via SSH. If it is confirmed that there is no problem, then the problem is solved.

In summary, it is the same as other VPS and servers. If you encounter similar problems, it may be because the port is blocked, or the set port is not saved and becomes invalid. We can just reset it.

Recommended site searches: website registration process, query whether a domain name is registered, check IP detailed address, independent IP space, Hong Kong virtual host space, foreign server rental price, AAA server, free cloud server, online IP check, Japanese proxy server IP ,

Solve the problem of blocked Linode SSH port and use Launch Lish Console to modify the port problem

All copyrights belong to 888u unless special state
取消
微信二维码
微信二维码
支付宝二维码