Internal network ip and external network ip

1. About the IP address

We usually have the most direct contact with the intranet IP. And you can also manually modify the ip address yourself. As for the external network ip, we seldom have direct contact, but only indirectly, because the external network ip is generally managed by the operator, and it is unique in the world, and generally we cannot modify it ourselves.

Intranet IP and extranet IP refer to the addresses used to identify computers or other devices in the network. The internal network IP refers to the IP address used in the local area network, and the external network IP refers to the IP address used in the public network.

Intranet IPs are usually assigned by routers or switches, and they are IP addresses in the private address space, such as 10.0.0.0/8, 172.16.0.0/12, and 192.168.0.0/16. These addresses are reserved exclusively for internal use and therefore cannot be accessed from the public network. Intranet IP can be shared in a LAN without the support of a public network. This means that private IPs can transfer data faster because they don't need to go through the public network's routers and servers.

External IP refers to the IP address used in the public network. These addresses are assigned by Internet Service Providers (ISPs), and they are globally unique. The external IP can be accessed through the public network, so it can be accessed from anywhere. This is because external IPs are globally unique and they are used to identify every device on the Internet. External IPs are necessary because they allow devices to communicate with each other on the Internet. For example, when you visit a website or send an email, your device needs to use an external IP address to communicate with other devices on the Internet.

Both internal IP and external IP are addresses used to identify a computer or other device, but they differ in use and access. The intranet IP can only be used in the local area network, while the external network IP can be accessed globally.

2. View the intranet ip address:

windows

ipconfig

linux

ifconfig

 

 3. View the external network address (exit ip address)

windows

Baidu search ip

linux

curl www.cip.cc

 

 

 4. What is it about others accessing us through the domain name, and what is the IP address corresponding to the domain name here?

For example, we publish the service to the production environment. The server will have an intranet ip address, so we provide it to others for access, and it must not be an intranet address. We need to provide a public IP address, and even bind the public IP to a domain name. So what is the public IP here?

 egress ip and ingress ip

  Generally speaking, accessing the services provided by others requires us to provide the other party with our export ip; when others access our services, we need the other party to provide us with the other party's export ip.

  The egress ip and the ingress ip are not necessarily the same address.

  1. Export ip

  Data packets whose destination address is the private network IP cannot be transmitted on the Internet. When the destination address is the public network ip and the source address (the address of the device that initiated the request) is the intranet, the data packet can reach the server smoothly, but the server cannot reply back with the response datagram (the destination address of the datagram replied by the server is the intranet address). Therefore, in order to enable the laptop/server on the intranet to access Internet resources normally, the network device will convert the request sent by the private network device to the external network ip.

When you need to cooperate with a third party, if you need to access the other party's services, you generally need to inform the other party of our export ip, so that the other party can authorize access.

  2. Entry ip

  The entry ip refers to that you, as the accessed end (server end), receive access from other people (client end). That is, which address is used by the client to access your service.

  It can be obtained by pinging the domain name.

  When you need to cooperate with a third party, if you need the other party to access your own service, you need to inform the other party of an accessible address. And authorize the other party's network device ip (the other party's export ip) to allow access to our services.

 

Guess you like

Origin blog.csdn.net/dongjing991/article/details/132277597