Huasan Cup H3C Network Knowledge Study Notes (1)

Easy-to-understand IP address, subnet mask, default gateway, DNS server
https://blog.csdn.net/belongtocode/article/details/106453395
This article understands network knowledge, IP, subnet mask, gateway, DNS , port number
https://zhuanlan.zhihu.com/p/65226634

Diagram| It turns out that this is the network

https://www.cnblogs.com/flashsun/p/14266148.html

IP address, subnet mask, default gateway, DNS server details

https://www.cnblogs.com/JuneWang/p/3917697.html

H3C

New H3C Group

As a leader in digital solutions, New H3C Group is committed to becoming a trustworthy partner for customers in business innovation and digital transformation. As a core enterprise under Tsinghua Unigroup, H3C has continuously improved the level of digital and intelligent empowerment through the in-depth layout of the entire industry chain of "cloud-network-computing-storage-end". New H3C has comprehensive digital infrastructure capabilities in computing, storage, network, 5G, security, and terminals, and provides comprehensive solutions including cloud computing, big data, artificial intelligence, industrial Internet, information security, intelligent connection, and edge computing. One-stop digital solutions, and end-to-end technical services. At the same time, H3C is also the exclusive provider of HPE® servers, storage and technical services in China.

New H3C Group has been deeply involved in the industry for decades, and has always been customer-oriented, providing scenario-based solutions to support the digitalization of various industries such as operators, government, finance, medical care, education, transportation, manufacturing, electric power, energy, Internet, and construction. Transformation practices, products and solutions are widely used in more than 100 countries and regions.

New H3C Group insists on taking technological innovation as the engine of development. At present, R&D personnel account for more than 50%, and the total number of patent applications exceeds 13,800, of which more than 90% are invention patents. Facing the broad opportunities in the development of the digital economy, New H3C Group has comprehensively deepened the "cloud intelligence native" strategy, upgraded the "digital brain", empowered the digital transformation and transformation of all industries, and continued to help customers realize in the development process: smarter business Decision-making (Smart), more timely business response (Timely), more agile business deployment (Agile), more reliable business assurance (Reliable), and a safer business environment (Safe).

"Integrating the digital future and sharing a better life" is the corporate vision of H3C Group. Facing the future, H3C will work with customers and partners to create a better life for everyone.
## Mainstream enterprises and their operating systems
Cisco Cisco IOS

Huawei VRP

H3C COMWARE

Internet unit:

Bit----bit a binary

Storage unit:
1000bit=1Kbit
1000Kbit=1Mbit
1000Mbit=1Gbit
1000Gbit=1Tbit
1000Tbit=1Pbit

Rate unit:
100Mbps
Byte-----byte 8 binary is equal to one byte
1000B=1KB
1000KB=1MB
1000MB=1GB
1000GB=1TB
100MBps—transfer 100M bytes of data in one second

The different bases are 1024 1000, so the memory will change (is there only 1000 in the eyes of programmers, not 1024)

互联网单位:
Bit----比特 一个二进制 
存储单位:
1000bit=1Kbit 
1000Kbit=1Mbit
1000Mbit=1Gbit
1000Gbit=1Tbit
1000Tbit=1Pbit
速率单位:100Mbps 
Byte-----字节 8个二进制等于一个字节
1000B=1KB
1000KB=1MB
1000MB=1GB
1000GB=1TB
100MBps---一秒钟传递100M字节的数据

Web 1.0

Identification: address
Addressing protocol: IPV4 IPV6 NSAP apple talk novell …
IPV4-----uses 32 binary digits for identification
Writing method: dotted decimal

Example: 192.168.1.1 255.255.255.0

(Supplementary) Web1.0 Web2.0 Web3.0 difference

  1. Web 1.0
    stands for:

Static pages

Traditional newspapers

Yahoo

Thinking content:

platform creation

All platform

platform control

Platform benefits

We can refer to the traditional newspapers and magazines for the original static web pages of the Internet. The newspaper office employs editors and reporters, and then the reporter will record what happened in the city and send it to the newspaper office, and the editor of the newspaper office will publish the content of the article on the newspaper, and then sell it for users to watch.

From the above examples, we can easily see that both editors and reporters belong to the newspaper. That is to say, the content on the newspaper is created by the newspaper office, and the ownership of its creation also belongs to the newspaper office. At the same time, the management control over how to manage the distribution and sales of the newspaper also belongs to the newspaper office, and the income from selling newspapers also belongs to the newspaper office. Editors and reporters It's just an employee with a newspaper salary.

The so-called Web 1.0, from the user's point of view, means that the platform unilaterally transmits information to the user, and the user only has read-only rights, and the user can read whatever information the platform transmits.

  1. Web 2.0
    stands for:

Social network

Facebook

Google

Thinking content:

user created

All platform

platform control

Platform benefits

Web 2.0 is also the most important form on the Internet at present. On Web 2.0, the platform only needs to provide an infrastructure and environment, but the content created by the platform accounts for a small proportion, and users are encouraged to create by themselves. The entire creation environment, publishing platform, readers' reading, etc. will all be controlled by the platform.

For example, on Weibo, users publish their own creative content on Weibo, but the platform controls the source data of user-created content by virtue of its control over the infrastructure, which means that the platform has obtained the ownership of user data.

What is more obvious here is that Weibo can decide to edit, modify, block, and delete any content of users, and any content that has been modified is collectively referred to as illegal content, which will be defined by Weibo.

Let’s talk about the live broadcast platform. The content created by the anchors of the live broadcast platform will be determined and distributed by the live broadcast platform. For example, the distribution ratio of rewards, the difference in contract level between big anchors and small anchors, etc., are all decided by the platform. The large amount of data footprint and value generated by its users in the process of using the Internet is also taken by the platform for free.

In Web 1.0, the generation of information and data is limited to a small area, which is in line with the basic principles of the market economy of who creates, who owns, and who benefits.

And Web2.0 is a process of generating excessive information and filling up network data. From the perspective of information and knowledge, Web 2.0 is undoubtedly successful, but from the perspective of market economy such as creation ownership and value distribution, Web 2.0 is undoubtedly distorted and unreasonable. The basic rights of creators are deprived, and users Value is extracted at will, which is effectively a system of digital slavery.

This explains why only the era of Web 2.0 has produced several super giants, because these platforms actually capture a large part of the value produced and created by tens or even hundreds of millions of users for free.

Let's look at Web2.0 from the user's point of view. Users watch the content and benefits created by other users on the platform, so they also want to create new content. This is the reason for the surge in the number of creators. While abiding by the rules of the platform, users can obtain the benefits brought by the content, and at the same time have great independent control over their accounts and content.

This is undoubtedly a false Web3.0 situation created by the platform for users, because whether it is ownership rights, management rights, or profit distribution, it seems that they are all in the hands of users, but in fact it is the platform that has the final say.

  1. Web 3.0
    stands for:

blockchain

metaverse

DAO

NFT

Chain game

Thinking content:

user created

user owned

user control

Agreement to distribute benefits

After understanding Web 1.0 and Web 2.0, it will be clearer to look at Web 3.0. In Web 3.0, the ownership of digital content created by users is clearly owned by the user, and the control and management rights are clearly owned by the user. The value created is distributed according to the agreement signed by the user with others.

This article will not repeat the essence and functions of the blockchain here. Web3.0 uses the technology of blockchain protocol creation and automatic execution, that is, through smart contracts, the distribution agreement of rights and values ​​can be obtained without going through a third party. Efficient, accurate, credible execution, and the whole process can be audited. To put it in an easy-to-understand way, it means "there is no middleman to make the difference". But the blockchain is only a means, the purpose is to realize the confirmation and protection of users' digital asset rights and interests.

For example, in the recent popular Metaverse, users’ digital asset rights and interests in the Metaverse are determined and guaranteed by NFT. NFT will serve as an important token right on Web3.0, which allows users to freely add, modify, and edit in the Metaverse own small space, and then rent out, exhibit, and sell the small space to benefit.

  1. Conclusion
    We are currently in a period of transition from Web2.0 to Web3.0.

The development of Web 1.0 to Web 2.0 has stimulated the psychological satisfaction of users to create and share, and opened up a new revenue model, which has led to the explosion of excessive information in Web 2.0, which has produced hundreds of times the number of original authors. The original author obtains his own income under the distribution of interests after negotiation with the platform.

In order to guarantee the interests of original creators, relevant laws, namely intellectual property rights, have emerged in the development of social forms.

With the advent of the Web3.0 era, several global giant platforms will emerge, the status of originality will be elevated again, the distribution of benefits will be more transparent and reasonable, and the absolute fairness under the control of the agreement will make it emerge more than it is now. There are hundreds of times more original authors.

IPV6-----using 128 binary for identification

ipv6

IPv6 (Internet Protocol Version 6), also known as IPng (IP Next Generation), is the next-generation IP protocol IPv6, which is an upgraded version of the current mainstream IP protocol IPv4.

What are the characteristics of IPv6, and how does it solve various problems of IPv4?

The number of addresses is huge. IPv6 uses a 128-bit address space, and the total number of addresses is 2 to the 128th power. Theoretically, it can be said that the number of addresses is almost infinite. It avoids the performance loss caused by NAT, and also simplifies the header structure to make data forwarding more efficient. Compared with the IPv4 header, the IPv6 header removes the IHL, identifiers, Flags, Fragment Offset, Header Checksum, Options, and Padding fields, and only adds the flow label field. Therefore, the processing of the IPv6 packet header is greatly simplified compared with IPv4, improving the Processing efficiency.

https://zhuanlan.zhihu.com/p/382612295 (understand IPv6 in one article)

Example of base conversion (binary and decimal)

128 64 32 16 8 4 2 1 (2的次方幂)

1011 0000 .0001 0111. 1100 1111. 0000 0101
176.23.207.5

XXXX XXXX 
**打板转换**
0000 0001=1
0000 0010=2
0000 0100=4
0000 1000=8
0001 0000=16
0010 0000=32
0100 0000=64
1000 0000=128

使用32个二进制组成, 书写使用点分十进制。

Basic Concepts of Networking

Client: Application C/S (client/server) B/S (browser/server)

Server: A machine that provides services, data, and resources to clients

Request: the client requests data from the server

Response: The server responds to the client request, usually returning data to the client

[External link picture transfer failed, the source site may have an anti-leeching mechanism, it is recommended to save the picture and upload it directly (img-uL7vaJDv-1685289892369)(2023-05-28-19-32-00.png)]

## URL

Uniform Resource Locator (Uniform Resource Locator)

Each resource in the network corresponds to a unique address - URL

Basic Concepts (Classroom)

192.168.1.1 255.255.255.0

network bit host bit

1100 0000.1010 1000.0000 0001.0000 0001
1111 1111.1111 1111.1111 1111.0000 0000

Network mask: network mask, composed of 32 binary bits, consisting of consecutive 1+ consecutive 0s, consecutive 1s correspond to network bits, and consecutive 0s correspond to host bits.

It is also very interesting to know about it https://www.zhihu.com/question/56895036

IP address

The IP address is a unified address format provided by the IP protocol. It assigns a logical address to each network and each host on the Internet to shield the physical address (each machine has a code, such as on MAC There is a thing called a MAC address) difference. It is 32-bit binary data, usually expressed in decimal and separated by ".". An IP address is a logical address used to identify each host in the network, and is unique on the local area network.

IP address

overview

To achieve network communication, a computer must have a network address for fast positioning. The IP address is the unique ID of the computer in the network, which is the same as the need to have a specific residential address for express delivery in the real world.

The ip address is represented by four decimal numbers separated by dots, and each number is from 0 to 255. For example, the ip address of a certain host is: 128.20.4.1

Composition of IP address

IP address = network address + host address (also known as: host number and network number)

Think about why there are administrative divisions (countries, provinces, districts, streets, etc.), in order to manage and position more efficiently;

Similarly, we usually divide the network into many sub-networks, each sub-network has its own network address, and each sub-network is composed of many computers (of course, it can also contain another sub-network).

To find the specified IP address, we only need to find the specified network address first, and then find the corresponding host address in the network.

The IP address is a 4 * 8bit (1 byte) digital string consisting of 0/1 (IP4 protocol)

Take the IP address 192.168.1.168 and subnet mask 255.255.255.0 (detailed below) in the screenshot of opening win7 in the article as an example, this address contains many meanings:

192.168.100.168 (IP address) = 192.168.1.0 (network address) + 0.0.0.168 (host address)

[External link picture transfer failed, the source site may have an anti-leeching mechanism, it is recommended to save the picture and upload it directly (img-bAlXfMvL-1685289892369)(2023-05-28-19-33-59.png)]

[External link picture transfer failed, the source site may have an anti-leeching mechanism, it is recommended to save the picture and upload it directly (img-wg7tTtdt-1685289892370)(2023-05-28-19-34-09.png)]

IPV4 address

[External link picture transfer failed, the source site may have an anti-leeching mechanism, it is recommended to save the picture and upload it directly (img-dClxDEND-1685289892370)(2023-05-28-19-34-26.png)]

IP address sorting, netmask to find addresses

Netmask:

subnet mask

If you want to understand what a subnet mask is, you have to understand the composition of an IP address. The Internet is composed of many small networks, and each network has many hosts, thus forming a hierarchical structure. The hierarchical characteristics of address allocation are considered in the design of IP addresses, and each IP address is divided into two parts, the network number and the host number, so as to facilitate the addressing operation of the IP address.

How many digits are the network number and host number of the IP address? If you don't specify it, you don't know which bits are the network number and which are the host number, which needs to be realized through the subnet mask . What is a subnet mask? A subnet mask cannot exist alone. It must be used in conjunction with an IP address. The subnet mask has only one function, which is to divide an IP address into two parts, the network address and the host address. The setting of the subnet mask must follow certain rules. The same as the IP address, the length of the subnet mask is also 32 bits. The left side is the network bit, which is represented by the binary number "1"; the right side is the host bit, which is represented by the binary number "0". Suppose the IP address is "192.168.1.1" and the subnet mask is "255.255.255.0". Among them, there are 24 "1", which means that the 24 bits on the left of the corresponding IP address are the network number; there are 8 "0", which means that the 8 bits on the right of the corresponding IP address are the host number. In this way, the subnet mask determines which of the 32-bit binary numbers of an IP address are network numbers and which are host numbers. This is very important for a network using the TCP/IP protocol. Only through the subnet mask can it indicate the relationship between the subnet where a host is located and other subnets, so that the network can work normally.

There are hundreds of commonly used subnet masks, and only the two most commonly used subnet masks are introduced here.
The network whose subnet mask is "255.255.255.0":
the last number can be changed arbitrarily within the range of 0~255, so 256 IP addresses can be provided. But the actual number of available IP addresses is 256-2, that is, 254, because the host number cannot be all "0" or all "1".

A network with a subnet mask of "255.255.0.0":

The latter two numbers can be changed arbitrarily within the range of 0~255, which can provide 255² IP addresses. But the actual number of available IP addresses is 255²-2, or 65023.
The subnet mask setting of the IP address is not arbitrary. If the subnet mask is set too large, that is to say, the scope of the subnet is expanded, then, according to the subnet routing rules, it is likely that the data sent to the target host that is not in the same subnet as the local host will be incorrectly judged. If the target host is considered to be in the same subnet, then the data packet will circulate in this subnet until it times out and is discarded, so that the data cannot reach the target host correctly, resulting in network transmission errors; if the subnet mask is set too small , then the communication between machines that originally belonged to the same subnet will be regarded as cross-subnet transmission, and the data packets will be handed over to the default gateway for processing, which will inevitably increase the burden on the default gateway (explained below the article), resulting in Network efficiency drops. Therefore, the subnet mask should be set according to the scale of the network. If the scale of a network does not exceed 254 computers, it is enough to use "255.255.255.0" as the subnet mask. Now most LANs will not exceed this number, so "255.255.255.0" is the most commonly used IP address subnet. Netmask; If there are more than 1500 computers in a university, a LAN of this size can use "255.255.0.0".

Address Classification

Address classification: ABCDE
XXXX XXXX
Class A address: 0XXX XXXX, 0-127, the default mask is 255.0.0.0
Class B address: 10XX XXXX, 128-191, the default mask is 255.255.0.0
Class C address: 110X XXXX, 192 -223, the default mask is 255.255.255.0.
The above three types of addresses are called unicast addresses.
The second page of partition new partition 16. The
above three types of addresses are called unicast
addresses. Class D addresses: 1110 XXXX, 224-239 , no mask, multicast address.
Class E address: 1111 XXXX, 240-255, reserved, scientific research address.

Data transmission method:

1. Unicast 2. Multicast 3. Broadcast

different network name

Ethernet—Ethernet
LAN——Local Area Network
WLAN—Wireless Local Area Network
Local Area Network
Metropolitan Area Network
Wide Area Network WAN

H3C operating system: comware system

##Network segment:
192.168.1.1 255.255.255.0
describes the network segment specified by the network number, the network bits remain unchanged, and the host bits are all 0
1100 0000.1010 1000.0000 0001.0000 0001
1111 1111.1111 1111.1111 1111.0 000 0000
192.168.1.0 255.255.255.0

routers and switches

Router: router, used for communication between different network segments
Switch: Switch, used for communication between users in the same network segment

interface:

LAN interface: Ethernet:
Ethernet interface, 10Mbps, half-duplex
FastEthernet: Fast Ethernet interface, 100Mbps, full-duplex
GigabitEthernet: Gigabit Ethernet interface, 1000Mbps, full-duplex

gateway

A gateway is essentially an IP address from one network to another. For example, there are network A and network B. The IP address range of network A is "192.168.1.1 192.168.1.254", and the subnet mask is 255.255.255.0; the IP address range of network B is "192.168.2.1 192.168.2.254". The netmask is 255.255.255.0. In the absence of a router, TCP/IP communication cannot be performed between two networks. Even if the two networks are connected to the same switch (or hub), the TCP/IP protocol will use the subnet mask (255.255 .255.0) determine that the hosts in the two networks are in different networks. And to realize the communication between these two networks, you must go through the gateway. If the host in network A finds that the destination host of the data packet is not in the local network, it forwards the data packet to its own gateway, and then the gateway forwards it to the gateway of network B, and the gateway of network B forwards it to a certain network B host. The same is true for the process of forwarding data packets from network B to network A. Therefore, only when the IP address of the gateway is set, the TCP/IP protocol can realize mutual communication between different networks. So which machine's IP address is this IP address? The IP address of the gateway is the IP address of the device with routing function. The devices with routing function include routers, servers with routing protocols enabled (essentially equivalent to a router), and proxy servers (also equivalent to a router).
A router (called a default gateway under Windows, a gateway is a route, and a route is a gateway should not be fooled).
If you figure out what a gateway is, the default gateway will be easy to understand. Just like a room can have multiple doors, a host can have multiple gateways. The default gateway means that if a host cannot find an available gateway, it will send the data packet to the default designated gateway, and the gateway will process the data packet. The gateway currently used by the host generally refers to the default gateway.

Below is the explanation given by Baidu Encyclopedia

How to set the default gateway The default gateway of a computer cannot be specified casually, it must be specified correctly, otherwise a computer will send data packets to a computer that is not a gateway, and thus cannot communicate with computers on other networks. There are two ways to set the default gateway: manual setting and automatic setting.
Manual setting: Manual setting is suitable for the situation where the number of computers is relatively small and the TCP/IP parameters are basically unchanged, for example, there are only a few to a dozen computers. Because this method needs to set the "default gateway" on each computer connected to the network, it is very laborious. Once the IP address of the default gateway must be modified due to migration or other reasons, it will bring a lot of trouble to the network management. Recommended Use. Special attention should be paid to: the default gateway must be the IP address in the network segment where the computer is located, and the IP address in other network segments cannot be filled in.
Automatic setting: automatic setting is to use DHCP server to automatically assign IP address, subnet mask and default gateway to computers in the network. The advantage of this is that once the default gateway of the network changes, as long as the setting of the default gateway in the DHCP server is changed, all computers in the network will obtain the IP address of the new default gateway. This method is suitable for networks with large network scale and possible changes in TCP/IP parameters. Another way to automatically obtain the gateway is to install the client program of the proxy server software (such as MS Proxy) to obtain it automatically. The principle and method are similar to DHCP. Due to the limited space, it will not be described in detail.

default gateway

Default Gateway (Default Gateway) is a node in a computer network that forwards data packets to other networks. In a typical TCP/IP network, nodes (such as servers, workstations, and network devices) have a defined default route set (pointing to the default gateway). It is possible to specify the next-hop IP address of the data packet to be sent without a specific route.
The following is the explanation given by Baidu Encyclopedia:

It can be seen that the default gateway is the default gateway, so some people will say that since there is one, why there is an extra default gateway out of thin air, my understanding is this, it should be said that the default gateway is a subset of the default gateway. The default gateway has a defined default routing setting (pointing to the default gateway). The default gateway is equivalent to a proxy server temporarily managing the sent data packets. When sending to the target host, it will be received by the default gateway of the target host and then find the corresponding The default gateway is equivalent to the default gateway being the parent class and the default gateway being the subclass~~

DNS server

Domain Name Server (Domain Name Server). There is a one-to-one correspondence between domain names and IP addresses on the Internet. Although domain names are easy for people to remember, machines can only recognize each other’s IP addresses. The conversion work between them is called domain name resolution. Domain name resolution requires a dedicated domain name DNS is the server for domain name resolution.

DHCP server

DHCP refers to a range of IP addresses controlled by the server. When the client logs in to the server, it can automatically obtain the IP address and subnet mask assigned by the server. Improve address usage.

MAC address

The MAC address is like the ID number on our ID card, which is globally unique. (Just know this, don’t need to look down) The first 24 bits
of the MAC (Media Access Control) address
are called the Organizationally Unique Identifier (OUI), which is given to different manufacturers by the IEEE registry The assigned codes distinguish different manufacturers.
The last 24 bits are assigned by the manufacturer itself and are called extended identifiers. The last 24 bits of the MAC address in the network card produced by the same manufacturer are different.
The physical address of the network card is usually burned into the EPROM of the network card by the manufacturer of the network card (a flash memory chip, which can usually be erased and written by the program). address.
That is to say, in the physical transmission process at the bottom of the network, the host is identified through the physical address, which must be unique in the world. For example, the physical address of the well-known Ethernet card is a 48-bit (bit) integer, such as: 44-45-53-54-00-00, which is stored in the host interface in a machine-readable manner. The Ethernet address management organization (other than this) (IEEE) (IEEE: Institute of Electrical and Electronics Engineers) divides Ethernet addresses, that is, different combinations of 48 bits, into several independent continuous address groups, producing Manufacturers of Ethernet network cards purchase one set, and assign unique addresses to the Ethernet cards one by one during specific production.
In a stable network, IP addresses and MAC addresses appear in pairs. If a computer wants to communicate with another computer in the network, the IP addresses of the two computers must be configured. The MAC address is set when the network card leaves the factory, so that the configured IP address and the MAC address form a corresponding relationship. . In data communication, the IP address is responsible for representing the network layer address of the computer, and the network layer device (such as a router) operates according to the IP address; the MAC address is responsible for representing the data link layer address of the computer, and the data link layer device (such as a switch) Operate according to the MAC address. The mapping relationship between IP and MAC addresses is completed by the ARP (Address Resolution Protocol, Address Resolution Protocol) protocol.

server

Classification of servers

According to the stage of software development, servers can be roughly divided into two types:

(1) Remote server

Alias: external network server, official server
Use stage: the server used after the application goes online User
population: for all users
Speed: server performance, user network speed

(2) Local server

Alias: Intranet server, test server
Use stage: The server used by the application in the development and test stage User population : Only for
developers and testers within the company
Efficiency
The choice of local server
The remote server is just a local intranet server open to external network access
If you are in the learning and development stage, you can build a local server by yourself

The port number

Ports include physical ports and logical ports. A physical port is an interface used to connect physical devices, and a logical port is a logical port used to differentiate services. The port in the TCP/IP protocol is a logical port, and different services are distinguished through different logical ports.

What is the use of the port? We know that a host with an IP address can provide many services, such as Web services, FTP services, SMTP services, etc., and these services can be fully realized through one IP address. So, how does the host distinguish between different network services? Obviously, you can't just rely on IP addresses, because the relationship between IP addresses and network services is a one-to-many relationship. In fact, different services are distinguished by "IP address + port number".

Well-Known Ports

Such ports are also often referred to as "commonly used ports". The port numbers of such ports range from 0 to 1023, and they are tightly bound to some specific services. Usually the communication of these ports clearly shows the protocol of some kind of service, and this kind of port can no longer redefine its function object. Port 80 is actually always used for HTTP communication, while port 23 is reserved for Telnet services.

Registered Ports

Port numbers range from 1025 to 49151. Assigned to a user process or application. These processes are mainly some applications that the user chooses to install, rather than commonly used programs with well-known ports assigned.

Dynamic and/or Private Ports (Dynamic and/or Private Ports)
are called dynamic ports because they generally do not assign certain services fixedly, but are assigned dynamically.

What do IP address, subnet mask, default gateway, DNS server mean?

(1) Problem analysis

Q: What is the difference between IP address, subnet mask, default gateway, and DNS server? I know that I cannot access the Internet without an IP address, and I also know that I cannot access the Internet without DNS, but what functions do they have, and what is the difference? Also, it’s really strange that my computer doesn’t have DNS, so I can access QQ, but I can’t open the webpage, why is that>

Answer: IP is 32-bit binary data, usually expressed in decimal and separated by ".". The IP address is a logical address used to identify each host in the network. The IP is unique, that is, the IP of each machine is unique in the world.

DNS is a domain name server, which is used to resolve domain names (analysis between domain names and IPs). If there is no such thing, you must enter the IP address of the website. With DNS, you can directly enter the URL.
Because accessing QQ does not require DNS (QQ is just a client program and does not use DNS), DNS is only used when browsing web pages (when URLs need to be entered).

(Nice article) Internet Roaming Notes of a Data Packet

https://www.51cto.com/article/442086.html

DNS server

 DNS是指:域名服务器(Domain Name Server)。在Internet上域名与IP地址之间是一一对应的,域名虽然便于人们记忆,但机器之间只能互相认识IP地址,它们之间的转换工作称为域名解析,域名解析需要由专门的域名解析服务器来完成,DNS就是进行域名解析的服务器 。

The software that translates domain names into IP addresses is called Domain Name System, or DNS. It keeps a table of domain name (domain name) and corresponding IP address (IP address) to resolve the domain name of the message. A domain name is the name of a certain computer or group of computers on the Internet, and is used to identify the computer's electronic location (or sometimes geographical location) during data transmission. A domain name is a series of dot-separated names, usually containing the name of an organization, and always includes a two- or three-letter suffix to indicate the type of organization or the country or region in which the domain is located. Domain name server introduction: http://baike.baidu.com/view/543329.htm

Most of us have used google.com to search, but have you ever wondered why you can connect to Google's servers by typing google.com in your browser? Well... To understand this, we need to understand domain names The concept of server (DNS).

Just as people in real life are distinguished from each other by their names, in the world of computer networking, different computers are distinguished from each other by the IP addresses assigned to them. There are two types of IP addresses: public and private. Usually servers use public addresses because they are accessed by millions of computers around the world. As for your PC connected to the router, it usually gets a private IP. Since the number of public addresses is limited, setting up a LAN (under a router with a public IP) and then using private addresses has become popular and very successful.

Tasks like remembering IP addresses are difficult for most people, so each server also has a name (such as google.com). In this way, the end user only needs to remember the name, enter it in the browser, and hit enter. Now let's take a look at what happens when the user types their name in the browser and hits enter. First, you need to convert the domain name to the corresponding IP. To accomplish this task, a DNS request is sent to the default gateway (router in most cases). Routers are configured with a DNS server address, which is the destination of DNS requests.

DNS servers are used to translate domain names into IP addresses. When a DNS server receives a request, it checks to see if it has the translation information needed for the request. If there is no such conversion information, the DNS server will forward this request to other DNS servers. In this way, the conversion from domain name to IP address is completed. The conversion results are then sent back to the requesting computer.

IP address

To achieve network communication between computers, there must be a legal ip address. IP address = network address + host address, (also known as: host number and network number) The structure of the ip address allows us to easily address on the Internet. The ip address is usually represented by four decimal numbers separated by dots, and each number is from 0 to 255. For example, the ip address of a certain host is: 128.20.4.1 In the local area network, the ip address is also required , Generally, the ip address of the intranet starts with 192.168, so it is easy to distinguish the ip address of the public network and the intranet.

Whether learning the network or surfing the Internet, IP address is a word with a very high frequency. The interface for setting IP address in Windows system is shown in Figure 1, in which there are IP address, subnet mask, default gateway and DNS server. There are a few places that need to be set up. Only with correct settings can the network be connected. What do these terms mean? When learning about IP addresses, you will also encounter concepts such as network addresses, broadcast addresses, and subnets. What do these mean? Woolen cloth

To answer these questions, let’s look at an example in daily life. As shown in Figure 2, in order for residents living in North Street to be able to find each other, each must have a house number, which is the address of each house. The way to express the house number is: North Street + XX. If household No. 1 wants to find household No. 6, the process is as follows. No. 1 shouted on the street: "Who is No. 6, please answer." At this time All the residents of Beijie Street heard it, but only No. 6 answered. This shouting process is called "broadcasting", and all the users of Beijie Street are his broadcasting range. If there are 20 users in Beijie Street, then the broadcasting address is: Beidajie No. 21 Main Street. That is to say, any user on North Street can be heard by "broadcast address-1" users.

The following words can be extracted from this example:
street address: North Street, if an address is given to the street, then use the address-1 of the first household, this example is: No. 0
household of North Street: as No. 1, No. 2, etc.
Household address: street address + XX, such as No. 1 North Street, No. 2 North Street, etc.
Broadcast address: the address of the last household + 1, in this example: No. 21 North Street

In the Internet network, each computer on the Internet has an address like the above example. This address is the IP address, which is the house number assigned to the network device. In order for the computers in the network to access each other, IP address = network address + host address , the IP address in Figure 1 is 192.168.100.1, which contains many meanings. As shown below:

Network address (equivalent to street address): 192.168.100.0
Host address (equivalent to door number of each household): 0.0.0.1
IP address (equivalent to household address): Network address + host address = 192.168.100.1
Broadcast address: 192.168. 100.255

How are these addresses calculated? Why are these addresses calculated? If you want to know how, you must first understand a truth. Learn and understand the concepts in the network, not just memorize a few nouns.

Note: 192.168.100.1 is a private address, which cannot be directly used in the Internet network. It must be converted to a public address when accessing the Internet, as detailed below.

Note: 192.168.100.1 is a private address, which cannot be directly used in the Internet network. It must be converted to a public address when accessing the Internet, as detailed below.

Guess you like

Origin blog.csdn.net/shaozheng0503/article/details/130919722