OSI network layer basic functions

Source: Internet
Author: User

The basic functions of the OSI network layer the network layer needs to execute four basic tasks: Addressing, encapsulating, unencapsulating, and routing with IP addresses. The first three items are easy to understand. routing is the most complex and technical part. 1. Grouping hosts into networks is very social. To facilitate management, hosts are grouped according to certain characteristics. When grouping, refer to three aspects: 1. Geographical Location 2. Specific purposes-different host uses different network requirements, such as e-commerce and art design. 3. Ownership-security considerations. 2. The benefits of dividing hosts into networks as the network grows, some column problems will also arise, such as performance degradation, security issues, and address management. Dividing a network into multiple interconnected small subnets can at least partially alleviate these problems. 1. Improve Performance-for example, dividing hosts with different attributes into different small networks facilitates broadcast. 2. Security: benefits of dividing networks by permissions. 3. implement hierarchical addressing-The address is divided into two parts: the network address and the host address. The network addressing can be divided into three layers, and the hierarchical addressing also improves the routing efficiency. 3. (default) Gateway: the egress of the network can be similar to that of the Customs. As a device parameter, each host has a specified default gateway address. A gateway is essentially an IP address from a network to another network (the IP address of a machine with a routing function ). When data packets are transmitted, the host in the network knows the address of the device in the network. If you need to transmit data packets to the Internet, the host does not know the destination address, so the data packets are sent to the default gateway. A host can have only one gateway for one Nic. 4. router routing definition: the router is responsible for determining the forwarding of each packet that arrives at the gateway interface. This forwarding process becomes a route. Router route table: the routes in the route table have three main features: destination network, next hop, and measurement (number of hops ). You can use the show ip route command on the vro。 console to view the route table. Host route table: run the "route print" or "netstat-r" command to view the host route table. 5. packet forwarding routes are completed one by one (data packets are sent from one route to another. Check the destination address of the package on each hop router, and then check the route table to find the forwarding information. The Router performs one of the following operations on the data packet: 1. Forward the next hop route 2. Forward the data packet to the target host 3. Discard the router and perform the following steps to determine the operation. 1. As an intermediate device, the router processes data packets at the network layer. However, the data packets arriving at the router interface are encapsulated as data link layer PDUS. The router must discard the layer-3 encapsulation before checking the data packets. 2. Check the IP address. 3. Search for matching items in the route table. 4. Select the next hop. 5. Then, the Router performs one of the following operations. Scenario A: vro forwards data packets. If the route that matches the destination network of the packet is a remote network, the packet is forwarded to the interface indicated by the route, which is encapsulated by the layer-3 protocol and then sent to the next hop address. If the destination network is a direct connection network, the data packet is first encapsulated by the layer-3 protocol and then sent to the correct local network interface. Scenario B: the router uses the default route. If no specific route entry in the route table is used for the incoming data packet, the data packet is forwarded to the interface indicated by the default route. Scenario C: the router discards data packets. If the packet is discarded, the IP does not specify that the packet is returned to the previous vro. This function reduces protocol efficiency and increases overhead. Other protocols are required to report such errors. 6. How to learn about a router the router requires information from other networks to build a reliable route table. The network and route are constantly changing. Router learning routing is divided into two ways: Static Routing-manually configure routing information. Advantages: 1. There is no overhead for processing data packets; 2. It is generally reliable. Disadvantage: fields cannot be updated, which requires continuous management costs. Dynamic Routing-in the same Internet, the router can dynamically learn route information from other routers. Advantage: no management cost. Disadvantage: the router processing overhead is required. The bandwidth overhead is increased when route information is exchanged. Updates accepted by the Protocol must be calculated by complex algorithms before they can be applied to the route table.
 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.