Network Connectivity1. Important terminologies
1) Link Device connection. The link itself can be wired or wireless.
2) node device. Computers, laptops, and mobile phones can all be node.
3) point-to-point only connects two devices.
4) more than two devices connected by multiple access. The link that multiple devices access at the same time.
5) switched network
-> The circuit must be established before Circuit Switched communication. There is a real physical line, and the line may be connected by multiple switches.
-> When packet switched transfers data, it splits the data into packages and drops each packet to the network for switch. That is to say, the data exchange unit is packet.
6) original message. Relatively large, relatively long.
Packet is the unit after the message is split. The network may not be able to process data that is too big or too long to be directly transferred to the network.
7) store-and-forward
When a network device processes a packge, it usually collects it first (store) and then checks who the packge is going to be sent to (when we receive a packge on the network, be sure to check who the packge will be sent to. Note that there will be information on the packge ), therefore, we need to go to The lookup table (this table will be available in the router or switcher). After the lookup table, we will know the port from which the packet needs to be sent to a certain destination. To sum up, we will first store the packge, then look up the table to find the port from which the packge is transferred out (forward ). For every packet that comes in, network devices (such as routers) are processed as: receiving, querying, and forwarding.
There are usually many ports between vswitches and vrouters. There are dozens of ports, and there are more than 20 Ports and even more than 100 ports. If a lot of packets come in at once, there is actually a great test on the device. Packets are stored in the memory of the device. If the packet comes in quickly, will it cause the loss to be stored because the memory is not large enough? Also, the packet comes in quickly, however, the transfer speed from the port is slow (the port has its own transmission rate, for example, Ethernet is usually a little faster, and wireless is slow). It will also handle loss packets (a large number of packets are received from the fast link, when these packets want to be switched to a slow network, the problem may occur. That is to say, if the incoming packets are too large to be digested, the queue must be put in the so-called buffer (in memory). However, if the incoming packets are still too fast, the process will be too slow, then the queue will pop up, and the packet cannot be fully retained, and the packet will be dropped)
8) hosts host.
9) switches
Vswitch. Generally, a vswitch is a Layer2 device. However, there will also be switches for layer3 and layer4. There are usually many switches on the network. We usually connect them to a loop state, because the loop can increase the network reliability during network operation. For example, if a link on the network is disconnected or a switch is deprecated, we do not want the network to be disconnected or isolated.
However, the loop itself may cause two problems during package transfer. First, because of a loop, our package may circle the network several times or even receive it several times. The second is that the package will perform address learning during transmission to learn where the host is. If there is a loop, it will make the address learning error. Let's talk about it later.
10) spanning tree
To keep the network running, do not have a loop for the time being. The network will first create a spanning tree structure. The link in red is a spanning tree.
Figure 1 A Switched Network
In a tree structure, any two nodes have a unique path. This path is the path of our package. Therefore, the Spanning Tree itself provides our routing path.
Figure 1 is a switched network. We use a switch to connect many hosts. Such a network is called a regional network because it is confined to a relatively small area. The entire Internet is very large, and we need to connect the whole world.
11) Internetwork
If many networks are connected, they are called Internetwork. That is to say, many networks are connected again, and each network is a network as shown in Figure 1.
12) router/Gateway
The device connecting the network is a router or gateway.
Figure 2 interconnection of networks
Internetwork is used to connect many networks. In our real world, Internetwork is used.
13) Host-to-host connectivity
Connect two hosts that may be in a very distant location to the network. The connection between them is the so-called host-to-host connectivity.
14) Address
Each computer or network card must have a location, which we call address. Only in this way can we know who it is and where it is.
The address of the NIC is MAC address.
The host address is called IP address.
15) routing
On the Internet, how do we find a path and send my package to the other party.
16) unicast/broadcast/Multicast
The sent package is divided into unicast, broadcast, and multicast.
Unicast indicates that the package is only for a specific object.
Multicast indicates that a package is thrown to multiple objects.
Broadcast indicates that the package is thrown to all objects. Generally, broadcast is only formed in a region network. Generally, the router blocks the broadcast. Otherwise, a broadcast will paralyze the whole world.
17) LAN (Local Area Networks)
18) MAN (Metropolitan Area Networks)
19) Wan (Wide Area Networks) 2. How many rams are delivered in an Internet?
Datax,Data PackageThe minimum data transmission unit in the package switched network.
Rfc_1594 defines a data package as follows: a self-complete and independent data entity carries enough information. It can select a path from the source and finally reach the target computer, instead of relying on the starting computer, the destination computer, or the transmission network for pre-exchange information. (From Wikipedia)
Figure 3 How many rams are delivered in an Internet?
The network status is changing at any time, and the path for one packet transfer is not fixed. You can exchange information between routers so that you can know which side is faster and which side is congested.
The router can split large packets into small packets. Why is it necessary to split it into small packets? Because each network has a packet upper limit, its value varies with different networks. For example, for Ethernet, the upper packet limit is 1518 bytes, while for wireless networks, the upper packet limit is 2312 bytes. If the packet size is large, we need to cut it into small packets when entering a network and find that the packet size cannot be entered.
The method of cutting into small packets is to cut the content into small segments, and package the content into packets for each small segment after cutting. For example, if you want to send a letter, but the content of the letter is too heavy, we will naturally divide the letter into multiple ones. However, for the separation of letters, we only split the content. After the separation, each letter still needs a complete envelope. Of course, each letter cannot be overweight (for packets, it cannot exceed the packet upper limit of the network to be transmitted ). After that, each piece of separated mail can be delivered to the destination through different routes by different postman (for the split packet, can be delivered by different routes to destination ).
The first packet may be bypassed on the Internet, but will arrive at destination later. The second packet may have a non-blocking path and will soon arrive at destination. Therefore, the first delivery may not come first.
What's more serious is that packets may be wrapped around the Internet, but they cannot be bypassed. For example, this may happen when the network is on the other side. Therefore, we have such a mechanism: every time a packet goes through a router when it is on the Network (Note: It depends on the router ), the number of packets is reduced by 1. When the number is reduced to 0, the packets are discarded. Therefore, the Internet itself is unrelible. If you throw a packet to it, it just serves us as much as possible to deliver the packet to the other party. It does not rule out the possibility that the packet will be dropped.
One of the reasons for packet loss is that, as mentioned above, packets cannot be bypassed for too long in the network, and the router is lost. The simpler reason is that a router connects two networks that are not used at a speed, for example, a LAN, which is faster, and a WAN, Which is slower. If the number of packets sent from the LAN to the router is large, and the forwarding speed from the router is slow, the packets will be temporarily stored because they cannot be sent out. If the storage time is too long or the incoming traffic is too large, the router will not be able to retain the packets because the router memory will be full, and the packets will be dropped. Therefore, the Internet itself is not reliable. It is best effort to help us send the packets, but in case the packets are lost by the network, the so-called unreliable means that the packets are lost. So far, our Internet is like this.
If the packets we want to transmit are very important, we need to find a way to ensure the packets are delivered. TCP can be reliable. 3. Cost-valid tive Resource Sharing (How can resources on the network be effectively shared ?)
1) Resource: links and nodes
Figure 4 multiplexing multiple logical flows over a single physical link
In Figure 4, the green links between switches belong to the resource to be shared, and the router and switch also belong to nodes and resource.
2) how to share a link?
A) multiplexing
Multiplexing is a specialized term in the field of communication and computer networks. without ambiguity, "multiplexing" can also be called "multiplexing ". Multiplexing usually indicates the process and technology of transmitting multiple signals or data streams over a channel. (From wiki)
OFDM: Frequency Division Multiplexing (Frequency Division Multiplexing)
For example, in this figure, the bandwidth is divided into four parts, that is, there are four channels. The bandwidth of each channel is only 1/4 of the original, but these four users can transmit packets at the same time, it's just a little slower. Each user has a dedicated channel. We split frequency (devide), so it is called frequency score.
Synchronous time-division multiplexing (TDM time division multiplexing)
Devide the time, and different users send packets at different time periods (here, the user uses the entire link bandwidth in each time period ).
Note: Both OFDM and TDM are Multiplexing technologies, but the biggest problem is: In case of load imbalance, for example, some users want to send a lot of information, while some users want to send a little, no, even in this case, channels or time periods cannot be borrowed (after the allocation is started, it is fixed), so the efficiency is still relatively poor.
Is there any technology that allows a small amount of data to be transferred through resources? SeeStatistical Multiplexing.
B) inverse process of de-multiplexing
C) Statistical Multiplexing (count multiple workers)
In this figure, multiple stations share the link marked with green crude lines.
-> Data is transmitted based onDemand of each flow.
-> What is a flow?
Flow, that is, traffic. Its definition is not fixed. Flow can be all the traffic between two hosts, but it is only the traffic between two applications, such as Skype.
-> FIFO, round-robin, priorities (Quality-of-Service (QoS ))
These mechanisms are used by vswitches.
FIFO: First-in-first-out. Each host has packets. Advanced packets are first sent out, using all the bandwidth of link. When the workload is almost large, the resources used by everyone are average. When some users have an hourly load, the bandwidth can be used by users with high loads. This is a relatively fair practice.
Round-Robin: Each user's packet enters the switch, there is a queue. Each queue sends packets in turn. Fairness.
Priorities: You can also set a priority for the queue. The priority is higher than the priority. For example, for video conferencing, packets must be sent first to ensure QoS services. However, this is not the case for OFDM and TDM.
-> Congested? (Congestion ?)
The packet will be dropped, but which one will be dropped will have a specific policy. I will discuss it later. 4. Logical Channels
Establishing a line between two hosts belongs to the logical channels, because there will be no physical connections, and the packets are generally transmitted using different paths.
5. Network Reliability
Network shocouldHide the errors.
1) bits are lost
-> Bit errors (1 to A 0, and vice versa)
-> Burst errors-several consecutive errors
Our data is transmitted by a bit during transmission, while the link we transmit is generally a coaxial cable, optical fiber or wireless. Coaxial Cables use voltage levels to indicate 0 and 1, which are prone to interference by the electric field and error occurs. The brightness intensity of optical fibers indicates 0 and 1, while that of wireless cables is 0 and 1 with the strength of electromagnetic waves, it is prone to electromagnetic interference and an error occurs.
2) packets are lost (congestion)
3) links and node failures
The link may be disconnected. If a node, such as a router, is out of service or the device fails
4) messages are delayed
The packet is bypassed in the network, and it is delay.
5) messages are delivered out-of-order
Packets may be bypassed in the network, and the delivery order may be inconsistent. This may happen when packets are sent first or then sent first.
6) third parties eavesdrop
Our packages all follow the store-and-forward mechanism, that is to say, store first, as long as it is in memory, it may be tampered with by a third party.Network Architecture????1. Example ofLayered Network System
Let's take a look at an example to divide the simple and rough network structure into four layers, for example:
The bottom isHardwareThat is, the so-called hardware layer, which is generally a network device or a connected device, including link, Nic, and reason. We will simplify the entire network to a so-called hardware.
The layer above hardware isHost-to-host connectivity.Because the purpose of our network is to allow the two hosts to connect, we can imagine at the upper layer of hardware that we have two hosts to connect for communication, therefore, host-to-host connectivity indicates that communication can be performed between two hosts.
On our host, we run many applications at the same time. Each application may create several connections and change them into communication between process and process. Therefore, the upper layer of host-to-host connectivity isProcess-to-process Channels.
The top is the so-calledApplication programs.2. Protocols
Under the concept of hierarchy, a very important element or a very important mechanism is protocols, a protocol (or a communication protocol ).
So why protocol? This is because our network connects many different hosts or devices. How can I see the information I sent when I send my documents to the other party? In other words, we need to allow communication between the host and the host. communication means to throw packets to the other party. Why can the other party understand the packets? Therefore, the format of the packets must be consistent. Not only is the format consistent, but the packet communication process should also be correct. For example, if you throw the first packet to me, what packets will be returned after I see it, you can see what packets will be returned after I return them. Therefore, we must develop a protocol for communication between the two parties. If everyone complies with this agreement, they can communicate. If you do not follow this agreement, you may not be able to read the information I sent you, or interpret the information incorrectly.
1) Protocol defines the interfaces
-> The layers in the same system and
-> The layers of Peer System
2) Protocols areBuilding BlocksOf a Network Architecture
3) each protocol object has two different interfaces
-> Service Interface: operations on this Protocol
-> Peer-to-peer interface: messages exchanged with peer
4) protocol specification (Protocol Specification)
Pseudo-code)
State Transition divisor (state transition diagram)
Message format)
Note: even if there is a clear protocol specification, each company or engineer will actually (write as a program), it is usually different. Interoperable is called when two or more implementations can communicate with each other.
5) interoperable
When two or more protocols that implement the specification accurately
6) IETF: Internet Engineering Task Force
Define Internet standard protocols
There are too many protocols. We need dedicated organizations to develop standards. 3. protocol architecture
4. Encapsulation
5. OSI Architecture
Divide network functions into seven layers.
Physical Layer (entity layer)
How do two hosts send data to each other? Through wired or wireless media, such as coaxial cable and optical fiber. Therefore, physical layer mainly discusses how to send signals (Binary) to the other party.
Data Link Layer)
Sending data to destination usually goes through many networks. The data link layer discusses how to send data (FRAME) One step forward. For example, there are many router in the middle, each of which is sent to a router, data Link Layer
Network Layer)
This article discusses how to send a package to the other party, that is, to the farthest destination, which is farther than the data link layer. The data link layer sends a route while the network layer sends a route.
Transport Layer)
Each host runs many different applications, such as browser, Skype, online game, and file transfer. Each application has different requirements when using the network. For example, when transferring files, the network must be very reliable (because the file content cannot be wrong); if you are viewing a vedio (such as YouTube ), during the transfer of this YouTube package, we can tolerate a little bit of errors, because the human hearing and vision are not sensitive to a little bit of errors.
The transport layer is responsible for transmitting data to the other party, which is reliable and unreliable.
(To be continued)
Introduction to network architecture and layer-7 reference modes (to be continued, updated this week)