Android use SHARESDK One-click to share

Source: Internet
Author: User

Note : This article is only for learning Exchange, reprint please indicate the source, welcome reprint! This article is a summary of the following documents related content : 1. "TCP/IP Detailed volume 1" 2. "TCP/IP protocol family" 3. The 5th edition of computer network OSPF(Open Shortest path first opening shortest path priority )is an IGP (internal Gateway Protocol) protocol that is used primarily as an in-house (autonomous system). The protocol is based on aLink State, and RIP is based on theDistance Vectorprotocol, in the lower-level implementation of the two algorithms, RIP uses theBellman-ford Algorithm(Bertelsmann Ford algorithm), while OSPF uses theDijkstra Algorithm(Dijkstra Algorithm). RIP passes some or all of a router's routing tables toneighboring routers, and OSPF uses the flooding method to pass its LSP (link state Packet link status pack) toall routers in the same area. in the above description, I first explain the following two nouns: link State , flood method . link State : Used to describe which routers are adjacent to each router, and the "metrics" for that router. Metrics can represent costs, distances, experiments, bandwidth, and so on. Note: The message sent by the OSPF protocol is the link state of all routers that are adjacent to this router, and the RIP protocol sends a message that is the distance to all networks and the next hop router. flooding means that routers send messages to all neighboring routers through all the output ports. Each neighboring router then sends the message to all of its neighboring routers (but no longer sends it to the router that just sent the message). In this way, eventually all routers in the entire region get a copy of this message, so OSPF is always faster than RIP convergence .     note : for OSPF protocol only when the link state changes, the router wants all other routers to send this message by flooding, and for the RIP protocol, regardless of whether the network topology has changed, Routing information is exchanged periodically between routers. OSPF packets mainly include: greeting pack Hello, Database description packet DBD, link State Request Package LSR, link status update package LSU and link status acknowledgment package Lsack five different types. these five types of data contain the same OSPF header, as follows:
version: The version of the OSPF protocol, which occupies 8 bits; Type: 8-bit, type of OSPF,; message length : 16 bits, total OSPF message length (including header); Source IP: The IP address of the router that accounted for 32 bits, which sent the packet; Area identification : 32 bits, because OSPF divides an as into smaller areas , each region corresponds to an ID called a region identifier, in dotted decimal notation, the ID of the backbone area is 0.0.0.0 ; Inspection and : accounted for 16 bits, for error testing; identification Type : 16 bits, identification type used in the area, 0 for no authentication, and 1 for password. identification: Occupy the position, store the identification data. If the authentication type is 0, fill in 0, and if the authentication type is 1, the field is filled with a password of 8 characters. The advantage of dividing a region is that the range of information used to make use of the flood exchange link is limited to each region and the second is not the whole as, thus reducing the amount of traffic on the entire network. these 5 types of packets are described in detail below. I. Greeting Pack HELLO OSPF uses the Hello packet to establish a neighbor relationship and test the accessibility of the neighboring station. Before the router can flood the neighboring station information about it to other routers, it must first greet the neighboring station. To determine whether these neighboring stations are working and whether they can be reached. OSPF Specifies that each of the two neighboring routers is exchanged for a greeting packet every 10s to know if the other party is accessible, because only the link state information of the adjacent station is stored in the link state database . The following types of packets are used to synchronize the link state database. Synchronization refers to the same content of the link-state database for different routers. ii. Database Description Package DBD when the router is connected to the system, it sends a Hello packet and greets its neighbor. If these neighboring stations are the first to receive information about the router, they send a database description message, which does not contain the complete database information, but gives a summary (the title of each row in the database). The router on the new connection examines these headers and finds out which lines of information it has not yet, and then sends one or more link-state request messages in order to get complete information on this particular link. Note: The link state database is actually a topology diagram of the entire network. This topology diagram is consistent across the network (known as the synchronization of the link state database). Each router uses the data from the link state database to construct its own routing table (by using the Dijstra algorithm). and the RIP protocol of each router only know the distance of all the network and the next router, but do not know the whole network topology, only know the distance is how much, but the specific how to walk is not known, because it knows the neighboring router information, only to the next hop to know how to go next. iii. Link -state request Group LSR The details of some link-state items that are requested to be sent to each other. iv. Link -state acknowledgement grouping lsack OSPF forces the router to confirm the packets received for each link state update, making routing more reliable.       v. Link-State Update group LSU LSU is the core of the entire OSPF operation, which routers use to advertise their link state information to neighboring stations. In the process of network operation, only one route of the link state changes, the router uses link state Update packet LSU, with flooding method to update the link state to the whole network. OSPF uses a reliable flooding method, where reliable refers to the router after receiving the update packet LSU to send a confirmation, of course, duplicate update packet value must send a confirmation. the point of the OSPF drip: 1.OSPF directly with the IP datagram delivery, corresponding IP datagram Header protocol field is 89, and RIP is UDP, the corresponding port number is 520. 2. All packets exchanged directly on the OSPF router have the authentication function, thus ensuring that link state information is exchanged only between trusted routers. 3.OSPF supports subnets. 4. Because OSPF converges fast, there is no "bad news transmission Slow" problem, which is exactly the opposite of RIP. 5. The OSPF protocol is used more for larger networks, and RIP is used more for smaller networks.
Related Article

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.