Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Introduction of routing and Agent ARP

2025-04-01 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/02 Report--

Network equipment management

Software

System Files-IOS.bin

Configuration file

Startup configuration file-sstartup-config

Running configuration file-running-config

Hardware

Flash-hard disk system file

Nvram-sstartup-config

Ram-running-config (save)

Management:

Local Management-console

Remote Management-telnet

MAC:

-effect

Globally, uniquely, identify a network device

-represents

Total 48bit, that is 6 bytes

Represented by hexadecimal

-structure

The 24 bits on the left represent the vendor code

The 24 digits on the right represent a device number defined by the manufacturer.

-pay attention

MAC address is a physical address and cannot be changed.

Equivalent to the address of a building in the human world

In the network world, you must rely on both IP address and MAC address

To uniquely identify a communication device.

In order to be able to get a MAC address corresponding to an IP address, you need: ARP

ARP:address resolution protocol: address Resolution Protocol

-the function is based on an IP address and resolves the corresponding MAC address.

In order to realize the complete encapsulation of the data

2-layer head (MAC/Ethernet header) total 14Byte

Destination MAC + source MAC + type

Destination source type

6Byte 6Byte 2Byte

Tail of layer 2 (FCS, frane checksum, frame checksum, total 4Byte)

-principle:

1. Source host, sent by broadcast, ARP request packet

2. After the target host receives the ARP request packet, it first checks whether the destination MAC of the layer 2 header is the same as itself, or whether it is a broadcast address

If so, analyze the ARP message behind the layer 2 header, if the "target IP" in it is the same as yourself

First of all, record the corresponding relationship between the sent IP and the MAC and put it in your local ARP table.

3. Then the target host builds and returns the ARP impact message in a unicast way

4. After the source host receives the ARP response message. Perform the same data processing as step 2 to form the ARP table locally.

-Type:

Ordinary ARP: resolve the corresponding MAC address based on the IP address

Reverse ARP: obtain the corresponding IP address based on the MAC address

Agent ARP

-bona fide agency

-malicious agent

The address requested by ARP:ARP for no reason is self, which is used to find duplicate IP addresses that are used by oneself, that is, IP address conflict detection.

Core table:

ARP table

Relationship between IP address and MAC address

Action

In order to realize the fast encapsulation of the data layer 2 header

Types

Static ARP entries: always exist in the ARP table

Dynamic ARP entries: stored in the ARP table within the valid time

The ARP valid time of network devices is 4 hours.

View

Terminal equipment: arp-a

Network devices: display arp and show ip arp

Cisco equipment:

Static ARP: arp 192.168.1.254 MAC address arpa

End device: arp-s 192.168.1.254 MAC address

Note:

The MAC address is all 1, indicating the broadcast MAC address

AMC addresses are all 0, indicating unknown MAC addresses

Routing:

Definition:

Interconnection of quality inspection between different network segments is called routing.

Achieve:

Achieve "routing" through devices with routing capabilities

Such as routers, multilayer switches

Core:

Routing tabl

View the routing table: show ip route

Analyze the routing table:

For example:

C 192.168.12.0/24 is directly connected, FastEthernet0/0

How a router works:

1. Routers only care about IP addresses, not MAC addresses

2. The router only cares about the destination IP address, not the source IP address.

3. After receiving the packet, the "destination IP" is proposed to match the "routing table entry":

The process is as follows

First analyze the subnet mask length of the route entry

Secondly, the bits of the corresponding length in the destination IP address are extracted according to the length of the subnet mask.

Once again, compare the proposed bits with the routing entries

If it is the same, it means that it is matched and forwarded out the corresponding port.

If it is different, it means that it does not match, and the packet is discarded.

Route viewing and configuration:

View:

Show ip route

Configuration:

Static router configuration:

Ip route 192.168.23.0 255.255.255.0 fas0/0

Ip route 192.168.23.0 255.255.255.0 192.168.12.2 recommended troubleshooting ideas:

The third layer is not accessible. Look at the route.

Show ip + Target IP

1. Master the data forwarding path under normal circumstances

2. Segmented processing

3. In each segment, debug verification commands based on OSI model and "data forwarding mode": show ip interface fas0/0 agent ARP status

Show interface fas0/0 look at the mac address of the port

Show ip arp view the arp table

Debug arp looks at the working process of ARP on the device

Undebug all turns off all debug commands on the device

No ip proxy-arp shuts down the proxy ARP function

Recommendations:

When configuring a static route, the next hop uses the IP address

Huawei static route configuration command

View:

Display ip routing-table View routing tabl

Configuration

Ip route-static 192.168.23.0 255.255.255.0

Enable debug debugging:

Terminal monitor enables monitoring

Terminal debuging enables monitoring of debug.

Debuging ip icmp looks at the working process of icmp on the device

Li Jun tel:15135361516 Qq:344728662

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report