Home >Operation and Maintenance >Linux Operation and Maintenance >What does port mean in linux
In Linux, port is the outlet for communication between the device and the outside world. It is often used to refer to the port in the "TCP/IP" protocol. Ports can be divided into recognized ports, registered ports and dynamic ports according to the port number.
#The operating environment of this tutorial: linux7.3 system, Dell G3 computer.
The definition of port:
The system program running on the computer is like a closed circle. The system programmer cuts this circle into many Segments, these line segment interfaces are called ports (popularly speaking, they are breaks, or interruptions). When the system runs to these ports, it depends on whether the port is open or closed. If it is closed, the rope is connected, and the system runs downward. If the port is open , the system gets the command, has external data input, accepts the external data and executes it.
Port classification:
The port occupies two bytes in the header, which is 16 bits. Port numbers are used to represent and distinguish different applications on the network.
Ports are divided into three categories:
(1) Well Known Ports: Port numbers between 0-1023. These ports are allocated and managed by IANA. IANA assigns these ports to the most important applications to let all users know that when a new application appears, IANA must assign it a recognized port.
Commonly used recognized ports are:
FTP : 21
TELNET : 23
SMTP : 25
DNS : 53
TFTP: 69
HTTP: 80
SNMP: 161
(2) Registered Ports: from 1024-49151. It is a port number registered by companies and other users with the Internet Corporation for Assigned Names and Numbers (ICANN). Application software that uses the Internet's Transmission Control Protocol (TCP) and User Datagram Protocol (UDP) to communicate needs to use these ports. In most cases, these applications can be opened by unprivileged users just like normal programs.
(3) Port numbers used by the client: 49152~65535. This type of port number is only dynamically selected when the client process is running, so it is also called a short-lived port number. Reserved for client processes to choose for temporary use. It can also be understood that when the client starts, the operating system randomly allocates a port to communicate with the server. When the client process is closed and opened next time, a new port is reassigned.
The port is like a door. The outside world can communicate with the processes of different services on the machine through different ports. The IP address and port number identify the only process that accesses the Internet host
Related recommendations: "Linux Video Tutorial"
The above is the detailed content of What does port mean in linux. For more information, please follow other related articles on the PHP Chinese website!