{"id":13575456,"url":"https://github.com/wx-chevalier/Network-Notes","last_synced_at":"2025-04-04T22:31:12.901Z","repository":{"id":105127287,"uuid":"242305641","full_name":"wx-chevalier/Network-Notes","owner":"wx-chevalier","description":"分布式系统之网络篇，TCPIP、HTTP、WebSocket、SDN 等。","archived":false,"fork":false,"pushed_at":"2024-09-24T07:58:54.000Z","size":7317,"stargazers_count":12,"open_issues_count":0,"forks_count":3,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-01-02T08:21:48.292Z","etag":null,"topics":["network","tcp"],"latest_commit_sha":null,"homepage":"https://ng-tech.icu/books/Network-Series","language":"HTML","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/wx-chevalier.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-02-22T08:20:10.000Z","updated_at":"2024-09-24T07:58:55.000Z","dependencies_parsed_at":null,"dependency_job_id":"cf4a8d2c-852b-48c1-b21f-967f0e275ba1","html_url":"https://github.com/wx-chevalier/Network-Notes","commit_stats":null,"previous_names":["wx-chevalier/network-series"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wx-chevalier%2FNetwork-Notes","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wx-chevalier%2FNetwork-Notes/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wx-chevalier%2FNetwork-Notes/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wx-chevalier%2FNetwork-Notes/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/wx-chevalier","download_url":"https://codeload.github.com/wx-chevalier/Network-Notes/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247260488,"owners_count":20910013,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["network","tcp"],"created_at":"2024-08-01T15:01:01.250Z","updated_at":"2025-04-04T22:31:07.863Z","avatar_url":"https://github.com/wx-chevalier.png","language":"HTML","funding_links":[],"categories":["HTML"],"sub_categories":[],"readme":"[![Contributors][contributors-shield]][contributors-url]\n[![Forks][forks-shield]][forks-url]\n[![Stargazers][stars-shield]][stars-url]\n[![Issues][issues-shield]][issues-url]\n[![license: CC BY-NC-SA 4.0](https://img.shields.io/badge/license-CC%20BY--NC--SA%204.0-lightgrey.svg)][license-url]\n\n\u003c!-- PROJECT LOGO --\u003e\n\u003cbr /\u003e\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://github.com/wx-chevalier/Network-Notes\"\u003e\n    \u003cimg src=\"https://s2.ax1x.com/2020/01/06/lr21MT.png\" alt=\"Logo\" width=\"80\" height=\"80\"\u003e\n  \u003c/a\u003e\n\n  \u003ch3 align=\"center\"\u003eNetwork Series\u003c/h3\u003e\n\n  \u003cp align=\"center\"\u003e\n    网络与协议·实践笔记\n    \u003cbr /\u003e\n    \u003ca href=\"https://github.com/wx-chevalier/Network-Notes\"\u003e\u003cstrong\u003e在线阅读 \u003e\u003e \u003c/strong\u003e\u003c/a\u003e\n    \u003cbr /\u003e\n    \u003cbr /\u003e\n    \u003ca href=\"https://github.com/wx-chevalier/Network-Notes\"\u003e速览手册\u003c/a\u003e\n    ·\n    \u003ca href=\"https://github.com/wx-chevalier/Network-Notes/issues\"\u003e代码实践\u003c/a\u003e\n    ·\n    \u003ca href=\"https://github.com/wx-chevalier/Network-Notes/issues\"\u003e参考资料\u003c/a\u003e\n  \u003c/p\u003e\n\u003c/p\u003e\n\n\u003c!-- ABOUT THE PROJECT --\u003e\n\n# Introduction | 前言\n\n# Network Series | 网络基础\n\n![TCPIP 分层模型](https://assets.ng-tech.icu/item/20230416204257.png)\n\n- 物理层：主要定义物理设备标准，如网线的接口类型、光纤的接口类型、各种传输介质的传输速率等。它的主要作用是传输比特流(就是由 1、0 转化为电流强弱来进行传输,到达目的地后在转化为 1、0，也就是我们常说的数模转换与模数转换)。这一层的数据叫做比特。\n\n- 数据链路层：定义了如何让格式化数据以进行传输，以及如何让控制对物理介质的访问。这一层通常还提供错误检测和纠正，以确保数据的可靠传输。\n\n- 网络层：在位于不同地理位置的网络中的两个主机系统之间提供连接和路径选择。Internet 的发展使得从世界各站点访问信息的用户数大大增加，而网络层正是管理这种连接的层。\n\n- 传输层：定义了一些传输数据的协议和端口号(WWW 端口 80 等)，如：TCP(传输控制协议，传输效率低，可靠性强，用于传输可靠性要求高，数据量大的数据)，UDP(用户数据报协议，与 TCP 特性恰恰相反，用于传输可靠性要求不高，数据量小的数据，如 QQ 聊天数据就是通过这种方式传输的)。主要是将从下层接收的数据进行分段和传输，到达目的地址后再进行重组。常常把这一层数据叫做段。\n\n- 会话层：通过传输层(端口号：传输端口与接收端口)建立数据传输的通路。主要在你的系统之间发起会话或者接受会话请求(设备之间需要互相认识可以是 IP 也可以是 MAC 或者是主机名)\n\n- 表示层：可确保一个系统的应用层所发送的信息可以被另一个系统的应用层读取。例如，PC 程序与另一台计算机进行通信，其中一台计算机使用扩展二一十进制交换码(EBCDIC)，而另一台则使用美国信息交换标准码(ASCII)来表示相同的字符。如有必要，表示层会通过使用一种通格式来实现多种数据格式之间的转换。\n\n- 应用层: 是最靠近用户的 OSI 层。这一层为用户的应用程序(例如电子邮件、文件传输和终端仿真)提供网络服务。\n\n# 常用术语\n\nIPAM：IP 地址管理；这个 IP 地址管理并不是容器所特有的，传统的网络比如说 DHCP 其实也是一种 IPAM，到了容器时代我们谈 IPAM，主流的两种方法：基于 CIDR 的 IP 地址段分配地或者精确为每一个容器分配 IP。但总之一旦形成一个容器主机集群之后，上面的容器都要给它分配一个全局唯一的 IP 地址，这就涉及到 IPAM 的话题。\n\nOverlay：在现有二层或三层网络之上再构建起来一个独立的网络，这个网络通常会有自己独立的 IP 地址空间、交换或者路由的实现。\n\nIPSesc：一个点对点的一个加密通信协议，一般会用到 Overlay 网络的数据通道里。\n\nvxLAN：由 VMware、Cisco、RedHat 等联合提出的这么一个解决方案，这个解决方案最主要是解决 VLAN 支持虚拟网络数量（4096）过少的问题。因为在公有云上每一个租户都有不同的 VPC，4096 明显不够用。就有了 vxLAN，它可以支持 1600 万个虚拟网络，基本上公有云是够用的。\n\n网桥 Bridge：连接两个对等网络之间的网络设备，但在今天的语境里指的是 Linux Bridge，就是大名鼎鼎的 Docker0 这个网桥。\n\nBGP：主干网自治网络的路由协议，今天有了互联网，互联网由很多小的自治网络构成的，自治网络之间的三层路由是由 BGP 实现的。\n\nSDN、Openflow：软件定义网络里面的一个术语，比如说我们经常听到的流表、控制平面，或者转发平面都是 Openflow 里的术语。\n\n\u003e 本书的精排目录导航版请参考 [https://ng-tech.icu/books/Network-Notes](https://ng-tech.icu/books/Network-Notes)。\n\n# Nav | 关联导航\n\n# About | 关于\n\n\u003c!-- CONTRIBUTING --\u003e\n\n## Contributing\n\nContributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are **greatly appreciated**.\n\n1. Fork the Project\n2. Create your Feature Branch (`git checkout -b feature/AmazingFeature`)\n3. Commit your Changes (`git commit -m 'Add some AmazingFeature'`)\n4. Push to the Branch (`git push origin feature/AmazingFeature`)\n5. Open a Pull Request\n\n\u003c!-- ACKNOWLEDGEMENTS --\u003e\n\n## Acknowledgements\n\n- [Awesome-Lists](https://github.com/wx-chevalier/Awesome-Lists): 📚 Guide to Galaxy, curated, worthy and up-to-date links/reading list for ITCS-Coding/Algorithm/SoftwareArchitecture/AI. 💫 ITCS-编程/算法/软件架构/人工智能等领域的文章/书籍/资料/项目链接精选。\n\n- [Awesome-CS-Books](https://github.com/wx-chevalier/Awesome-CS-Books): :books: Awesome CS Books/Series(.pdf by git lfs) Warehouse for Geeks, ProgrammingLanguage, SoftwareEngineering, Web, AI, ServerSideApplication, Infrastructure, FE etc. :dizzy: 优秀计算机科学与技术领域相关的书籍归档。\n\n## Copyright \u0026 More | 延伸阅读\n\n笔者所有文章遵循[知识共享 署名 - 非商业性使用 - 禁止演绎 4.0 国际许可协议](https://creativecommons.org/licenses/by-nc-nd/4.0/deed.zh)，欢迎转载，尊重版权。您还可以前往 [NGTE Books](https://ng-tech.icu/books-gallery/) 主页浏览包含知识体系、编程语言、软件工程、模式与架构、Web 与大前端、服务端开发实践与工程架构、分布式基础架构、人工智能与深度学习、产品运营与创业等多类目的书籍列表：\n\n[![NGTE Books](https://s2.ax1x.com/2020/01/18/19uXtI.png)](https://ng-tech.icu/books-gallery/)\n\n\u003c!-- MARKDOWN LINKS \u0026 IMAGES --\u003e\n\u003c!-- https://www.markdownguide.org/basic-syntax/#reference-style-links --\u003e\n\n[contributors-shield]: https://img.shields.io/github/contributors/wx-chevalier/Network-Notes.svg?style=flat-square\n[contributors-url]: https://github.com/wx-chevalier/Network-Notes/graphs/contributors\n[forks-shield]: https://img.shields.io/github/forks/wx-chevalier/Network-Notes.svg?style=flat-square\n[forks-url]: https://github.com/wx-chevalier/Network-Notes/network/members\n[stars-shield]: https://img.shields.io/github/stars/wx-chevalier/Network-Notes.svg?style=flat-square\n[stars-url]: https://github.com/wx-chevalier/Network-Notes/stargazers\n[issues-shield]: https://img.shields.io/github/issues/wx-chevalier/Network-Notes.svg?style=flat-square\n[issues-url]: https://github.com/wx-chevalier/Network-Notes/issues\n[license-shield]: https://img.shields.io/github/license/wx-chevalier/Network-Notes.svg?style=flat-square\n[license-url]: https://github.com/wx-chevalier/Network-Notes/blob/master/LICENSE.txt\n\n## Links\n\n- https://segmentfault.com/a/1190000019891825\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwx-chevalier%2FNetwork-Notes","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwx-chevalier%2FNetwork-Notes","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwx-chevalier%2FNetwork-Notes/lists"}