当前位置:首页 > CN2资讯 > 正文内容

ARP代理配置

3天前CN2资讯

ARP代理主要分为三种:

一,路由式Proxy ARP:

解决同一网段不同物理网络上计算机的互通问题。

二,VLAN内Proxy ARP:

解决相同VLAN内,且VLAN配置用户隔离后的网络上计算机互通问题。

三,VLAN间Proxy ARP:

解决不同VLAN之间对应计算机的三层互通问题。

 

用上图中三个路由器模拟实际使用环境RSG5与RSG6分别代表两台主机。

实验一:

路由式Proxy ARP:解决同一网段不同物理网络上计算机的互通问题

RSG5上配置:

VLAN 5

vlan 5

interface Vlanif5
ip address 192.168.6.1 255.255.0.0               -----这里是关键RSG5 RSG6的地址必须是一个网段的。
interface GigabitEthernet0/0/2
undo shutdown
portswitch
port link-type trunk
port trunk allow-pass vlan 5

RSG6上配置:

vlan 6

interface Vlanif6
ip address 192.168.7.1 255.255.0.0

interface GigabitEthernet0/0/2
undo shutdown
portswitch
port link-type trunk
port trunk allow-pass vlan 6

RNC上配置:

vlan batch 5 to 6

interface Vlanif5
ip address 192.168.6.3 255.255.255.0
arp-proxy enable
interface Vlanif6
ip address 192.168.7.2 255.255.255.0
arp-proxy enable

interface GigabitEthernet0/0/0           
undo shutdown
portswitch
port link-type trunk
port trunk allow-pass vlan 5


interface GigabitEthernet0/0/1
undo shutdown
portswitch
port link-type trunk
port trunk allow-pass vlan 6

 

配置后在RSG5上执行:

<RSG5>ping -c 1000 192.168.7.1
  PING 192.168.7.1: 56  data bytes, press CTRL_C to break
    Reply from 192.168.7.1: bytes=56 Sequence=1 ttl=254 time=90 ms
    Reply from 192.168.7.1: bytes=56 Sequence=2 ttl=254 time=70 ms
    Reply from 192.168.7.1: bytes=56 Sequence=3 ttl=254 time=60 ms
    Reply from 192.168.7.1: bytes=56 Sequence=4 ttl=254 time=60 ms
    Reply from 192.168.7.1: bytes=56 Sequence=5 ttl=254 time=60 ms
    Reply from 192.168.7.1: bytes=56 Sequence=6 ttl=254 time=30 ms
    Reply from 192.168.7.1: bytes=56 Sequence=7 ttl=254 time=70 ms
    Reply from 192.168.7.1: bytes=56 Sequence=8 ttl=254 time=40 ms
    Reply from 192.168.7.1: bytes=56 Sequence=9 ttl=254 time=50 ms
    Reply from 192.168.7.1: bytes=56 Sequence=10 ttl=254 time=60 ms
    Reply from 192.168.7.1: bytes=56 Sequence=11 ttl=254 time=50 ms
    Reply from 192.168.7.1: bytes=56 Sequence=12 ttl=254 time=40 ms
    Reply from 192.168.7.1: bytes=56 Sequence=13 ttl=254 time=50 ms
    Reply from 192.168.7.1: bytes=56 Sequence=14 ttl=254 time=60 ms--------------------这里可以看到TTL=254经过ARP代理后减了1

    !!这里只要在RSG的VLANIF5下做ARP代理就可以从RSG5上ping通RSG6上的地址。

实验二:用的模拟器不能模拟在交换机上的端口隔离配置这里就没有做,这个实验也是最简单的一个。

实验三:

解决不同VLAN之间对应计算机的三层互通问题。

基础配置:

在RSG5上:建立vlan5,起三层接口配地址:192.168.1.5/24

在RSG6上:建立vlan6,起三层接口配地址:192.168.1.6/24

在RNC上:建立vlan7,起三层接口配地址:192.168.1.1/24,RNC在VLAN7的三层地址下起VLAN间ARP代理,将VLAN7设置为汇聚VLAN,将VLAN 5 VLAN 6加入到VLAN7中。

配置:

RSG5:

interface Vlanif5
ip address 192.168.1.5 255.255.255.0

interface GigabitEthernet0/0/2
undo shutdown
portswitch
port link-type trunk
port trunk allow-pass vlan 5

RSG6:

interface Vlanif6
ip address 192.168.1.6 255.255.255.0

interface GigabitEthernet0/0/2
undo shutdown
portswitch
port link-type trunk
port trunk allow-pass vlan 6

RNC:

vlan batch 5 to 7

vlan 7
aggregate-vlan
access-vlan 5 to 6

interface Vlanif7
ip address 192.168.1.1 255.255.255.0
arp-proxy inter-sub-vlan-proxy enable

 

结果:

PING 192.168.1.5: 56  data bytes, press CTRL_C to break
   Request time out
   Request time out
   Request time out
   Request time out
   Request time out
   Request time out                                                                                             ------没有开启VLAN间ARP代理时RSG5与RSG6不通
   Reply from 192.168.1.5: bytes=56 Sequence=7 ttl=254 time=80 ms -------开启VLAN间ARP代理后可以PING通同样跳数减1
   Reply from 192.168.1.5: bytes=56 Sequence=8 ttl=254 time=50 ms
   Reply from 192.168.1.5: bytes=56 Sequence=9 ttl=254 time=60 ms
   Reply from 192.168.1.5: bytes=56 Sequence=10 ttl=254 time=60 ms
   Reply from 192.168.1.5: bytes=56 Sequence=11 ttl=254 time=30 ms
   Reply from 192.168.1.5: bytes=56 Sequence=12 ttl=254 time=30 ms

    你可能想看:

    扫描二维码推送至手机访问。

    版权声明:本文由皇冠云发布,如需转载请注明出处。

    本文链接:https://www.idchg.com/info/24333.html

    标签: ARP代理配置
    分享给朋友:

    “ARP代理配置” 的相关文章

    中国电信CN2网络接入不了的原因解析及解决方案

    在数字化时代,网络连接已成为我们生活中不可或缺的一部分。对于企业用户来说,中国电信CN2网络作为一张高可靠、低时延的网络,为广大用户提供了优质的网络服务。一些用户近期反映中国电信CN2网络接入不了的问题,这不仅影响了用户体验,也可能对企业正常运营造成干扰。中国电信CN2网络接入不了的原因到底是什么呢...

    搬瓦工带防御:如何提升VPS安全性,抵御DDoS攻击

    搬瓦工VPS的基本介绍 搬瓦工(Bandwagon Host)作为一家知名的VPS提供商,以其稳定的网络连接和出色的性能赢得了众多用户的青睐。无论是个人网站搭建、企业应用部署,还是科学上网需求,搬瓦工VPS都能提供灵活且高效的解决方案。它的价格相对亲民,同时支持多种操作系统和自定义配置,满足了不同用...

    香港CN2线路:提升跨境数据传输效率的最佳选择

    CN2线路的定义与背景 香港CN2线路是中国电信推出的一项先进网络服务,专门设计用于提供高质量的国际数据传输。这个网络服务的目标是解决传统网络在跨境数据传输时遇到的延迟和带宽限制问题。CN2线路的推出,标志着中国电信在网络技术上的一个重要进步,特别是在处理大量数据和高频率的跨境通信方面。 CN2线路...

    如何高效使用测速脚本监测网络性能

    在互联网的快速发展中,网络测速变得越来越重要。作为一个互联网用户,了解自己的网络性能是否稳定,以及在不同时间与地点的表现,能帮助我们更好地选择服务和进行问题排查。网络速度直接影响了我们的在线体验,无论是看视频、玩游戏,还是进行远程办公,网络性能都扮演着至关重要的角色。 测速脚本出现在这样的背景下,它...

    VPS CN2:提升网络性能的最佳选择

    在了解VPS CN2之前,我觉得有必要先简单说说VPS究竟是什么。VPS即虚拟专用服务器,是一种利用虚拟化技术将物理服务器划分成多个独立的虚拟服务器。每个VPS都能独立运行操作系统和应用软件,用户可以通过远程方式管理和使用。这给了我们极大的灵活性和自由度,让我可以随时根据需求扩大或缩小资源。 说到V...

    Debian 修改 DNS 的详细步骤与常见问题解决方案

    在讨论 Debian 中的 DNS 修改前,我想先和大家分享一些关于 DNS 的基本信息。DNS(Domain Name System)是互联网的“电话簿”,它将我们可读的网站地址(如 www.example.com)转换为计算机能够理解的 IP 地址。这一过程对于我们浏览网页、发送邮件等操作至关重...