An overview of computer networks - an article to understand computer networks

Overview of Computer Networks

1.1 The role of computer networks in the information age

Some important features of the 21st century are digitalization, networking and informatization. It is an information age with the network as the core.
Thinking: What is the most inseparable item for everyone every day?
image-1671551939497
If there is no network, no Internet, no rich and colorful information and applications on the Internet, will people still be obsessed with mobile phones?

So what exactly is the network we usually talk about?

  • Network (Network) is composed of several nodes (Node) and links (Link) connecting these nodes. The nodes in the network can be computers, hubs, switches or routers, etc.
    image-1671552012833

  • Multiple networks can also be interconnected through routers, thus forming a computer network with a larger coverage. Such a network is called the Internet (internetwork or internet)
    image-1671552050522

  • When we use a cloud to represent a network, two different situations are possible. In one case, the network represented by the cloud already includes computers connected to the network. But sometimes, for the convenience of discussing problems (for example, to discuss how to communicate between several computers), the relevant computers can also be drawn outside the cloud. Customarily, a computer connected to a network is often called a host . In this way, there are only many routers and links connecting these routers left in the Internet represented by the cloud.
    image-1671552078687

  • The Internet (nternet) is the largest interconnected network in the world (hundreds of millions of users and millions of interconnected networks)
    image-1671552102737

  • The difference between internet and Internet

    • Internet (Internet or Internet) is a general term that generally refers to a network formed by interconnecting multiple computer networks . The communication protocol between these networks can be arbitrary.
    • Internet (Internet) is a special term. It refers to the current world's largest, open, specific computer network formed by interconnecting many networks. It adopts the TCP/IP协议rules of communication. Its predecessor is ARPANET in the United States.

1.2 Three Stages of Internet Development

The basic structure of the Internet has roughly experienced the following three stages of evolution:
image-1671552428829

The first stage: In 1969, the US military computer network ARPANET ("ARPANET") appeared, which is the prototype of today's Internet. Centralized data processing, data processing and communication processing are all done through the host.

At that time, Arpanet was only connected to four nodes, and the transmission rate was low. Because the computer graphical interface was not developed at that time , information could only be displayed through text terminals, and there were no application scenarios .

The distribution position of the four nodes in 1969. They are:

  • University of California, Los Angeles - UCLA
  • University of California, Santa Barbara - UCSB
  • Stanford Research Institute - SRI
  • University of Utah - Utah

image-1671552550533

In 1983, the TCP/IP protocol became the standard protocol of ARPANET, so people consider 1983 as the birth time of the Internet.

The second stage: the Internet with a three-level structure has been built. Since 1985, the National Science Foundation NSF (National Science Foundation) has built a computer network around six large computer centers, namely the National Science Foundation Network NSFNET, which is a three-level computer network divided into backbone network, regional network and Campus network (or enterprise network) . This three-level computer network covers major universities and research institutes across the United States, and has become a major component of the Internet. In 1991, NSF and other U.S. government agencies began to recognize that the Internet was bound to expand its use beyond universities and research institutions. Many companies in the world have connected to the Internet one after another, and the traffic on the network has increased sharply, making the capacity of the Internet unable to meet the needs. So the U.S. government decided to hand over the backbone network of the Internet to private companies to operate, and began to charge for units connected to the Internet. In 1992, there were more than 1 million hosts on the Internet. In 1993, the speed of the Internet backbone network was increased to 45Mbit/s (T3 speed).

The third stage: the Internet with a multi-level ISP structure gradually formed . Beginning in 1993, NSFNET, funded by the US government, was gradually replaced by several commercial Internet backbones, and government agencies were no longer responsible for the operation of the Internet. Thus appeared - a new term: Internet Service Provider ISP (Internet Service Provider). In many cases, an ISP is a company that conducts commercial activities, so ISP is often translated as an Internet service provider. For example, companies such as China Telecom, China Unicom, and China Mobile are the most famous ISPs in our country.

  • Internet service provider ISP (Internet Service Provider)
    • ISP can apply for a lot of P addresses from the Internet management agency (hosts on the Internet must have P addresses to access the Internet), and at the same time have communication lines (big ISPs build communication lines themselves, and small ISPs lease communication lines from telecommunications companies) and routers Therefore, any organization or individual can obtain the right to use the required IP address from the ISP as long as they pay the specified fee to the ISP, and can access the Internet through the ISP.
      image-1671552821228
    • According to the size of the coverage area provided by the service and the number of P addresses owned, ISPs are also divided into different levels of ISPs: backbone ISPs, regional ISPs, and local ISPs (we are also called first-tier ISPs, second-tier ISPs in terms of hierarchical relationships). tier ISP, local ISP)
      • Backbone ISPs are created and maintained by several specialized companies, serve the largest area (generally able to cover the country), and also have a high-speed backbone network (eg 10Gbit/s or higher). Some regional ISP networks can also be directly connected to the backbone ISP.
      • Regional ISPs are smaller ISPs. These regional ISPs are connected by one or more backbone ISPs. They are on the second tier in the hierarchy and have a lower data rate.
      • Local ISPs provide direct services to users (these users are sometimes called end users, emphasizing end users). Local SPs can connect to regional ISPs or directly to backbone ISPs. The vast majority of users connect to their local ISP. A local ISP can be a company that simply provides Internet service, a business that owns a network and provides services to its own employees, or a non-profit institution (such as a college or university) that runs its own network. Local ISPs can connect with regional ISPs or trunk ISPs.
        image-1671553083397

1.3 Internet standardization work

  • The standardization work of the Internet has played a very important role in the development of the Internet.
  • A great feature of the Internet in formulating its standards is that it is open to the public.
    • All RFC (Request For Comments) technical documents on the Internet can be downloaded free of charge from the Internet, http://www.ietf.org/rfc.html
    • Anyone can email comments or suggestions about a document at any time.
  • The Internet Society SOC is an international organization responsible for the overall management of the Internet and the promotion of its development and use worldwide
    • The Internet Architecture Board AB is responsible for managing the development of Internet-related protocols:
    • The ETF of the Internet Engineering Department is responsible for researching short-term and medium-term engineering issues, mainly for the development and standardization of protocols:
    • The Internet Research Department, TF, is engaged in theoretical research and development of issues that require long-term consideration.
      image-1671553449918

1.4 Composition of the Internet

1.4.1 Function division

Although the topology of the Internet is very complex and covers the whole world geographically, it is functionally complex. It can be divided into the following two parts.

  • Edge part: composed of all hosts connected to the Internet . This part is used directly by users for communication (transmitting data, audio or video) and resource sharing .
    • The host in the edge part can be a computer or a large server, or a notebook or a tablet
    • Smartphones, smart watches
    • IoT smart hardware: smart cameras, etc.
  • Core part: composed of a large number of networks and routers connecting these networks . This part serves the edge part (provides connectivity and switching).
    image-1671553595990

1.4.2 Edge part

  1. The part at the edge of the Internet is all the hosts connected to the Internet. These hosts are also called end systems
  2. "Host A communicates with host B" actually means: "a program running on host A communicates with another program running on host B".
  3. That is, "a process on host A communicates with another process on host B". Or simply "computer-to-computer communication"
  4. The means of communication between programs running in end systems at the edge of the network can generally be divided into two broad categories:
    • Client server mode (C/S mode) , that is, Client/Server mode

      • Client (client) and server (server) both refer to the two application processes involved in the communication
      • The client-server approach describes the relationship between the service and the serviced process .
      • The client is the requester of the service , and the server is the provider of the service .
        image-1671553797198
      • The client program must know the P address of the server program, no special hardware and very complicated operating system are required.
      • The server program does not need to know the P address of the client program, but the system needs to be running continuously, and needs powerful hardware and advanced operating system support.
    • Peer-to-peer mode (P2P mode) , that is, Peer-to-Peer mode

      • Peer-to-peer connection (peer-to-peer, abbreviated as P2P) means that two hosts do not distinguish which one is the service requester or the service provider when communicating.
      • As long as both hosts are running peer-to-peer connection software (P2P software), they can communicate on an equal, peer-to-peer connection.
      • Both parties can download the shared documents that the other party has stored in the hard disk.
        image-1671553974365
      • The peer-to-peer connection method still uses the client-server method in essence, but each host in the peer-to-peer connection is both a client and a server at the same time.
      • For example, when host C requests the service of D, C is the client and D is the server. But if C provides services to F at the same time, then C also acts as a server at the same time.
      • The characteristics of P2P network technology are reflected in the following aspects:
        • Decentralization: The resources and services in the network are scattered on all nodes, and the transmission of information and the realization of services are carried out directly between nodes, without the intervention of intermediate links and servers, avoiding possible bottlenecks
        • Robustness: The P2P architecture is inherently resistant to attacks and highly fault-tolerant. Since the service is distributed among various nodes, the damage to some nodes or the network has little impact on other parts.
        • High cost performance: The performance advantage is an important reason why P2P is widely concerned. The use of P2P architecture can effectively utilize a large number of common nodes scattered in the Internet, and distribute computing tasks or storage data to all nodes. Utilize the idle computing power or storage space to achieve high-performance computing and mass storage.
        • Privacy protection: In the P2P network, since the transmission of information is distributed between nodes without going through a centralized link, the possibility of eavesdropping and leakage of user's private information is greatly reduced.

1.4.3 Core part

1. The router plays a special role in the core part of the network .
image-1671554120057

2. Three exchange methods

  • Circuit Switching: The way a telephone switch connects
    image-1671554144507
    to a telephone line is called circuit switching. Telephone lines are connected on demand, greatly reducing the number of connected telephone lines

    From the perspective of communication resource allocation, switching (Switching) is to dynamically allocate transmission line resources in a certain way

    The three steps of circuit switching:

    • Establish a connection (allocate communication resources)
    • Call (constantly occupying communication resources)
    • Disadvantages of releasing the connection (returning communication resources)
      image-1671554233748
      circuit switching: when the user is inputting and editing a file to be transmitted, the communication resources used by the user are temporarily unused, and the communication resources cannot be used by other users. Line resources are wasted in vain, so the transmission efficiency of circuit switching is very low, and it is not suitable for communication between computers .
  • Packet Switching: The router is a key component to realize packet switching, and its task is to forward received packets, which is the most important function of the core part of the network

    • Packet switching uses store-and-forward technology . As shown in the figure below, a message is divided into several groups before transmission . Usually we call the entire block of data to be sent a message . Before sending the message, divide the long message into smaller equal-length data segments, for example, each data segment is 1024bit (bit) . In front of each data segment, add some headers consisting of necessary control information to form a packet . A packet is also called a " packet ", and the header of a packet is also called a " packet header ". A packet is a unit of data transmitted on the Internet. The "header" in the packet is very important. It is precisely because the header of the packet contains important control information such as destination address and source address that each packet can independently select a transmission path in the Internet and be delivered to The end point of the packet transmission.
    • packet switching process
      image-1671554452186
    • The characteristics of packet switching: each packet that constitutes the original message is stored and forwarded on each node router, and error checking can be performed to ensure the integrity and accuracy of the message.
      image-1671554501091
      image-1671554624210
  • Message Switching

    • The entire message is transmitted to the adjacent node first, and then it is stored in the forwarding table and forwarded to the next node.
    • There is no limit to the size of the message, so there is a requirement for the buffer space of the device receiving the message
      image-1671554746348
  • Comparison of the three exchange methods
    image-1671554790785

1.5 Classification of Computer Networks

1.5.1 Classification according to the scope of the network

  1. Wide Area Network WAN (Wide Area Network) : The scope of a wide area network is usually tens to several thousand kilometers, so it is sometimes called a long haul network. The WAN is the core part of the Internet, and its task is to transport data sent by hosts over long distances (for example, across different countries) . The links connecting the switches of each node in the WAN are generally high-speed links with large communication capacity.
    image-1671554868817

  2. MAN (Metropolitan Area Network) : The scope of the MAN is generally a city, which can span several blocks or even the entire city, and its operating distance is about 5~50k. A metropolitan area network can be owned by one or several units, but it can also be a public facility used to interconnect multiple LANs. At present, many metropolitan area networks adopt Ethernet technology, so it is often discussed in the scope of LAN sometimes.
    image-1671554911487

  3. Local area network LAN (Local Area Network) : Local area networks are generally connected by microcomputers or workstations through high-speed communication lines (the rate is usually above 10Mbit/s), but Digas is a local city network, but now the local area network is very right). In the early days of LAN development, a school or factory often had only one LAN, but now LANs are widely used, and most schools or enterprises have many interconnected LANs (such networks are often called campus networks or enterprise networks).
    image-1671554967984

  4. PAN (Personal Area Network): Personal area network is to connect personal electronic devices (such as portable computers, etc.) with wireless technology in the place where individuals work, and its range is very small, about 10m.
    image-1671555021304

1.5.2 Classification according to the line structure of the network

1. Star

image-1671555048280

  • The star topology is a topology commonly used in local area networks at present.
  • The star topology is a network that uses one node as the central node, and other nodes are directly connected to the central node. The central node can be a file server or a connection device. Common central nodes are hubs or routers.
  • The network of the star topology is a centralized control network, and the entire network is controlled and managed by the central node, and the communication between each node must pass through the central node. Each node that wants to send data will send the data to be sent to the central node, and then the central node is responsible for sending the data to the destination node. Therefore, the central node is quite complicated, and the communication processing burden of each node is very small, and only needs to meet the simple communication requirements of the link.
    image-1671555091013
  • advantage:
    • Controls are simple. Any site is only connected to the central node, so the media access control method is simple, resulting in a very simple access protocol. Easy network monitoring and management.
    • Fault diagnosis and isolation are easy. The central node can isolate the connection lines one by one for fault detection and location. The fault of a single connection point only affects one device and will not affect the entire network.
    • Convenient service. The central node can easily provide service and network reconfiguration to each site.
  • shortcoming:
    • A large number of cables are required, and the workload of installation and maintenance also increases sharply.
    • The central node has a heavy burden, forming a "bottleneck". Once a failure occurs, the entire network will be affected.
    • The distributed processing capacity of each site is low.

2. Bus type

image-1671555196851

  • All devices in the bus-type network topology are directly connected to the bus, and the medium it uses is generally coaxial cables (including thick cables and thin cables), but now optical cables are also used as the bus-type transmission medium.
  • The bus structure means that all workstations and servers are hung on the same bus, each workstation is equal, and there is no central node control. Both ends spread, just like the information transmitted by radio stations, so it is also called broadcast computer network. Each node checks the address when receiving information to see if it matches the address of its own workstation, and if it matches, it receives the information on the Internet.
  • The network characteristics of the bus structure are as follows:
    • Simple structure: each node of the network can be connected to the network through a simple wire tie (T head), and the construction is similar to connecting a TV antenna.
    • Small amount of wiring: The star network needs to separate the wires from the central hub to each network node. If the wires are not routed in the wire slot, the ground is often covered with bundles of wires.
    • The cost is low; the bus-type network does not need expensive network equipment such as hubs due to the small amount of wires used, and does not need structural layout materials such as wire slots and junction boxes, so the cost is much lower than that of the star-type network.
    • Flexible expansion: It is sometimes an extremely painful thing to increase the number of nodes in a star network. If the space left in the initial planning of the network is small, you may encounter the following situations. You may have to buy a switch because only one node is added. : And the bus-type network only needs to add a section of cable and a T head to increase a contact.
    • Fault diagnosis and isolation are more difficult: when a node fails, it is more convenient to isolate. Once the transmission medium fails, the entire bus needs to be cut off.
    • Data collisions are prone to occur, and line contention is more serious.

3. Ring type

image-1671555320594

  • The ring structure consists of several nodes in the network connected end to end through point-to-point links to form a closed ring. This structure makes the public transmission cable form a ring connection, and data is transmitted between nodes along one direction in the ring. Information is passed from one node to another.
  • The network form of this structure is mainly used in token ring . In this network structure, each device is directly connected in series through cables , and finally forms a closed loop. The information sent by the entire network is transmitted in this ring. Usually, the This type of network is called a " token ring network ".
  • In fact, in most cases, the network of this topology will not really connect all computers into a physical ring. Generally, the two ends of the ring are closed by an impedance matcher, because In the actual networking process, it is inconvenient to physically connect the two ends of the ring due to geographical restrictions.
  • What is Token Ring
    • The medium access control mechanism of the token ring network adopts the circulation method of the distributed control mode. In the token ring network, there is a token (Token) which is passed along the ring bus in a counterclockwise direction between the network node computers . The token is actually a frame in a special format, which does not contain information itself, and only controls the channel. Use to ensure that only one node can monopolize the channel at the same time. Tokens travel around the ring when all nodes on the ring are idle. The node computer can only send the data frame after getting the token, so there will be no collision. Because tokens are passed sequentially on the ring, access is fair to all computers connected to the network.
    • Tokens have two statuses "idle" and "busy" during work. "Busy" indicates that the token is not occupied, that is, there is no computer transmitting information in the network; "busy" indicates that the token is occupied, that is, information is being transmitted in the network. A computer wishing to transmit data must first detect the "idle" token, set it to a "busy" state, and then transmit data following the token. When the transmitted data is received by the destination node computer, the data is removed from the network and the token is reset to "idle"
      image-1671555453985

4. Mesh type

image-1671555484394

  • Mesh topology, this topology mainly refers to the interconnection of nodes through transmission lines, and each node is connected to at least two other nodes. Mesh topology has high reliability, but its structure is complex and expensive to implement High, difficult to manage and maintain, not commonly used in LAN
  • advantage:
    • The network reliability is high. Generally, there are two or more communication paths between any two node switches in the communication subnet. In this way, when one path fails, the information can be sent to the node through another path. switch.
    • The network can be formed into various shapes, using various communication channels, and various transmission rates.
    • The best path can be selected, and the transmission delay is small.
  • shortcoming:
    • The controls are complicated and the software is complicated.
    • The line cost is high and it is not easy to expand.
    • In Ethernet, if the setting is improper, it will cause a broadcast storm, and in severe cases, the network can be completely paralyzed.

1.6 Performance indicators of computer network

There are seven commonly used computer network performance indicators: rate, bandwidth, throughput, delay, round trip time, utilization rate, packet loss rate

1.6.1 Rate

  • The signals sent by the computer are in the form of binary numbers.
  • A binary digit is a bit (bit, binary digit)
  • Byte: Byte, 1Byte=8bit(1B=8b)
  • Commonly used data volume units:
    image-1671555641783
  • Rate: The rate at which a host connected to a computer network transmits bit data on a digital channel, also known as bit rate or data rate
    image-1671555722946
  • think:
    image-1671555753668

1.6.2 Bandwidth

  • In computer networks, bandwidth is used to represent the ability of a certain channel in the network to transmit data, so the network bandwidth represents the "highest data rate" that a certain channel in the network can pass within a unit of time
  • Unit: b/s(kbs,Mb/s,Gb/s,Tb/s)
  • The broadband bandwidth is 100M: the export network speed is up to 100Mb/s

1.6.3 Throughput

  • Throughput represents the amount of data passing through a network (or channel, interface) per unit time
  • Throughput is often used as a measure of real-world networks to know how much data is actually going through the network.
  • Throughput is limited by the bandwidth or rated rate of the network.
    image-1671555831130
    Pay attention to the difference between throughput and bandwidth: bandwidth refers to the maximum transmission speed, while throughput refers to the actual transmission speed

1.6.4 Latency

  • Latency (delay or latency) refers to the time required for data (a message or packet, or even bits) to be transmitted from one end of the network (or link) to the other. Latency is a very important performance indicator, it is sometimes called delay or delay.
    image-1671555889612
  • Latency in a network is made up of several different components:
    • sending delay
      • The time required for a host or router to send a data frame is the time from the first bit of a data frame to the time when the last bit of the frame is sent.
      • The formula for calculating the sending delay is:
        image-1671555950005
      • The sending rate of the host is related to the sending rate of the network card, the bandwidth of the channel, and the interface rate
        image-1671555973241
    • propagation delay
      • The time it takes for an electromagnetic wave to travel a certain distance in a channel
      • The formula for calculating the propagation delay is:
        image-1671556045889
      • The speed of propagation of each medium:
        image-1671556067978
    • processing delay
      • Processing latency refers to the time it takes for a host or router to receive a packet. For example, analyze the header of the packet, extract the data part from the packet, find the appropriate route, and so on.

1.6.5 Round trip time

  • RTT (Round-Trip Time) round-trip time is an important performance indicator in computer networks. Indicates the total elapsed time from when the sender sends data to the transmission medium to when the sender receives an acknowledgment from the receiver (not including the sending delay).
  • RTT is determined by three parts: the propagation time of the link, the processing time of the end system, and the queuing and processing time in the cache of the router. The values ​​of the first two parts are relatively fixed as a TCP connection, and the queuing and processing time in the cache of the router will change with the change of the congestion degree of the entire network. Therefore, changes in RTT reflect changes in network congestion to a certain extent.
  • For example, A sends data to B. If the data length is 100MB and the sending rate is 100Mbit/s, then
    image-1671556185825
  • If B has correctly received the 100MB of data, it will immediately send a confirmation to A. Also assume that A can only continue to send data to B after receiving B's confirmation message. Obviously, this needs to wait for a round-trip time TT (here, it is assumed that the confirmation information is very short, and the time for B to send the confirmation can be ignored). If the return time = 2s, then it can be calculated that the effective data rate of A sending data to B is 80Mbit/s. Much smaller than the original data rate of 100Mbit/s
    image-1671556227152

1.6.6 Utilization

  • There are two types of utilization: channel utilization and network utilization.
    image-1671556265953
  • According to queuing theory, when the utilization rate of a channel increases, the delay caused by the channel will also increase rapidly.
  • If let Do represent the delay when the network is idle, and D represent the current delay of the network, then under appropriate assumptions, the following simple formula can be used to express the relationship between D, Do and the utilization rate U as follows
    image-1671556295069
    : A simple formula to express the relationship between D, Do and utilization rate U is:
    • Here U is the utilization of the network, the value is between 0 and 1:
    • When the utilization rate of the network reaches 50%, the delay will be doubled; when the utilization rate of the network exceeds 50%, the delay will increase sharply;
    • When the utilization rate of the network is close to 100%, the delay tends to infinity:
    • Therefore, some SPs with larger backbone networks usually control their channel utilization not to exceed 0%. If it exceeds, it is necessary to prepare for expansion and increase the bandwidth of the line;
      image-1671556387152
      therefore, the higher the channel utilization rate, the better.

1.6.7 Packet loss rate

  • The packet loss rate is the packet loss rate, which refers to the ratio of the number of packets lost during transmission to the total number of packets within a certain time range .
  • Packet loss rate is a network performance indicator that network operation and maintenance personnel are very concerned about, but ordinary users often don't care about this indicator because they are usually unaware of network packet loss.
  • There are two main cases of packet loss:
    • Bit errors occurred in the packet during transmission and were discarded by the node
      image-1671556451822
      The packet sent by the host had a bit error during transmission. When the packet entered the node switch in the transmission path, the node switch detected the bit error. and then discarded.

    • Packets are discarded when they arrive at a packet switch with a full queue: this can cause network congestion during periods of high traffic
      image-1671556499321

    • Assume that the current input buffer of router R is full, and the packet sent by the host arrives at the router at this time. The router has no memory to stage the packet and can only discard it. Actually. According to its own congestion control method, the router will actively discard packets when the input buffer is not full.

    • Therefore, the packet loss rate reflects the congestion of the network: when there is no congestion, the packet loss rate of the path is 0

    • Path packet loss rate is 1%~4% when mildly congested

    • Path packet loss rate is 5%~15% when severe congestion

Guess you like

Origin blog.csdn.net/qq_49619863/article/details/128392015