In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/01 Report--
This article mainly introduces how to install telnet under Linux, has a certain reference value, interested friends can refer to, I hope you can learn a lot after reading this article, the following let the editor take you to understand it.
The telnet command is usually used for remote login. Telnet program is a remote login client program based on TELNET protocol. Telnet protocol is a member of TCP/IP protocol family, and it is the standard protocol and main way of Internet remote login service.
Installation
Open the terminal and enter the following command to install telnet:
Yum install telnet telnet-server-y
Now telnet is installed on your server. Next, edit the file / etc/xinetd.d/telnet:
Vi / etc/xinetd.d/telnet
Set disable = no:
# default: on# description: The telnet server serves telnet sessions; it uses\ # unencrypted username/password pairs for authentication.service telnet {flags = REUSE socket_type = stream wait = no user = root server = / usr/sbin/in.telnetd log_on_failure + = USERID disable = no}
Save and exit the file. Remember, we don't have to do this in CentOS 7.
Next, restart the telnet service with the following command: on the CentOS 6.x system:
Service xinetd start
Let the service start every time it is restarted:
On CentOS 6:
Chkconfig telnet onchkconfig xinetd on
On CentOS 7:
Systemctl start telnet.socketsystemctl enable telnet.socket
Allow the default port 23 of telnet to pass through the firewall and router. To make the telnet port accessible through the firewall, edit the following file on the CentOS 6.x system:
Vi / etc/sysconfig/iptables
Add the following line "- An INPUT-p tcp-m state-state NEW-dport 23-j ACCEPT":
# Firewall configuration written by system-config-firewall# Manual customization of this file is not recommended.*filter:INPUT ACCEPT [0:0]: FORWARD ACCEPT [0:0]: OUTPUT ACCEPT [0:0]-An INPUT-m state-- state ESTABLISHED RELATED-j ACCEPT-An INPUT-p icmp- j ACCEPT-An INPUT-I lo-j ACCEPT-An INPUT-p tcp-m state-- state NEW-- dport 23-j ACCEPT-An INPUT-m state-- state NEW-m tcp-p tcp-dport 22-j ACCEPT-An INPUT-j REJECT-- reject-with icmp-host-prohibited-A FORWARD-j REJECT-- reject-with icmp-host-prohibitedCOMMIT
Save and exit the file. Restart the iptables service:
Service iptables restart
In CentOS 7, run the following command to allow the telnet service to pass through the firewall.
Firewall-cmd-permanent-add-port=23/tcpfirewall-cmd-reload
okay. The telnet service is now available for use.
Create a user
Create a test user, such as the user name "sk" and the password "centos":
Useradd skpasswd sk client configuration
Install the telnet package:
Yum install telnet
In DEB-based systems:
Sudo apt-get install telnet
Now, open the terminal and try to access your server (remote host). If your client is a Linux system, open the terminal and enter the following command to connect to the telnet server.
Telnet 192.168.1.150
Enter the username and password that has been created on the server: sample output:
Trying 192.168.1.150...Connected to 192.168.1.150.Escape character is'^] '.Kernel 3.10.0-123.13.2.el7.x86_64 on an x86_64server1 login: skPassword: [sk@server1 ~] $
As you can see, the remote host has been successfully accessed locally. If your system is windows, go to start-> run-> Command prompt. At the command prompt, enter the command:
Telnet 192.168.1.150
192.168.1.150 is the remote host IP address. Now you can connect to your server. okay.
Thank you for reading this article carefully. I hope the article "how to install telnet under Linux" shared by the editor will be helpful to everyone. At the same time, I also hope you will support us and pay attention to the industry information channel. More related knowledge is waiting for you to learn!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.