The switch is equivalent to one car
, there are buses and cars, each person is equivalent to a host, the purpose of the car is to bring multiple people to run at the same time, and everyone in the car knows each other
The router is equivalent to the traffic police at the intersection. In addition to maintaining traffic order, it must also mark the signs (many ways) to go to the next intersection. If you ask for directions, tell him the destination. If you know, it will give you the route. If you don't know where you are going, you can ask.
router
- A router is a network device that forwards data packets between computer networks .
- Routers perform traffic control functions on the Internet.
- A data packet is usually forwarded from one router to another through the networks that make up the internetwork until it reaches its destination node .
I summarize that the responsibility of all routers is to direct the transmission direction of data packets and to find a shorter data transmission route as much as possible. The
function is very similar to that of the traffic police . When the person asks for directions, after the calculation, tell the current optimal processing method
How physics works
- Physical connection :
- A router is connected to two (at least) or more data lines from different networks (crossovers are not considered).
- Get the destination address:
- When a packet enters one of the lines, the router reads the network to determine the final destination.
- After processing, select route forwarding:
- Then, using the information in its routing table or routing policy , it directs the packet to the next network .
Common routers
The most common types of routers are home and small office routers,
which simply Internet
forward IP
packets between the home computer and .
An example of a router is the owner 's cable or DSL
router
which is connected to the internet through the internet service provider internet server provider ( ISP
).
More sophisticated routers, such as 企业路由器
, connect large enterprises or ISP
networks to powerful core routers
that forward data at high speeds along Internet
the fiber optic lines of the backbone.
Note: Although routers are usually dedicated hardware devices, software-based routers also exist.
Generally, the network shares (such as:
热点
) that are opened on the device are based on the software implementation of the existing hardware.
data processing work
When multiple routers are used in an internetwork
, information about the destination address can be 路由协议
exchanged between the routers . A routing table is built in each router that lists the preferred routes between any two systems on the interconnected network.
The logical composition of the router
Divided into two levels:
0x1. Control level: (mainly maintain the routing table)
A routing table maintained by a router lists which connected routes should be used to forward packets, and through which physical interface the route should be connected.
- There are two implementations:
-
This is done by dynamically learning routes using a routing protocol ( ) using internally preconfigured directives (called
静态路由
) .
动态路由
Both static and dynamic routing configuration information is stored in the routing table.
After the control level is executed, a
Forwarding Information Table ( forwarding information base
FIB) (often called a mac
table in China) is established for the forwarding level.
- Forwarding information table (
FIB
):- Also known as
forwarding table
orMAC table
, most commonly used on network bridging , routing and similar functions- Function :
- Find the correct .
- Note:
- Essentially a dynamic table that maps MAC addresses to physical ports.
This is an important mechanism to separate network switches from Ethernet hubs.Essentially, it can be seen that the routing internally adopts the working mechanism of the switch, but it is only limited to
mac地址
the
0x02. Forwarding level: (according to the mac table)
Routers perform the function of forwarding packets between incoming and outgoing interface connections .
They are forwarded to the correct network address using the information contained in the header, which matches the entry in the provided
by the control layer .FIB
Router Introduction:
Routers may have interfaces for different types of physical layer connections, such as copper, fiber, or wireless transmission.
It can also support different network layer transport standards .
Each network interface is used to forward data packets from one transport system to another transport system.
Routers can also be used to connect logical groups 子网
of two or more computer devices called (eg: vlan
) , each with a different network prefix.
A router can provide connectivity within a business, between a business and the Internet, or between an Internet Service Provider ( ISP
) network.
The largest routers (like Cisco CRS-1
or Juniper Networks PTX
) interconnect various ISP
, or possibly large, enterprise networks.
In an enterprise, a core router might provide a "folding backbone" that interconnects distribution-layer routers from multiple buildings on a campus or from a large enterprise location.
They tend to be optimized for high bandwidth, but lack some features of edge routers
Distributed Router:
Distributed routers aggregate traffic from multiple access routers, either at the same site or by collecting traffic from multiple sites to a primary enterprise location.
Distributed routers are usually responsible WAN
for enforcing quality of service over a wide area network ( WAN ), so they may have a large amount of memory installed, multiple WAN
interface connections, and a lot of onboard data processing routines. They can also provide connectivity to file server groups or other external networks.
Routers are also often differentiated based on the network they are in:
internal router
Routers in a single organization's local area network ( LAN
) are called internal routers.
(Generally, it is necessary to add an additional interface, so LAN
that all hosts are connected to Route
it, and each host is regarded as a subnet lan
, and the switch is no longer used to merge multiple hosts into one subnet)
External router:
External routers pass packets between hosts in one LAN
and hosts in the other LAN
.
Routers that operate in the backbone of the internet are called 外部路由器
.
gateway (border) router
The most borderline egress or ingress router that connects the local area network ( LAN
) and the wide area network ( ) is called a border router or gateway router .WAN
ISP
Router protocols that connect to major enterprises typically use
the Border
Gateway Protocol (
BGP
) to exchange routing information.
RFC 4098
The standard defines BGP
types of routers according to their functions:
edge router
- Edge router:
-
Also known as a
carrier
edge router , it is located at the edge of the
ISP
network .
Routers use externalBGP
to other routersISP
orEBGP
routers . - User Edge Router:
-
Also known as a customer edge router, it is located at the edge of the user's network and it also
EBGP
uses the autonomous system of its provider. It is usually used in (enterprise) organizations. - Inter-provider border routers:
-
An interconnect
ISP
is aBGP
router that maintains sessionsBGP
with other routers in the ISP's autonomous system.BGP
Core router:
The core router is located in the autonomous system and acts as the backbone for transporting traffic between the backbone routers .
ISP
Internally: In an ISP
autonomous system, routers use internals BGP
to communicate with other ISP
edge routers, other Intranet
core routers, or ISP
intranet provider edge routers.
- "Internet backbone:
-
"The Internet no longer has a clearly identifiable backbone like the previous networks. The
main system routers make up what can be considered the backbone of the current Internet. Run all four types of BGP routers described here. The routers are used for Interconnects its edge routers and border routers. Core routers can also have specialized functions in a virtual private network based on a combination of VPS and multiprotocol label switching protocols.ISP
ISP
ISP
核心
BGP
- port forwarding:
- Routers are also used for port forwarding between servers connecting to the private internet.
- Voice/Data/Fax/Video Processing Router:
-
Often referred to as access servers or gateways, these devices are used to route and process voice, data, video, and fax traffic over the Internet.
Since 2005, most long-distance calls have been handled asIP
traffic (VOIP
)
, and the use of access server-type routers expanded with the advent of the Internet, first with dial-up access and the revival of another voice telephony service.
Note:
Larger networks often use multi-layer switches
Layer-3 devices are used to simply interconnect multiple subnets within the same security zone
When filtering , translation , load balancing , or other more advanced functions are required (especially between zones) higher layer switches .
history
The first router was not Cisco
created
The first ARPANET
router, the Interface Message Processor, was delivered to UCLA on August 30, 1969, and went live on October 29, 1969. The concept of an "interface computer" was first used in NPL networks by Donald Davies in 1966.
[19] The Interface Message Processor (IMP) was conceived for ARPANET in 1967 and has basically the same function as a router.
Routers (then called "gateways") were originally formed through an international group of computer networking researchers called the International Networking Working Group (INWG).
Founded in 1972 as an informal group to consider the technical issues involved in connecting disparate networks, it became a subcommittee of the International Union for Information Processing later that year.
These gateway devices have two different types of packet switching schemes than most previous ones.
First, they are connected to different kinds of networks, such as serial lines and local area networks.
Second, they are connectionless devices, they cannot ensure reliable delivery of traffic and are left entirely to the host. [E]
This idea was explored in more detail with the aim of producing a prototype system as part of two concurrent programs. One was an initiative originally initiated by DARPA that created the TCP / IP
architecture used today.
The other is a Xerox PARC
project to explore new networking technologies that gave rise to the PARC
Universal Packet System; it has received attention outside Xerox for years because of corporate intellectual property issues.
Some time after early 1974, the first Xerox routers were put into use.
The first real IP
routers were developed by BBN
, Ginny Strazisar
as part DARPA
of an effort initiated by , in 1975-1976. [23] By the end of 1976, three PDP-11-based routers were in use in Internet experimental prototypes [24].
In 1981, researchers at MIT and Stanford University independently created the first multiprotocol router; the Stanford router was done by William Yeager and the one at MIT by Noel Chiappa; both were based on the PDP-11.
Almost all networks use it now TCP / IP
, but multiprotocol routers are still being made.
They were very important in the early stages of computer networking development when protocols other than TCP/IP were used.
Modern Internet routers that handle IPv4 and IPv6 are multiprotocol, but simpler than routers that handle AppleTalk
, DECnet
, , IP
and Xerox
protocols.
From the mid-1970s to the 1980s, general-purpose minicomputers were used as routers.
Modern high-speed routers are highly specialized computers with additional hardware added to accelerate common routing functions such as 数据包转发
and . Extensive use of and software-based machines running open source routing code for research and other applications. The operating system is designed independently. Major router operating systems, such as and , are widely modified versions of the software.专用功能
IPsec加密
Linux
Unix
Cisco IOS
Junos
NX-OS
Unix