当前位置:网站首页>IP protocol from 0 to 1
IP protocol from 0 to 1
2022-07-31 16:39:00 【Xiaopaicai learns java】
Network layer protocol: IP protocol Internet Protocol
Responsibilities of the network layer: realize the communication between the host and the host across the local area network, and complete the routing function
Routing problem: solve the problem of long-term goals and short-term goals, and solve the problem of short-term goals through long-term goals
IP address:
IPV4: 32-bit unsigned positive number (4 bytes), usually expressed in dotted decimal: 127.0.0.1
IPV6: 128-bit unsigned integer
——————————————————————————————————————————
IP address consists of routing number + host number.
Disassembly of the network number:
1, static mode: divided into 5 types of networks

Class A network IP: The network number occupies 8 bits, the first digit is 0, and the host number occupies 3 bytes (8 bits * 3)
For example: 10.192.93.2 into binary: 0b 0000 1010 . 192.93.2
The network number is 8 bytes of money: 0000 1010 -> 10.0.0.0 is the network number
Host ID: 0.192.93.2
2, dynamic, adds a netmask
Netmask: Unsigned 32-bit integer, characteristic, all 1s in front, all 0s in the back

For example: mask 224.0.0.0, written in binary: 1110 0000.0.0.0, the first three digits are all 1s, followed by all 0s, 1110 0000.0.0.0 and / 3 This way of writing expresses the same thing, both meannetmask: 224.0.0.0;
ip address = network number + host number
Calculation of network number and host number:

Special IP address
If the host number is all 0 (network number), it will not be allocated. If the host number is all 1 (broadcast number), it will not be allocated.
127.0.0.0/8 is reserved as the loopback address,
IP addresses are divided into intranet and public addresses.

Intranet IP range:

The IPs of the same intranet cannot be duplicated, and the host IPs of different intranets can be duplicated, but the external IPs cannot be duplicated.
——————————————————————————————————————————
IP routing and forwarding function



——————————————————————————————————————————
IP protocol header parsing
DNS Protocol: Domain Name Resolution Protocol
In order to solve the problem that IP addresses are difficult to remember, a protocol for resolving IP addresses using domain names is specified.


边栏推荐
猜你喜欢

研发过程中的文档管理与工具

Three aspects of Ali: How to solve the problem of MQ message loss, duplication and backlog?

Dialogue with Zhuang Biaowei: The first lesson of open source

【7.29】代码源 - 【排列】【石子游戏 II】【Cow and Snacks】【最小生成数】【数列】

【pytorch】pytorch 自动求导、 Tensor 与 Autograd
![[TypeScript] In-depth study of TypeScript type operations](/img/d9/ee240ccba72e8d3114ee5c52ed0c8f.png)
[TypeScript] In-depth study of TypeScript type operations

Smart Trash Can (8) - Infrared Tube Sensor (Raspberry Pi pico)

二分查找的细节坑

i.MX6ULL driver development | 33 - NXP original network device driver reading (LAN8720 PHY)

2022年整理LeetCode最新刷题攻略分享(附中文详细题解)
随机推荐
第二届中国PWA开发者日
[TypeScript] In-depth study of TypeScript type operations
【网络通信三】研华网关Modbus服务设置
Graham's Scan method for solving convex hull problems
【愚公系列】2022年07月 Go教学课程 020-Go容器之数组
6-22漏洞利用-postgresql数据库密码破解
Foreign media right, apple on May be true in inventory
Applicable scenario of multi-master replication (2) - client and collaborative editing that require offline operation
牛客网刷题(三)
自动化测试—web自动化—selenium初识
Stuck in sill idealTree buildDeps during npm installation, npm installation is slow, npm installation is stuck in one place
动态规划之线性dp(下)
并发性,时间和相对性
After the form is submitted, the page does not jump [easy to understand]
SringMVC中个常见的几个问题
【Yugong Series】July 2022 Go Teaching Course 020-Array of Go Containers
【愚公系列】2022年07月 Go教学课程 022-Go容器之字典
C language "the third is" upgrade (mode selection + AI chess)
2020微信小程序反编译教程(小程序反编译源码能用吗)
使用互相关进行音频对齐