Current location - Quotes Website - Collection of slogans - I want to know the function of the port number in the website.
I want to know the function of the port number in the website.
The function of port number is mainly to distinguish business categories and conduct multiple sessions at the same time.

For example, there is a host A that needs to provide FTP and

WWW two services, if there is no port number.

In other words, there is no difference between the two services. In fact, when a host B on the network needs to access the FTP service of A, it needs to specify the destination port number as 21; When you need to visit A's WWW service, you need to set the destination.

The port number is set to 80. At this point, A can distinguish two different requests of B according to the port number accessed by B ... This is the role of port number in distinguishing service categories.

Another example: Host A needs to download to the network at the same time.

Two files on FTP server B, and then A needs

At the same time, two sessions are established with B, and the two transmission sessions are distinguished by the source port number. In this case, if there is no concept of source port number, then A cannot distinguish which meeting the data returned by B belongs to.

Word, which file belongs to. The actual communication process is that A uses the local port 1025 to request the file 1 on the port 2 1 of B, and at the same time uses the port 1026 to request the file 2. For the returned number

It is reported that it was returned to port 1025, so it is considered as file1; Those that return to port 1026 are considered to belong to document 2. This is the role of port numbers to distinguish multiple sessions.

The port number ranges from 1 to 65535. Total * * * is divided into two categories:

(1) Port number used by the server.

Among them, 1 ~ 1024 is designated by RFC 3232 and is called "well-known port" or system port number; The value of1024 ~ 49151is called the registered port number. This port number is suitable for applications that are unfamiliar with port numbers. (Traveler Gong Zhong.No.: Pumpkin Carriage Gang. )

Some common port numbers and their usage are as follows:

TCP 2 1 port: FTP file transfer service.

TCP 23 port: TELNET terminal emulation service

TCP 25 Port: SMTP Simple Mail Transfer Service

UDP 53 port: DNS domain name resolution service

TCP 80 port: HTTP hypertext transfer service

TCP 1 10 Port: the port used by POP3 post office protocol-Version 3.

TCP 443 port: HTTPS encrypted hypertext transfer service.

TCP 152 1 port: Oracle database service.

TCP 1863 port: the port used by the file transfer function of MSN Messenger.

TCP 3389 port: the port used by Microsoft RDP Microsoft Remote Desktop.

TCP 563 1 port: the port used by Symantec pcAnywhere to remotely control data transmission.

UDP 5632 port: the port used by Symantec pcAnywhere master terminal to scan the controlled terminal.

TCP 5000 port: the port used by MS SQL Server.

UDP 8000 port: Tencent QQ

(2) Port number used by the client

The value is 49 152~65535. This port number will be dynamically selected only when the client process is running, which is also called temporary port number. When the communication between the client and the server using this port number ends, its port number no longer exists and can be used by other client processes in the future.