设为首页收藏本站language 语言切换
查看: 2203|回复: 0
收起左侧

[书籍] EFM(Ethernet in the First Mile)配置指南

[复制链接]
 成长值: 63400
发表于 2021-8-13 16:01:26 | 显示全部楼层 |阅读模式
EFM简介
EFM能够有效提高以太网的管理和维护能力,保障网络的稳定运行。

以太网技术简单易用、价格低廉、且带宽可不断提高,无论是作为一种业务还是作为一种网络结构,其在企业网范围内都已经得到广泛应用。随着以太网推广的范围逐渐扩大,对以太网管理和维护功能的需求也越来越强烈。但是传统以太网可维护、可运营能力比较弱,最后一公里以太网EFM(Ethernet in the First Mile)的出现很好的解决了这一问题。

EFM主要用于接入部分的以太网物理层规范以及以太网管理和维护,是链路级的OAM(Operation and Management)。针对两台直连设备之间的链路,提供链路连通性检测功能、链路故障监控功能、远端故障通知功能和远端环回功能。

EFM配置任务概览
完成EFM基本功能配置后,EFM即可开始工作。如果需要部署一些特殊的EFM组网方案,例如EFM链路监控功能、EFM远端环回功能、EFM远端故障检测功能、EFM联动功能,则可根据相应章节进行其他配置。

EFM的配置任务如表1所示。

表7-7  EFM配置任务概览
场景

描述

对应任务

配置EFM基本功能

配置EFM基本功能,实现对链路的监测。

配置EFM基本功能

配置EFM链路监控功能

EFM链路监控功能配置成功后,网络管理员可以在各种环境下检测和发现链路层故障,实时动态监控链路的质量,以便对网络进行实时的调整。

配置EFM链路监控功能

配置EFM远端环回功能

EFM远端环回功能配置成功后,为用户提供了一种测试链路连通性和性能的手段。

配置EFM远端环回功能

配置EFM远端故障检测功能

EFM远端故障检测功能为用户提供了一种检测远端设备链路故障和以太网性能的手段。

配置EFM远端故障检测功能

配置EFM联动功能

EFM提供了与接口和协议联动功能,通过联动功能,可以实现链路故障的传递,保证业务的可靠性。

配置EFM联动功能
配置EFM功能示例
组网需求
随着网络的快速发展,IP网络越来越多的承载语音、视频等多种业务,这些业务对网络的高可靠性提出了更高的要求,从而网络要求更快的故障感知能力和故障处理速度。
图7-10所示,CE1到CE3之间网络为新部署网络,用户希望
  • 在启用新的网络前对该网络进行链路连通性和链路的质量进行检测。
  • 在链路正常启用后,动态监测链路的质量。
  • 当主用链路故障时,能够切换到备用链路上进行业务转发。


图7-10  配置EFM功能组网图

                               
登录/注册后可看大图



配置思路采用如下思路配置EFM功能:
  • 在CE1和CE4设备配置EFM基本功能,实现链路连通性的自动检测。
  • 在CE1设备上配置EFM远端环回,以实现正式启用链路前对CE1到CE4链路进行连通性和性能测试。
  • 在CE1设备上配置EFM链路监控功能,监测CE1到CE4之间链路的性能和质量。
  • 在CE4上配置EFM与接口联动功能,使得当EFM检测到CE1到CE4链路故障时,将CE4另一侧的接口置为逻辑Down。




操作步骤
  • 配置EFM基本功能
    # 全局使能CE1的EFM功能。
    <Huawei> system-view[Huawei] sysname CE1[CE1] efm enable
    # 使能CE1上接口Eth1/0/2的EFM功能。
    [CE1] interface ethernet 1/0/2[CE1-Ethernet1/0/2] efm enable[CE1-Ethernet1/0/2] quit
    # 全局使能CE4的EFM功能。
    <Huawei> system-view[Huawei] sysname CE4[CE4] efm enable
    # 配置CE4的Eth2/0/1接口的EFM工作模式为被动模式。
    [CE4] interface ethernet 2/0/1[CE4-Ethernet2/0/1] efm mode passive
    # 使能CE4上接口Eth2/0/1的EFM功能。
    [CE4-Ethernet2/0/1] efm enable[CE4-Ethernet2/0/1] quit
    # 检查配置结果
    如果CE1和CE4的EFM配置正确,接口Eth1/0/2和接口Eth2/0/1成功协商后进入握手阶段,此时在CE1或者CE4上执行display efm session { all | interface interface-type interface-num }命令,可看到接口Eth1/0/2或者接口Eth2/0/1的EFM协议状态为detect
    [CE1] display efm session all  Interface                 EFM State                   Loopback Timeout  ----------------------------------------------------------------------  Ethernet1/0/2                   detect                        --
  • 配置EFM远端环回功能
    # 在CE1上配置EFM远端环回。
    [CE1] interface ethernet 1/0/2[CE1-Ethernet1/0/2] efm loopback start[CE1-Ethernet1/0/2] quit
    # 检查配置结果
    配置EFM远端环回成功后,在CE1上执行display efm session { all | interface interface-type interface-num }命令,可以看到接口Eth1/0/2的EFM协议状态为loopback (control),即远端环回状态(且为远端环回的发起方)。
    [CE1] display efm session interface ethernet 1/0/2  Interface                 EFM State                   Loopback Timeout  ----------------------------------------------------------------------  Ethernet1/0/2                   loopback (control)          20
    配置EFM远端环回成功后,在CE4上执行display efm session { all | interface interface-type interface-num }命令,可以看到接口Eth2/0/1的EFM协议状态为loopback (be controlled),即远端环回状态(且为远端环回的响应方)。
    [CE4] display efm session interface ethernet 2/0/1  Interface                 EFM State                   Loopback Timeout  ----------------------------------------------------------------------  Ethernet2/0/1                   loopback (be controlled)    --
  • 从CE1向CE4发送测试报文
    [CE1] test-packet start interface ethernet 1/0/2Please wait..............Info: The test is completed.
  • 在CE1上查看测试报文的返回情况
    [CE1] display test-packet result  TestResult         Value--------------------------------------------------------  PacketsSend    :   5  PacketsReceive :   5  PacketsLost    :   0  BytesSend      :   320  BytesReceive   :   320  BytesLost      :   0  StartTime      :   03-05-2012 14:28:16 UTC+03:00  EndTime        :   03-05-2012 14:29:22 UTC+03:00
    根据以上数据可计算链路的丢包率等,以查看链路质量。

  • 取消EFM远端环回
    [CE1] interface ethernet 1/0/2[CE1-Ethernet1/0/2] efm loopback stop[CE1-Ethernet1/0/2] quit

                                   
    登录/注册后可看大图
    说明:
    缺省情况下,远端环回的超时时间是20分钟,到达此时间,远端环回自动停止。如果需要提前取消远端环回,可执行以上步骤。



  • 验证配置结果
    # 远端环回功能取消后,在CE1或者CE4上执行display efm session { all | interface interface-type interface-num }命令,可以看到链路两端接口的EFM协议状态为detect,即握手状态。例如:
    [CE1] display efm session all  Interface                 EFM State                   Loopback Timeout  ----------------------------------------------------------------------  Ethernet1/0/2                   detect                        --
    远端环回功能检测到链路为正常情况下,可以进行下面的配置,以实时监控链路的连通性及其故障。

  • 在CE1上配置接口Eth1/0/2的误帧、误码、误帧秒检测功能
    # 在CE1上配置接口Eth1/0/2的误帧检测功能
    [CE1] interface ethernet 1/0/2[CE1-Ethernet1/0/2] efm error-frame period 5[CE1-Ethernet1/0/2] efm error-frame threshold 5[CE1-Ethernet1/0/2] efm error-frame notification enable
    # 在CE1上配置接口Eth1/0/2的误码检测功能
    [CE1-Ethernet1/0/2] efm error-code period 5[CE1-Ethernet1/0/2] efm error-code threshold 5[CE1-Ethernet1/0/2] efm error-code notification enable
    # 在CE1上配置接口Eth1/0/2的误帧秒检测功能
    [CE1-Ethernet1/0/2] efm error-frame-second period 120[CE1-Ethernet1/0/2] efm error-frame-second threshold 5[CE1-Ethernet1/0/2] efm error-frame-second notification enable[CE1-Ethernet1/0/2] quit
  • 验证配置结果
    # 上述配置完成后,CE1的接口Eth1/0/2和CE4的接口Eth2/0/1成功协商后进入握手阶段,此时在CE1或者CE4上执行display efm session { all | interface interface-type interface-num }命令,可看到接口Eth1/0/2或者接口Eth2/0/1的EFM协议状态为detect
    [CE1] display efm session interface ethernet 1/0/2  Interface                 EFM State                   Loopback Timeout  ----------------------------------------------------------------------  Ethernet1/0/2                   detect                        --
    # 上述配置完成后,执行命令display efm { all | interface interface-type interface-number },接口的EFM配置信息如下:
    [CE1] display efm interface ethernet 1/0/2    Item                            Value    ----------------------------------------------------    Interface:                      Ethernet1/0/2    EFM Enable Flag:                enable    Mode:                       active    Loopback IgnoreRequest:     no    OAMPDU MaxSize:                 128    OAMPDU Timeout:                 5000      OAMPDU Interval:                1000    ErrCodeNotification:        enable    ErrCodePeriod:              5    ErrCodeThreshold:           5    ErrFrameNotification:       enable    ErrFramePeriod:             5    ErrFrameThreshold:          5    ErrFrameSecondNotification: enable    ErrFrameSecondPeriod:       120    ErrFrameSecondThreshold:    5    Hold Up Time:                   0    ThresholdEvtTriggerErrDown:     disable    TriggerIfDown:                  disable    TriggerMacRenew:                disable    Remote MAC:                     0010-0010-0010    Remote EFM Enable Flag:         enable    Remote Mode:                    passive    Remote MaxSize:                 128    Remote Loopback IgnoreRequest:  no      Remote State:                   --    ErrFramePeriodNotification:     disable    ErrFramePeriodPeriod:           200000    ErrFramePeriodThreshold:        1
  • 在CE4上配置EFM与接口Eth2/0/2联动
    [CE4] oam-mgr[CE4-oam-mgr] oam-bind efm interface ethernet 2/0/1 trigger if-down interface ethernet 2/0/2 [CE4-oam-mgr] quit
  • 验证配置结果
    # 配置完成后,在CE1接口Eth1/0/2下执行shutdown命令,在CE4设备上可以查看到接口Eth2/0/2下“current state”的值为“TRIGGER DOWN (3AH)”。
    [CE1] interface ethernet 1/0/2[CE1-Ethernet1/0/2] shutdown[CE1-Ethernet1/0/2] quit[CE4] display interface ethernet 2/0/2Ethernet2/0/2 current state : TRIGGER DOWN (3AH)                         Line protocol current state : DOWN                                                Last line protocol up time : 2012-05-02 06:00:06                                Description:HUAWEI, AR Series, Ethernet2/0/2 Interface                   Route Port,The Maximum Transmit Unit is 1500                                    Internet protocol processing : disabled                                         IP Sending Frames' Format is PKTFMT_ETHNT_2, Hardware address is 0004-c002-2808 Last physical up time   : 2012-05-02 06:00:06                                   Last physical down time : 2012-05-02 05:59:27                                   Current system time: 2012-05-19 23:32:06                                        Port Mode: COMMON COPPER                                                        Speed :  100,  Loopback: NONE                                                   Duplex: FULL,  Negotiation: ENABLE                                              Mdi   : AUTO                                                                    Last 300 seconds input rate 928 bits/sec, 1 packets/sec                         Last 300 seconds output rate 432 bits/sec, 0 packets/sec                        Input peak rate 30840 bits/sec,Record time: 2012-05-11 05:32:54                 Output peak rate 56672 bits/sec,Record time: 2012-05-11 05:32:54                                                                                                Input:  983276 packets, 132479662 bytes                                           Unicast:             288163,  Multicast:               25518                    Broadcast:           669595,  Jumbo:                       0                    Discard:                  0,  Total Error:                 0                                                                                                    CRC:                      0,  Giants:                      0                    Jabbers:                  0,  Throttles:                   0                    Runts:                    0,  Symbols:                     0                    Ignoreds:                 0,  Frames:                      0                                                                                                  Output:  465225 packets, 35625620 bytes                                           Unicast:             464361,  Multicast:                   0                    Broadcast:              864,  Jumbo:                       0                    Discard:                  0,  Total Error:                 0                                                                                                    Collisions:               0,  ExcessiveCollisions:         0                    Late Collisions:          0,  Deferreds:                   0                                                                                                      Input bandwidth utilization threshold : 100.00%                                 Output bandwidth utilization threshold: 100.00%                                 Input bandwidth utilization  : 0.01%                                            Output bandwidth utilization :    0%


配置文件
  • CE1的配置文件
    #sysname CE1#efm enable#interface Ethernet1/0/2 efm enable                                                                      efm error-frame period 5                                                        efm error-frame threshold 5                                                     efm error-frame notification enable                                             efm error-frame-second period 120                                               efm error-frame-second threshold 5                                              efm error-frame-second notification enable                                      efm error-code period 5                                                         efm error-code threshold 5                                                      efm error-code notification enable                  #                                                 return
  • CE4的配置文件
    #sysname CE4#efm enable#interface Ethernet2/0/1 efm mode passive efm enable#oam-mgr oam-bind ingress efm interface Ethernet2/0/1 trigger if-down egress interface Ethernet2/0/2 oam-bind ingress interface Ethernet2/0/2 egress efm interface Ethernet2/0/1 trigger if-down#                                                                                             return
  • 游客,如果您要查看本帖隐藏内容请回复








您需要登录后才可以回帖 登录 | 论坛注册

本版积分规则

QQ|Archiver|手机版|小黑屋|sitemap|鸿鹄论坛 ( 京ICP备14027439号 )  

GMT+8, 2025-2-2 21:42 , Processed in 0.085876 second(s), 13 queries , Redis On.  

  Powered by Discuz!

  © 2001-2025 HH010.COM

快速回复 返回顶部 返回列表