Difference between revisions of "Маршрутизация"

From Ilianko
Line 12: Line 12:
  
  
Routing, in a more narrow sense of the term, is often contrasted with bridging in its assumption that network addresses are structured and that similar addresses imply proximity within the network. Because structured addresses allow a single routing table entry to represent the route to a group of devices, structured addressing (routing, in the narrow sense) outperforms unstructured addressing (bridging) in large networks, and has become the dominant form of addressing on the Internet, though bridging is still widely used within localized environments.
 
  
 +
Most routing algorithms use only one network path at a time, but multipath routing techniques enable the use of multiple alternative paths.
  
In packet switching networks, routing directs [[packet forwarding]], the transit of logically addressed packets from their source toward their ultimate destination through intermediate [[Node (networking)|nodes]], typically hardware devices called [[Router (computing)|routers]], [[Bridging (networking)|bridges]], [[gateway (telecommunications)|gateways]], [[Firewall (computing)|firewalls]], or [[network switch|switches]]. General-purpose [[computer]]s can also forward packets and perform routing, though they are not specialized hardware and may suffer from limited performance. The routing process usually directs forwarding on the basis of [[routing table]]s which maintain a record of the routes to various network destinations. Thus, constructing routing tables, which are held in the router's [[Computer storage|memory]], is very important for efficient routing. Most routing algorithms use only one network path at a time, but [[multipath routing]] techniques enable the use of multiple alternative paths.
+
Routing, in a more narrow sense of the term, is often contrasted with bridging in its assumption that network addresses are structured and that similar addresses imply proximity within the network. Because structured addresses allow a single routing table entry to represent the route to a group of devices, structured addressing (routing, in the narrow sense) outperforms unstructured addressing (bridging) in large networks, and has become the dominant form of addressing on the Internet, though bridging is still widely used within localized environments.
 
 
Routing, in a more narrow sense of the term, is often contrasted with [[bridging (networking)|bridging]] in its assumption that [[network address]]es are structured and that similar addresses imply proximity within the network. Because structured addresses allow a single routing table entry to represent the route to a group of devices, structured addressing (routing, in the narrow sense) outperforms unstructured addressing (bridging) in large networks, and has become the dominant form of addressing on the Internet, though bridging is still widely used within localized environments.
 
 
 
==Delivery semantics==
 
{{routing scheme}}
 
Routing schemes differ in their delivery semantics:
 
* [[unicast]] delivers a message to a single specific node
 
* [[Broadcasting (computing)|broadcast]] delivers a message to all nodes in the network
 
* [[multicast]] delivers a message to a group of nodes that have expressed interest in receiving the message
 
* [[anycast]] delivers a message to any one out of a group of nodes, typically the one nearest to the source
 
* [[geocast]] delivers a message to a geographic area
 
 
 
Unicast is the dominant form of message delivery on the Internet, and this article focuses on unicast routing algorithms.
 
 
 
==Topology distribution==
 
In a practice known as [[static routing]] (or non-adaptive routing), small networks may use manually configured routing tables. Larger networks have complex [[network topology|topologies]] that can change rapidly, making the manual construction of routing tables unfeasible. Nevertheless, most of the [[Public Switched Telephone Network|public switched telephone network]] (PSTN) uses pre-computed routing tables, with fallback routes if the most direct route becomes blocked (see [[routing in the PSTN]]). [[Adaptive routing]], or dynamic routing, attempts to solve this problem by constructing routing tables automatically, based on information carried by [[routing protocol]]s, and allowing the network to act nearly autonomously in avoiding network failures and blockages.
 
 
 
Examples of adaptive-routing algorithms are the Routing Information Protocol ([[Routing Information Protocol|RIP]]) and the Open-Shortest-Path-First protocol ([[OSPF]]). Adaptive routing dominates the Internet. However, the configuration of the routing protocols often requires a skilled touch; networking technology has not developed to the point of the complete automation of routing.{{Citation needed|date=October 2011}}
 
 
 
===Distance vector algorithms===
 
{{main|Distance-vector routing protocol}}
 
Distance vector algorithms use the [[Bellman-Ford]] algorithm. This approach assigns a number, the ''cost'', to each of the links between each node in the network. Nodes will send information from point A to point B via the path that results in the lowest ''total cost'' (i.e. the sum of the costs of the links between the nodes used).
 
 
 
The algorithm operates in a very simple manner. When a node first starts, it only knows of its immediate neighbours, and the direct cost involved in reaching them. (This information, the list of destinations, the total cost to each, and the ''next hop'' to send data to get there, makes up the routing table, or ''distance table''.) Each node, on a regular basis, sends to each neighbour its own current idea of the total cost to get to all the destinations it knows of. The neighbouring node(s) examine this information, and compare it to what they already 'know'; anything which represents an improvement on what they already have, they insert in their own routing table(s). Over time, all the nodes in the network will discover the best next hop for all destinations, and the best total cost.
 
 
 
When one of the nodes involved goes down, those nodes which used it as their next hop for certain destinations discard those entries, and create new routing-table information. They then pass this information to all adjacent nodes, which then repeat the process. Eventually all the nodes in the network receive the updated information, and will then discover new paths to all the destinations which they can still "reach".
 
eg RIPV1,RIPV2
 
 
 
===Link-state algorithms===
 
{{main|Link-state routing protocol}}
 
When applying link-state algorithms, each node uses as its fundamental data a [[map]] of the network in the form of a [[graph (mathematics)|graph]]. To produce this, each node floods the entire network with information about what other nodes it can connect to, and each node then independently assembles this information into a map. Using this map, each router then independently determines the least-cost path from itself to every other node using a standard [[Shortest path problem|shortest paths]] algorithm such as [[Dijkstra's algorithm]]. The result is a [[Tree (graph theory)|tree]] rooted at the current node such that the path through the tree from the root to any other node is the least-cost path to that node. This tree then serves to construct the routing table, which specifies the best next hop to get from the current node to any other node.
 
 
 
===Optimised Link State Routing algorithm===
 
{{main|Optimized Link State Routing Protocol}}
 
A link-state routing algorithm optimised for [[mobile ad-hoc network]]s is the ''Optimised Link State Routing Protocol (OLSR)''.<ref>RFC 3626</ref> OLSR is proactive; it uses Hello and Topology Control (TC) messages to discover and disseminate link state information through the [[mobile ad-hoc network]]. Using Hello messages, each node discovers 2-hop neighbor information and elects a set of ''[[multipoint relay]]s'' (MPRs). MPRs distinguish OLSR from other link state routing protocols.
 
 
 
===Path vector protocol===
 
{{main|Path vector protocol}}
 
Distance vector and link state routing are both intra-domain routing protocols. They are used inside an [[Autonomous system (Internet)|autonomous system]], but not between autonomous systems. Both of these routing protocols become intractable in large networks and cannot be used in [[Inter-domain]] routing. Distance vector routing is subject to instability if there are more than a few hops in the domain. Link state routing needs huge amount of resources to calculate routing tables. It also creates heavy traffic due to flooding.
 
 
 
Path vector routing is used for inter-domain routing. It is similar to distance vector routing. In path vector routing we assume there is one node (there can be many) in each autonomous system which acts on behalf of the entire autonomous system. This node is called the speaker node. The speaker node creates a routing table and advertises it to neighboring speaker nodes in neighboring autonomous systems. The idea is the same as distance vector routing except that only speaker nodes in each autonomous system can communicate with each other. The speaker node advertises the path, not the metric of the nodes, in its autonomous system or other autonomous systems.
 
Path vector routing is discussed in RFC 1322; the path vector routing algorithm is somewhat similar to the distance vector algorithm in the sense that each border router advertises the destinations it can reach to its neighboring router. However, instead of advertising networks in terms of a destination and the distance to that destination, networks are advertised as destination addresses and path descriptions to reach those destinations. A route is defined as a pairing between a destination and the attributes of the path to that destination, thus the name, path vector routing, where the routers receive a vector that contains paths to a set of destinations.
 
The path, expressed in terms of the domains (or confederations) traversed so far, is carried in a special path attribute that records the sequence of routing domains through which the reachability information has passed.
 
 
 
===Comparison of routing algorithms===
 
[[Distance-vector routing protocols]] are simple and efficient in small networks and require little, if any, management. However, traditional distance-vector algorithms have poor [[Convergence (routing)|convergence]] properties due to the [[count-to-infinity problem]].
 
 
 
This has led to the development of more complex but more scalable algorithms for use in large networks. Interior routing mostly uses [[link-state routing protocol]]s such as [[OSPF]] and [[IS-IS]].
 
 
 
A more recent development is that of loop-free [[distance-vector protocols]] (e.g., [[EIGRP]]). Loop-free distance-vector protocols are as robust and manageable as native distance-vector protocols, but avoid counting to infinity, and have good worst-case [[Convergence (routing)#Convergence time|convergence times]].
 
 
 
==Path selection==
 
Path selection involves applying a [[Metrics (networking)|routing metric]] to multiple routes, in order to select (or predict) the best route.
 
 
 
In the case of computer networking, the metric is computed by a routing algorithm, and can cover such information as [[Bandwidth (computing)|bandwidth]], [[network delay]], [[hop count]], path cost, load, [[MTU (networking)|MTU]], reliability, and communication cost (see e.g. [http://rainer.baumann.info/public/tik262.pdf this survey ] for a list of proposed routing metrics). The routing table stores only the best possible routes, while [[link-state]] or topological databases may store all other information as well.
 
 
 
Because a routing metric is specific to a given routing protocol, multi-protocol routers must use some external heuristic in order to select between routes learned from different routing protocols. [[Cisco]]'s routers, for example, attribute a value known as the [[administrative distance]] to each route, where smaller administrative distances indicate routes learned from a supposedly more reliable protocol.
 
 
 
A local network administrator, in special cases, can set up host-specific routes to a particular machine which provides more control over network usage, permits testing and better overall security. This can come in handy when required to debug network connections or routing tables.
 
 
 
==Multiple agents==
 
In some networks, routing is complicated by the fact that no single entity is responsible for selecting paths: instead, multiple entities are involved in selecting paths or even parts of a single path. Complications or inefficiency can result if these entities choose paths to optimize their own objectives, which may conflict with the objectives of other participants.
 
 
 
A classic example involves traffic in a road system, in which each driver picks a path which minimizes their own travel time. With such routing, the [[Nash equilibrium|equilibrium]] routes can be longer than optimal for all drivers. In particular, [[Braess paradox]] shows that adding a new road can ''lengthen'' travel times for all drivers.
 
 
 
In another model, for example used for routing [[automated guided vehicle]]s (AGVs) on a terminal, reservations are made for each vehicle to prevent simultaneous use of the same part of an infrastructure. This approach is also referred to as context-aware routing.<ref>
 
Jonne Zutt, Arjan J.C. van Gemund, Mathijs M. de Weerdt, and Cees Witteveen (2010). [http://www.st.ewi.tudelft.nl/~mathijs/publications/intinfra09.pdf Dealing with Uncertainty in Operational Transport Planning]. In R.R. Negenborn and Z. Lukszo and H. Hellendoorn (Eds.) Intelligent Infrastructures, Ch. 14, pp. 355-382. Springer.</ref>
 
 
 
The Internet is partitioned into [[autonomous system (Internet)|autonomous systems]] (ASs) such as [[internet service provider]]s (ISPs), each of which has control over routes involving its network, at multiple levels. First, AS-level paths are selected via the [[Border Gateway Protocol|BGP]] protocol, which produces a sequence of ASs through which packets will flow. Each AS may have multiple paths, offered by neighboring ASs, from which to choose. Its decision often involves business relationships with these neighboring ASs,<ref>Matthew Caesar and Jennifer Rexford. [http://www.cs.princeton.edu/~jrex/papers/policies.pdf BGP routing policies in ISP networks]. IEEE Network Magazine, special issue on Interdomain Routing, Nov/Dec 2005.</ref> which may be unrelated to path quality or latency. Second, once an AS-level path has been selected, there are often multiple corresponding router-level paths, in part because two ISPs may be connected in multiple locations. In choosing the single router-level path, it is common practice for each ISP to employ [[hot-potato routing]]: sending traffic along the path that minimizes the distance through the ISP's own network—even if that path lengthens the total distance to the destination.
 
 
 
Consider two ISPs, ''A'' and ''B'', which each have a presence in [[New York City|New York]], connected by a fast link with latency 5 [[millisecond|ms]]; and which each have a presence in [[London]] connected by a 5 ms link. Suppose both ISPs have trans-Atlantic links connecting their two networks, but ''A''<nowiki>'s</nowiki> link has latency 100 ms and B's has latency 120 ms. When routing a message from a source in ''A''<nowiki>'s</nowiki> London network to a destination in ''B''<nowiki>'s</nowiki> New York network, ''A'' may choose to immediately send the message to ''B'' in London. This saves ''A'' the work of sending it along an expensive trans-Atlantic link, but causes the message to experience latency 125 ms when the other route would have been 20 ms faster.
 
 
 
A 2003 measurement study of Internet routes found that, between pairs of neighboring ISPs, more than 30% of paths have inflated latency due to hot-potato routing, with 5% of paths being delayed by at least 12 ms. Inflation due to AS-level path selection, while substantial, was attributed primarily to BGP's lack of a mechanism to directly optimize for latency, rather than to selfish routing policies. It was also suggested that, were an appropriate mechanism in place, ISPs would be willing to cooperate to reduce latency rather than use hot-potato routing.<ref>Neil Spring, Ratul Mahajan, and Thomas Anderson. [http://www.cs.washington.edu/research/networking/rocketfuel/papers/sigcomm2003.pdf Quantifying the Causes of Path Inflation]. Proc. [[SIGCOMM]] 2003.</ref>
 
 
 
Such a mechanism was later published by the same authors, first for the case of two ISPs<ref>Ratul Mahajan, David Wetherall, and Thomas Anderson. [http://research.microsoft.com/en-us/um/people/ratul/papers/nsdi2005-nexit.pdf Negotiation-Based Routing Between Neighboring ISPs]. Proc. [[NSDI]] 2005.</ref> and then for the global case.<ref>Ratul Mahajan, David Wetherall, and Thomas Anderson. [http://research.microsoft.com/en-us/um/people/ratul/papers/nsdi2007-wiser.pdf Mutually Controlled Routing with Independent ISPs]. Proc. [[NSDI]] 2007.</ref>
 
 
 
==Route analytics==
 
As the Internet and IP networks become [[mission critical]] business tools, there has been increased interest in techniques and methods to monitor the routing posture of networks. Incorrect routing or routing issues cause undesirable performance degradation, flapping and/or downtime. Monitoring routing in a network is achieved using [[route analytics]] tools and techniques.
 
 
 
==See also==
 
 
 
===Routing algorithms and techniques===
 
<div style="-moz-column-count:2; column-count:2;">
 
* [[Inter domain routing algorithm]]
 
* [[Intra domain routing algorithm]]
 
* [[Adaptive routing]]
 
* [[Alternative-path routing]]
 
* [[Deflection routing]]
 
* [[Edge Disjoint Shortest Pair Algorithm]]
 
* [[Dijkstra's algorithm]]
 
* [[Fuzzy routing]]
 
* [[Geographic routing]]
 
* [[Heuristic routing]]
 
* [[Hierarchical routing]]
 
* [[IP forwarding algorithm|IP Forwarding Algorithm]]
 
* [[Multipath routing]]
 
* [[Overlay network]] routing schemes
 
** [[Key-based routing]] (KBR)
 
** [[Decentralized object location and routing]] (DOLR)
 
** [[Group anycast and multicast]] (CAST)
 
** [[Distributed hash table]] (DHT)
 
* [[Path computation element]] (PCE)
 
* [[Policy-based routing]]
 
* [[Quality of Service]] in routing
 
* [[Static routing]]
 
* [[Backward learning routing]]
 
</div>
 
 
 
===Routing in specific networks===
 
* [[Open Source Routing Machine]] (Road map routing)
 
* [[Route assignment]] in transportation networks
 
* [[Routing in the PSTN]]
 
* [[Small world routing]] - the internet is approximately a small world network
 
 
 
===Routing protocols===
 
* [[Routing protocol]]
 
* [[Classless inter-domain routing]] (CIDR)
 
* [[Multiprotocol Label Switching|MPLS]] routing
 
* [[Asynchronous Transfer Mode|ATM]] routing
 
* [[RPSL]]
 
* [[RSMLT]]
 
* Routing in [[optical mesh network]]s
 
 
 
===Alternative methods for network data flow===
 
* [[Peer-to-peer]]
 
* [[Network coding]]
 
 
 
===Router Software and Suites===
 
* [[GNU Zebra]]
 
* [[Quagga (software)]]
 
* [[Iproute2]]
 
* [[Bird Internet routing daemon]]
 
 
 
===Router Platforms===
 
* [[Network operating system]] - NOS
 
* [[XORP]] - the eXtensible Open Router Platform
 
* [[FTOS]] - Dell's Force 10 firmware family
 
* [[Junos]]
 
* [[Cisco IOS]]
 
* [[NX-OS]]
 
* [[CatOS]]
 
 
 
==References==
 
{{reflist}}
 
{{more footnotes|date=October 2011}}
 
{{refbegin}}
 
* {{cite book | author=Ash, Gerald | title=Dynamic Routing in Telecommunication Networks | publisher=McGraw-Hill | year=1997 | isbn=0-07-006414-8}}
 
* {{cite book | author=Doyle, Jeff and Carroll, Jennifer | title=Routing TCP/IP, Volume I, Second Ed. | publisher=Cisco Press | year=2005 | isbn=1-58705-202-4}}[http://www.ciscopress.com/title/1587052024 <nowiki>Ciscopress ISBN 1-58705-202-4</nowiki>]
 
* {{cite book | author=Doyle, Jeff and Carroll, Jennifer | title=Routing TCP/IP, Volume II, | publisher=Cisco Press | year=2001 | isbn=1-57870-089-2}}[http://www.ciscopress.com/title/1578700892 <nowiki>Ciscopress ISBN 1-57870-089-2</nowiki>]
 
* {{cite book | author=Huitema, Christian | title=Routing in the Internet, Second Ed. | publisher=Prentice-Hall | year=2000 | isbn=0-321-22735-2}}
 
* {{cite book | author=Kurose, James E. and Ross, Keith W. | title=Computer Networking, Third Ed. | publisher=Benjamin/Cummings | year=2004 | isbn=0-321-22735-2}}
 
* {{cite book | author=Medhi, Deepankar and Ramasamy, Karthikeyan | title=Network Routing: Algorithms, Protocols, and Architectures | publisher=Morgan Kaufmann | year=2007 | isbn=0-12-088588-3}}
 
{{refend}}
 
 
 
==External links==
 
* [http://wiki.uni.lu/secan-lab/Count-To-Infinity+Problem.html Count-To-Infinity Problem]
 
* [http://wwwlehre.dhbw-stuttgart.de/~schulte/htme/55024.htm#HDR3 "Stability Features"] are ways of avoiding the "count to infinity" problem.
 
* [http://www.cisco.com/web/about/ciscoitatwork/case_studies/routing.html Cisco IT Case Studies] about Routing and Switching
 
* [http://www.eventhelix.com/Realtimemantra/Networking/ip_routing.htm good example at event-helix]
 
{{Routing protocols}}
 
 
 
[[Category:Компютърни мрежи]]
 
 
 
Most routing algorithms use only one network path at a time, but multipath routing techniques enable the use of multiple alternative paths.
 

Revision as of 07:47, 7 January 2013

Маршрутизация или рутиране е процес на избиране на път в дадена мрежа, по който да се изпрати мрежовия трафик.

Рутиране има в различни мрежи - телефонни мрежи (комутационни вериги), транспортни мрежи (логистика), компютърни мрежи (пакетна комутация).

В компютърните мрежи информацията се предава на пакети, затова рутирането се занимава с препращането на пакет от комуникационна точка към друга комуникационна точка (нод - възел, който в частност може да е router, bridge, gateway, firewall или switches). Целта е информационният пакет да бъде пренесен от началната точка до крайната точка.

Всеки компютър с подходящ софтуер може да изпълнява роля на някои от тези устройства, но при големи натоварвания се препоръчва специализиран хардуер.

Рутираща машина препраща пакети според своята рутираща таблица, в която са описани пътищата до различни дестинации (мрежи). Затова оптималното конструиране на рутиращата таблица е много важно за ефективно рутиране.



Most routing algorithms use only one network path at a time, but multipath routing techniques enable the use of multiple alternative paths.

Routing, in a more narrow sense of the term, is often contrasted with bridging in its assumption that network addresses are structured and that similar addresses imply proximity within the network. Because structured addresses allow a single routing table entry to represent the route to a group of devices, structured addressing (routing, in the narrow sense) outperforms unstructured addressing (bridging) in large networks, and has become the dominant form of addressing on the Internet, though bridging is still widely used within localized environments.