junper_ERX_1400做宽带接入的配置数据

junper ERX 1400做宽带接入的配置数据
Configuration being generated on SUN NOV 09 2003 09:27:17 CHN
! Juniper Edge Routing Switch ERX-1400
! Version: 3.4.1 patch-9.0 (October 6, 2003 10:20)
! Copyright (c) 1999-2003 Juniper Networks, Inc. All rights reserved.
boot config running-configuration
boot system erx_3-4-1p9-0.rel
!
exclude-subsystem ct3
exclude-subsystem ct1
exclude-subsystem ut3a
exclude-subsystem ut3f
exclude-subsystem dpfe
exclude-subsystem "ct3-12"
exclude-subsystem oc3
exclude-subsystem ut3f12
exclude-subsystem oc12p
exclude-subsystem "oc3-4p"
exclude-subsystem coc12
exclude-subsystem oc12s
!
boot backup erx_3-4-1p7-0.rel zc0310.cnf
no boot subsystem
no boot backup subsystem
no boot force-backup
no boot slot
!

virtual-router default
默认的VRF
virtual-router LEASED_LINE
专线的VRF
virtual-router VPDN_LAC
本地VPDN用户的VRF
!
license b-ras 1r1Knae9k7
!
aaa domain-map "163.gd"
virtual-router default
!
aaa domain-map default
virtual-router "VPDN_LAC"
!
aaa domain-map none
virtual-router default
!
hostname "ERX--01"
service password-encryption
enable secret level 5 5 P=<R9\6{3-"YQ>?TCV-*[BR>enable secret level 10 5 p/$E+QF8rBj?)3*dQ}<@[BR>!
clock timezone CHN 8 0
!
controller sonet 3/0
clock source internal module
!
controller sonet 3/1
clock source internal module
!
controller sonet 3/2
clock source internal module
!
controller sonet 3/3
clock source internal module
!
!
line console 0
password XXXXX
exec-timeout 5 0
login
!
line vty 0 4
password XXXXX
exec-timeout 5 0
access-class DenyTel in
!
log engineering
log verbosity low
no log severity *
no log engineering
log fields timestamp instance no-calling-task
!
disable-switch-on-error
========================================================================
用户的速率限制PROFILE


rate-limit-profile pro512K
committed-rate 512000
committed-burst 51200
peak-burst 16384
conformed-action drop
!
rate-limit-profile pro1M
committed-rate 1024000
committed-burst 102400
peak-burst 16384
conformed-action drop
!
rate-limit-profile pro2M
committed-rate 2048000
committed-burst 204800
peak-burst 16384
conformed-action drop
!
rate-limit-profile pro3M
committed-rate 3072000
committed-burst 307200
peak-burst 16384
conformed-action drop
!
rate-limit-profile pro4M
committed-rate 4096000
committed-burst 409600
peak-burst 16384
conformed-action drop
!
rate-limit-profile pro5M
committed-rate 5120000
committed-burst 512000
peak-burst 16384
conformed-action drop
!
rate-limit-profile pro6M
committed-rate 6144000
committed-burst 614400
peak-burst 16384
conformed-action drop
!
rate-limit-profile pro7M
committed-rate 7168000
committed-burst 716800
peak-burst 16384
conformed-action drop
!
rate-limit-profile pro8M
committed-rate 8192000
committed-burst 819200
peak-burst 16384
conformed-action drop
!
rate-limit-profile pro10M
committed-rate 10240000
committed-burst 1024000
peak-burst 16384
conformed-action drop
!
bandwidth oversubion
=========================================================================
profile default
profile pppoe
ip unnumbered loopback 0
ip sa-validate
ip policy input pro512K
ip policy output pro512K
pppoe url "http://www.stdx.com/temp/notice/adslzf_new/index.php"
!
profile "pppoe-1"
ip unnumbered loopback 0
ip sa-validate
ip policy input pro512K
ip policy output pro2M
ppp authentication pap
pppoe sessions 1
!
virtual-router default
aaa dns primary 61.xx.xx.xxx
aaa dns secondary 61.xx.xx.xxx
aaa duplicate-address-check disable
aaa authentication ppp default radius
aaa accounting ppp default radius

ip address-pool local
interface null 0
interface loopback 0
ip address 218.xx.xx.x 255.255.255.255
!
interface loopback 2
!==============================================================================
ATM模块配置全局初始数据(这部分必不可少,否则ATM交换机查不到连接)

!interface atm 3/0
atm clock internal module
atm vc-per-vp 4096
atm oam flush
no atm cac 0 ubr 0
!
interface atm 3/1
atm clock internal module
atm vc-per-vp 4096
atm oam flush
no atm cac 0 ubr 0
============================================================================
ATM上行的PPPOE用户做终结
VPi 50 VCI 32
的用户

interface atm 3/1.10500032 point-to-point
profile any "pppoe-1"
auto-configure pppoe
atm pvc 10500032 50 32 aal5snap 0 0 0
!

=============================================================================

interface gigabitEthernet 0/0
mtu 1522
duplex full
speed 1000
encapsulation vlan
!
interface gigabitEthernet 0/0.191
vlan id 191
ip address 61.141.x.x 255.255.255.252
ip proxy-arp
no ip redirects
!
interface gigabitEthernet 0/0.507
vlan id 507
pppoe
!
pppoe subinterface gigabitEthernet 0/0.507.1
encapsulation ppp
ppp authentication pap
profile any pppoe
!
pppoe subinterface gigabitEthernet 0/0.507.2
encapsulation ppp
ppp authentication pap
profile any pppoe
!

interface gigabitEthernet 0/0.190
!
ip route 0.0.0.0 0.0.0.0 61.141.19.66
ip route 10.1.0.0 255.255.0.0 10.1.4.1
ip route 61.xx.xx.xxx 255.255.255.0 null0
ip route 61.xx.xx.xxx255.255.255.0 null0
ip ttl 60
!
access-list DenyTel permit ip 61.xx.xx.xxx 0.0.0.31 any

!
!
ip local pool "xx-pool-01"
ip local pool "xx-pool-01" 218.1xx.2xx.2 218.1xx.243.254
ip local pool "xx-pool-02"
ip local pool "xx-pool-02" 218.1xx.2xx.1 218.1xx.244.254
!
policy-list pro512K
rate-limit-profile pro512K
!
policy-list pro2M
rate-limit-profile pro2M
!
policy-list pro1M
rate-limit-profile pro1M
!
policy-list pro3M
rate-limit-profile pro3M
!
policy-list pro4M
rate-limit-profile pro4M
!
policy-list pro5M
rate-limit-profile pro5M
!
policy-list pro6M
rate-limit-profile pro6M
!
policy-list pro7M
rate-limit-profile pro7M

policy-list pro8M
rate-limit-profile pro8M
!
policy-list pro10M
rate-limit-profile pro10M
!
radius authentication server 61.xx.xx.xxx
udp-port 1645
retransmit 2
timeout 5
deadtime 10
key xxxx
!
radius authentication server 61.xx.xx.xxx
udp-port 1645
retransmit 2
timeout 5
deadtime 10
key xxxx
!
radius accounting server 61.xx.xx.xxx
udp-port 1646
retransmit 2
timeout 5
deadtime 10
key xxx
!
radius accounting server 61.xx.xx.xxx
udp-port 1646
retransmit 2
timeout 5
deadtime 10
key xxxx
!
radius update-source-addr 61.xx.xx.xxx
!

! ==============================================================================
!
virtual-router LEASED_LINE
aaa authentication ppp default radius
aaa accounting ppp default radius
!
ip address-pool local
interface null 0
interface loopback 1
ip route 0.0.0.0 0.0.0.0 61.141.xx.xx
ip bgp-community new-format
no ip source-route
ip ttl 30
!
telnet listen port 23
!
! ==============================================================================
virtual-router VPDN_LAC
aaa authentication ppp default radius
aaa accounting ppp default radius
!
ip address-pool local
interface null 0
.
!
interface gigabitEthernet 0/0.192
vlan id 192
ip address 61.141.xx.xx 255.255.255.252
ip proxy-arp
!
ip route 0.0.0.0 0.0.0.0 61.141.xx.xx
no ip source-route
radius authentication server 61.xx.xx.xx
udp-port 1645
key xx
!
radius accounting server 61.xx.xx.xxx
udp-port 1646
key xxx
!
radius update-source-addr 61.xx.xx.xxx
!
snmp-server


JUNIPER (ERX)宽带接入服务器日常维护


1.概述
本文档主要介绍JUNIPER BRAS服务器ERX1400硬件/软件方面的日常维护,描述了BRAS在日常运行中可能出现的故障及解决方法。本文档适合用JUNIPER产品-BAS的网络管理员,网络日常维护人员。
2.硬件介绍
ERX1440配置的ERX1440机框具有14个槽位,系统路由及交换模块占用中间两个槽位,其余12个槽位可以配置不同类型的接口模块。
每一组接口模块有两部分组成:前卡为LINEMODULE线路模块,后卡为I/OMODULE I
前卡负责数据包的查找及转发,后卡负责各种类型的物理端口连接。
ERX-1400
的系统路由及交换模块 (SRP) 的交换能力为10Gbps全双工。ERX-1400的路由及交换模块 (SRP) 在一台ERX上有两个,它们共享一块SRP的接口板 (SRP后板)SRP模块主要完成系统的路由学习/系统的数据线速交换/设备状态管理及完成系统软件配置。SRP后板主要由CONSOLE端口及带外网管以太口和系统外部时钟接口等组成。 SRP同时会将一份系统软件及路由表下载到线路模块上。
ERX1400SRP以热备份方式工作即一块SRP工作在PRIMARY状态下,另一块SRP工作在SLAVE状态下,当主用SRP出现故障时,备用SRP自动取得所有的系统控制。
ERX-1400
的电源采用直流供电,一共有两路-48V输入,每一路要求30A
两路电源按负载均担方式工作。
ERX-1400
的风扇系统在整个机框的顶部。
接口模块的工作状态: 每一组接口模块的前卡有三个指示灯---POWER/LINK/FAIL。正常情况下只有POWERLINK灯长亮 (绿色)。如果FAIL灯长亮 (红色) ,表明该接口模块的前卡没有正常工作,需要进一步诊断。
3.
常见故障及排除方法
·Line card 工作异常
现象:FAIL 灯长亮,ONLINE灯不亮
解决措施:如果用命令SHOW HARDWARE 确认该模块一直处于“booting”状态,可以用RELOAD SLOT X 将该模块重启。
·更换不同类型的 Line card
如果安装该Line card的槽位以前安装过不同类型的模块,则新安装的模块不能被系统识别,需要用以下命令进行恢复:
SLOT ERASE         
(注意:该命令同时将相关的软件配置擦除)
SLOT ACCEPT
·用户无法拨号
一般在排除接入部分的问题后,在BRAS上可能的原因有:
1
BRAS地址池耗尽,用命令 SHOW IP LOCAL POOL 确认。
2
.用户账号被锁,用 TEST AAA  USERNAME USERPASSWORD确认。
3
.拨号软件工作异常。
·无法用TELNET 远程登陆BRAS
可能的原因有:
默认的VTY端口被占满。用CLEAR LINE <1-5> 使某个连接断开。
系统受到TCP SYN 攻击。可以用SHOW IP TRAFFIC 确认是否系统受到大量TCP SYN ,如果是可以通过访问列表(ACL)来控制非法的TCP连接。
定义ACL:
IP Access List admin:
    permit ip 202.103.219.64 0.0.0.31 any
    permit ip 202.103.227.192 0.0.0.63 any
    permit ip host 192.168.0.254 any
    permit ip host 202.103.224.74 any
deny ip any any
应用ACLvty :
进入line vty 0 4
access-class admin  in

4. JUNIPER BRAS 常用命令
1.SHOW HARDWARE      
检查系统硬件的工作状态
2.SHOW ENVIRONMENT   
检查系统运行环境
ERX_zhenhai#sho en
Please wait
。。。
    chassis: 14 slot (id 0x3
rev 0x0)
    fabric: 10 Gbps (rev
8)
    fans: ok
    nvs: ok (488MB flash disk
28% full)
    power: A ok
B ok
    srp redundancy: switch-on-error enabled
auto-sync enabled in sync
    slots: ok
        online: 1 4 6 10
        standby: 7
        empty: 0 2 3 5 8 9 11 12 13
    line redundancy: none
    temperature: ok
    timing: primary
        primary: internal SC oscillator (ok)
        secondary: internal SC oscillator (ok)
        tertiary: internal SC oscillator (ok)
        auto-upgrade enabled
    system operational: yes
3.SHOW SUBSCRIBERS  [SUMMARY]   
检查在线的用户
4.SHOW SUBSCRIBERS USERNAME   zh86294722  
检查特定用户(用户名/IP ADDRESS/ATM PVC  等。
5.SHOW UTILIZATION
SHOW PROCESS
观察系统资源利用情况
6.SHOW ATM VC ATM 10/0 151022
检查某个特定的PVC 工作状态
7.SHOW ATM VC
检查所有PVC 工作状态
8.SHOW IP ROUTE | INCLUDE ATM10/0
检查从端口ATM10/0拨号上来的上的IP 路由(可以统计该端口的在线用户)
9.SHOW PPP INTERFACE
检查PPP端口的工作状态: DOWN表示该端口上目前无拨号用户,UP为该端口上有一个拨号用户
10.sh pppoe int atm 10/2
1830 观察PPPOE的会话过程中的数据包统计
11.Show ip local pool     
12.COPY RUNNING-CONFIG ZHENHAI
CNF 将运行配置拷贝道FLASH上名为ZHENHAICNF的文件 (注意: * CNF为二进制文件)
    COPY RUNNING-CONFIG TEST:/BACKUP
CNF
   
将运行配置COPY到主机名为TESTFTP服务器上,文件名为BACKUPCNF
13.
BRAS上建立主机TEST(需进入CONFIG模式):
        host TEST 1
111 ftp anonymous 163   
        1
111 为远端FTP SERVER 地址。
14.RELOAD   
系统重起。
15.LOGOUT SUBSCRIBER ALL [USER]  
将所有[部分]拨号用户强行断开连接
16.
BRAS上增加ADSL 用户端口(PPPOE拨号):
1.
进入配置模式       CONFIG T
2.
创建ATM子接口     INTERFACE ATM 10/0152000
3.
建立PVC                ATM PVC 152000 15 2000 AAL5SNAP
4.
ATM子接口的封装设为PPPOE        ENCAP   PPPOE
5.
创建ATM子接口的子接口        INTERFACE ATM1001520001
6.
将该子接口的封装设为PPP     ENCAP PPP
7.
启动PPPPAP认证          ppp authentication pap
8.
配置该子接口默认属性      profile any zhenhai

ERX700/ERX1400配置及故障诊断(1)


本文主要分为三部分:系统部分描述的是软件升级以及硬件诊断及故障处理、配置部分总结了常用的ERX上不同业务的相关配置,同时对可能出现的配置故障行了分析,提供了相关的解决方法、安全部分是有关ERX安全防范配置。所有描述的配置内容来源于ERX配置手册,如果有不一致的地方以ERX配置手册为准。
1
系统部分
1.1 ERX模块工作状态描述
ERX
的模块主要有SRPline modulei/o module组成,工作状态描述的是SRPline module的运行情况。正常情况下除了备用的SRP状态是standby以外,所有模块的工作状态应为online。通过show version 可以得到各个模块的工作状态:
ERX-1400-CN#show version
Juniper Edge Routing Switch ERX-1400
Copyright (c) 1999-2003 Juniper Networks, Inc.  All rights reserved.
System Release: erx_5-0-3.rel
        Version: 5.0.3 release-0.0 [BuildId 1625]   (December 30, 2003  17:41)
System running for: 6 days, 16 hours, 16 minutes, 18 seconds
        (since WED JUL 07 2004 18:40:26 UTC)

                                                     running                 
slot     state            type        admin  spare    release     slot uptime
---- -------------- ---------------- ------- ----- ------------- -------------
0         ---             ---          ---    ---       ---           ---     
1        inactive    GE               enabled  ---  erx_5-0-3.rel 6d16h:11m:16s
2         ---             ---          ---    ---       ---           ---     
3        online     FE-8             enabled  ---  erx_5-0-3.rel 6d16h:11m:17s
4    hardware error OC3/OC12/DS3-ATM enabled  ---  erx_5-0-3.rel      ---     
5         ---             ---          ---    ---       ---           ---     
6        online     SRP-10Ge         enabled  ---  erx_5-0-3.rel 6d16h:14m:48s
7       standby     SRP-10Ge         enabled  ---  erx_5-0-3.rel      ---     
8    not present OC3-4A           enabled  ---  erx_5-0-3.rel      ---     
9         ---             ---          ---    ---       ---           ---     
10        ---             ---          ---    ---       ---           ---     
11   not responding OC3/OC12/DS3-ATM enabled  ---  erx_5-0-3.rel      ---     
12        ---             ---          ---    ---       ---           ---     
13       online     GE               enabled  ---  erx_5-0-3.rel 6d16h:11m:17s

以下是对各个工作状态的描述:
Ø Inactive
,通常是由于该槽位的i/o module 未连接引起的。
Ø Hardware error
,这表明该line module 没有通过上电自检,一般是该模块有硬件问题,通过硬件诊断可以得到log申请case(步骤见下节)。
Ø Not present
,如果原先正常工作的line module 被拔离该槽位会出现该状态。通过配置模式下的slot erase x 可以将该信息清除。(操作前需确认板卡是否在槽位上)
Ø Not responding
,通常是SRP无法与该line card 建立控制连接通道,可能是line card 有故障,可以通过
操作模式下的reload slot  x 对该模块重启,如果故障依旧,需要通过硬件诊断确认。
需要注意的是slot erase x 会同时清空相关槽位的所有配置,应用之前需要确认。而reload slot x 只是将某个line card 进行重启操作,不会影响配置文件。
.2 如何对LINE MODULE 实施硬件诊断
板卡在工作时出现异常,如果无法通过重启/更换槽位等方法恢复工作时,只有通过更换新的模块。通过硬件诊断可以得到模块的故障信息。
在所有line cardSRP上都有一个RJ45的接口,诊断时需要将console线连接到该接口上。ERX console线
由一根直通网线(蓝色)以及两个DB-9 RJ45的转换接头(cross overstrait through 各一个)组成。进行硬件诊断用的console线需要一根直通网线及一个crossover DB-9 RJ45的转换接头。
首先将terminal调整到19.2kbps,打开termial的日志功能,将需要诊断的模块重机框中拔出,连接console线后将模块插回机框。此时该linecard 进行上电自检,当出现倒计数时键入空格键,terminal会提示:2/1/0? 选择0,该line card 将刷新板卡上的flash(内含系统软件)。正常情况下,linecard 会启动到 boot##提示,同时linecard上的online等点亮,表明该linecard通过诊断已经恢复工作。该过程需要耗时3分钟左右。
如果linecard通过上述诊断最终出现fail灯常亮,表明该模块有硬件故障,取得日志文件后申请返修。
除了对板卡进行硬件诊断外,我们还可以通过show reboot-history可以迅速了解模块故障或重启的原因:
ERX-1400-CN#sh reboot
*** Entry  1 ***
time of reset: THU JUL 08 2004 16:47:18 UTC
run state: unknown
image type: boot
location: slot (4)
build date: 0x3ff1aed1 TUE DEC 30 2003 16:58:57 UTC
reset type: user reboot, task "scheduler", reason "not specified"
*** Entry  2 ***
time of reset: THU JUL 08 2004 16:45:36 UTC
run state: unknown
image type: boot
location: slot (4)
build date: 0x3ff1aed1 TUE DEC 30 2003 16:58:57 UTC
reset type: power cycle

观察某个linemodule reset type,如果出现反复重启并且是“power cyclye
那么可能是该linecard 与机框接触不良,或者是由于该linecard上的DC-DC模块出现故障。前者可以通过更换槽位,如果更换之后同样出现类似的log表明该模块的电源模块有问题,直接提起返修即可。
1.3 软件升级问题及系统配置的恢复
ERX
的系统软件是存放在内部flash上的一个单一的.rel文件。该文件通过ftp方式从ftp server上拷贝后生成。在ftp server上的升级文件由一个xxx.rel文件(例如erx-5-0-3.rel)和多个.exe文件组成,该.rel文件是一个索引文件,内部描述了所有模块软件(subsystem)的名称和大小,通常情况下我们不能对该文件修改。默认情况下我们得到的升级文件包含支持各个类型linecard的模块文件,同时在ftp 拷贝生成ERX flash上的.rel系统软件也包含了所有subsystem,该.rel就是一个full 版本的系统软件。
Full
版本占用的flash 空间较大,系统启动加载需要的时间也较长。我们可以通过生成partial 版本的.rel系统文件来减少启动时间。目前在ERX上使用较多的linecard有:oc3/oc12-atmge/fe它们分别支持4端口oc-3-atm/1端口oc-12-atm 1端口ge/8端口fe i/o module 。所以在拷贝时我们可以不需要加载oc3coc12dpfesubsystem模块软件。在配置模式下配置exclude-subsystem可以实现:
exclude-subsystem ct3
exclude-subsystem ut3a
exclude-subsystem ut3f
exclude-subsystem ct1
exclude-subsystem oc3
exclude-subsystem dpfe
exclude-subsystem oc12p
exclude-subsystem oc3-4p
exclude-subsystem oc3-4a
exclude-subsystem coc12
exclude-subsystem ct3-12
exclude-subsystem oc12s


通常在进行ftp拷贝时会得到如下提示:“copy source not valid”,一种可能是由于ftp server 的帐号设置和erx上的host 配置不匹配引起的,另外如果需要拷贝的subsystem文件在ftp server上不存在也可能引起该现象。
如果ERX上有两个SRP,在reload 之前必须进行同步操作:
ERX-1400-CN#synchronize
Please wait…………………….
ERX-1400-CN#
虽然此时ERX提示同步完成,我们必须通过show utilization进行确认。当standbySRP的利用率为0%时才表明同步操作真正完成,可以进行重启了
为了确保新软件的正常运行,一般建议通过reload slot x standbySRP先进行重启(不影响业务,耗时3分钟左右),此后如果show version 显示新的软件已经被备用SRP运行,说明软机没有问题,此时可以重启主用的SRP
升级失败的对策:
主要现象是SRP一直在启动状态,且业务中断。如果有两块SRP可以尝试将有问题的SRP拔出机框,即强行切换到备用SRP的方式进行恢复。如果只有一块SRP那么只能通过如下方式和顺序进行恢复:
Ø
重启SRP(关电/插拔均可)
Ø console
出现倒计数时键入mb,强行进入boot 模式
Ø
用出厂配置尝试重启:boot##boot configure factory-defaults 然后boot##reload
Ø
如果系统启动成功并且是新的软件版本说明配置文件有问题,此时可以通过配置恢复方式(见以下相关配置)进行配置恢复。
Ø
如果出厂配置时系统仍启动失败表明新的系统软件有问题或者flash有故障。
Ø
尝试恢复到以前的软件版本:boot## boot system  old.rel 然后重启。
Ø
如果启动失败则我们不得不需要对flash进行初始化操作:boot##flash-disk initilize 格式化flash
boot##ip address x.x.x.x x.x.x.x  
配置以太口(SRP I/O )ip
boot##host test x.x.x.x ftp
配置host
boot##copy test:/erx-x.rel  erx-x.rel  
重传系统软件
Ø
然后重启后恢复配置。
系统配置的恢复:
方法一、将backup.cnf拷贝到flash上,在配置模式下boot configure backup.cnf once 然后重启。
方法二、将backup.scr拷贝到flash上,在操作模式下,通过 configure file backup.scr恢复系统配置。
方法一速度较快但需要重启系统,方法二不需重启系统但是需要确保所有模块已经处于online状态才可以进行恢复。
软件升级的步骤:
Ø
备份配置:
host ftpserver x.x.x.x ftp  xxx   xxx  
配置 host
copy running-configure backup.cnf
show config >backup.scr
copy backbup.cnf   ftpserver:/backbup.cnf
copy backup.scr  ftpserver:/backup.scr
Ø
ftp server拷贝系统软件到erxflash
copy ftpserver:/erx-5-0-3.rel  erx-5-0-3.rel
Ø
在配置模式下指定新软件
boot system erx-5-0-3.rel
Ø
在操作模式下进行配置同步
synchronize
Ø
重启备用SRP
reload slot x   x
是备用SRP的所在的槽位
Ø
重启主用SRP(此时业务中断,时间在515分钟)
reload slot x  x
是主用SRP的所在的槽位
设备升级正常但是拨号业务无法恢复:
现象是大部分拨号用户无法进行拨号连接(提示用户名口令错),这可能是由于在重启erx时大量的拨号用户在线但是erx没有及时发出拆线记录(例如突然断电重启erx,这样在radius上这些用户都还处于连接状态,同时radius对用户帐号进行了限制,同一帐号只允许一个session
用以下命令可以观察到radius server拒绝了大部分用户的连接请求:
base radius
show radius statistics delta
SZ_ERX1400_LQF#show radius statistics delta
   RADIUS Authentication Statistics   
   --------------------------------   
     Statistic        202.102.13.66
-------------------   -------------
UDP Port              1812         
Round Trip Time       1            
Access Requests       15200
Rollover Requests     0            
Retransmissions       0      
Access Accepts        0   
Access Rejects        15200
Access Challenges     0            
Malformed Responses   0            
Bad Authenticators    0     
Requests Pending      0            
Request Timeouts      0     
Unknown Responses     0            
Packets Dropped       0     
   
解决的方法是通知radius管理员清除这些用户的拨号记录(可以按照radius client 的地址进行清除)

ERX700/ERX1400配置及故障诊断(2)


2 配置部分

2.1
拨号配置(出现NO SERVICE时的处理)
atm
拨号端口典型配置:
interface atm 12/0
atm clock internal chassis
atm vc-per-vp 4096
atm oam flush
!
interface atm 12/0.332 point-to-point
atm pvc 332 3 32 aal5snap 0 0 0
encapsulation pppoe
pppoe acName wenzhou
!
interface atm 12/0.332.1
encapsulation ppp
ppp authentication pap
profile any pppoe

以太口拨号端口典型配置:
interface gigabitEthernet 8/0.4
vlan id 4
pppoe
!
pppoe subinterface gigabitEthernet 8/0.4.1
encapsulation ppp
ppp authentication pap
profile any pppoe

以下命令可以观察拨号端口是否工作正常:
show pppoe interface atm 5/1----
列出所有atm5/1上的pppoe interface,正常情况下,只要该端口的物理链路和pvc状态是up的,那么所有pppoe interface operational status 应当是up的。
SZ_ERX1400_LQF#show pppoe interface  atm 3/1
PPPoE interface atm 3/1.21101 is operStatusUp
PPPoE interface atm 3/1.21102 is operStatusUp
PPPoE interface atm 3/1.21103 is operStatusUp

show ppp interface gi3/1
――――列出所有gi3/1上的ppp interface ,正常情况下,如果该端口有拨号用户在线则状态应为up,如果没有拨号用户在线状态为lowerdown
SZ_ERX1400_LQF#show ppp interface Gigaethernet 3/1
PPP interface Gigaethernet 3/1.7110.2 is lowerDown
PPP interface Gigaethernet 3/1.7110.3 is lowerDown
PPP interface Gigaethernet 3/1.245112.2 is lowerDown
PPP interface Gigaethernet 3/1.245111.2 is lowerDown
PPP interface Gigaethernet 3/1.152101.1 is up
PPP interface Gigaethernet 3/1.152102.1 is up
PPP interface Gigaethernet 3/1.152103.1 is up

Show pppoe interface atm3/1.xxx
―――检查特定pppoe端口的工作情况,在这里可以看到所有关于本端口的PAD(pppoe active discovery),如果用户申报拨号时无法找到pppoe service可以通过该命令来检测pppoe是否工作正常。
SZ_ERX1400_LQF#show pppoe interface  atm 3/1.21101
PPPoE interface atm 3/1.21101 is operStatusUp
    PPPoE interface atm 3/1.21101 has max sessions = 4094
    PPPoE interface atm 3/1.21101 has 0 active connections,
        out of 1 configured subinterfaces
No baseline has been set
PPPoE Statistics
    PADI-rx 1229
    PADI-tx 0
    PADO-rx 0
    PADO-tx 671
    PADR-rx 640
    PADR-tx 0
    PADS-rx 0
    PADS-tx 640
    PADT-rx 258
    PADT-tx 404
    PADM-tx 610
    PADM-rx 0
    BadPackets 0
    Insufficent Resources 558

实际案例:某电信局在其ERX的百兆端口上上配置了2000个拨号端口(通过script完成),在进行割接时发现所有用户无法找到pppoe service。我们检查了以太网交换机到erx的二层链路(通过将拨号端口配置改为静态ip)发现工作正常。随后通过show pppoe interface fax/x.xxx 检查pppoe的工作情况,
SZ_ERX1400_LQF#show pppoe interface  atm 3/1.21101
PPPoE interface fastethernet 3/1.21101 is operStatusDown
    PPPoE interface fastethernet 3/1.21101 has max sessions = 4094
    PPPoE interface fastethernet 3/1.21101 has 0 active connections,
        out of 1 configured subinterfaces
发现该端口的pppoedown的,同时发现用户在刷新服务时该端口上没有看到有PAD包的增加。同时在物理端口上却能够看到包计数器在增加,这说明该端口的pppoe没有工作,我们将该端口的拨号配置删除并重新配置后一切正常。
由于是割接工作,物理链路只有在割接时才连接到新的端口,所以预先配置完成的拨号端口无法检测是否工作正常。
该案例提示我们在进行割接时,在物理链路起来后,首先应当检查所有端口的pppoe工作状态。( show pppoe interface xxx)。




2.2
固定IP 配置(ATM 端口)
两种应用模式:1483桥接和1483路由
Atm
端口上的固定ip配置:
interface atm 12/0
atm clock internal chassis
atm vc-per-vp 4096
atm oam flush
!
interface atm 12/0.332 point-to-point
atm pvc 332 3 32 aal5snap 0 0 0
encapsulation bridged1483--------
如果是用1483路由方式接入则无需配此命令
ip unnumbered  lo0

interface lo0
ip address 192.168.1.1 255.255.255.255

配置主机路由指向用户ip地址:
ip route 192.168.1.2 255.255.255.255 atm 12/0.332
1483桥接方式下我们可以通过show ip arp 可以观察到用户的mac地址。

ERX700/ERX1400配置及故障诊断(3)


2.3 MACRO的使用
ERX
提供该命令可以使得用户的拨号端口的创建可以批量自动完成。在使用之前首先需要创建扩展名为.macscript 文件。以下是在以太端口(fa4/0fa4/1)上配置拨号数据的script 文本:
<# fa4 #>
―――――――――――子程序名字
<# vlanid:=962 #>
<# while vlanid<=964 #>
――――第一组循环
interface fa4/0.vlanid
vlan id vlanid
encap pppoe
interface fa4/0.vlanid.1
encapsulation ppp
ppp authentication pap
profile any pppoe
<# vlanid:=vlanid+1 #>

<# vlanid:=962 #>
<# while vlanid<=964 #>
――――第二组循环
interface fa4/1.vlanid
vlan id vlanid
encap pppoe
interface fa4/1.vlanid.1
encapsulation ppp
ppp authentication pap
profile any pppoe
<# vlanid:=vlanid+1 #>

<# endwhile #>
每个.mac文件由一个或多个子程序组成,每个子程序可以由多个循环组成但是不能嵌套。
将该mac例如:fast.mac上传到erx,通过以下命令运行该script:
macro test  fast.mac   fa4   ----------macro
每次只能运行一个子程序
test
是一个关键字用于测试该script是否有语法错,如果没有macro会将执行结果输出到telnet窗口上。
如果确认配置无误,将test关键字去掉使得输出结果真正生效(期间不会有屏幕输出)
macro fast.mac fa4

2.4 拨号端口同时配置为DHCP
可以实现在以太和1483桥接端口上既能进行拨号又能通过dhcp上网.
interface atm 12/0.332 point-to-point
atm pvc 332 3 32 aal5snap 0 0 0
encapsulation pppoe
pppoe acName wenzhou
ip unnumbered lo0

配置dhcp relay :
set dhcp relay  x.x.x.x  ―――――――dhcp server ip
需要注意的是的低版本(3.4.1之前)erx不支持在以太端口上同时配置拨号和dhcp
2.5 利用AUTO-CONFIGURE配置动态拨号端口
动态拨号端口的创建是指不需要为每一个拨号用户手工创建pppoe/ppp拨号端口,当端口监测到新的拨号会话时自动创建pppoe端口和相应的ppp子端口。
对于atm端口:
interface atm 5/1.6105   point-to-point
atm pvc 6105 6 105 aal5snap 0 0 0     
auto-configure pppoe
profile pppoe "pppoe-1"

profile "pppoe-1"
ip unnumbered loopback 0
ppp authentication pap
pppoe sessions 1      
――――限制同时在线的拨号端口
对于以太端口:

interface atm 5/1.6105   point-to-point
atm pvc 6105 6 105 aal5snap 0 0 0     
auto-configure pppoe
profile pppoe "pppoe-1"
pppoe sessions 1      

两者的配置区别是:在以太端口上的session数限制必须在pppoe端口下配置。
需要注意5.0以前的版本上不支持在以太端口上创建auto-configure
2.6 MPLS的配置
Ø ldp
的分发方式:erx默认是data-driven 方式分发ldp label在与其他厂家进行互通时需要进行修改为topology-driven方式。
mpls topology-driven-lsp

Ø 限制ldp label :通常情况下,erx会对将所有active的路由表项绑定label,在实际使用中(例如mpls/vpn)我们只需要将本地的loopback绑定label并进行分发即可,可以通过配置ACLlabel的分发进行限制。
access-list onlyme permit ip host 202.96.209.34 any
mpls ldp advertise-labels for onlyme   

Ø
关于router id
在配置使用ibgp时要求ibgpsource-address 必须和router-id一致,如果没有认为指定router-iderx会自动选择一个ip router-id,这样可能导致bgp无法建立连接。
Ip router-id x.x.x.x  -----------
ibgpupdate-source 一致。

Ø
观察bgp路由接收情况
show ip bgp vpnv4 vrf xxx  [y.y.y.y]
可以检查是否收到remote pe分发的vpn路由以及本地广播的vpn路由是否正确。如果加上某个具体的路由y.y.y.y ,可以检查该vpn路由的label等属性。
gongyeyuan-erx1400#sh ip bgp vpnv4 vrf suzhou
Local BGP identifier 61.177.2.96, local AS 64513
  14 routes (784 bytes)
  14 destinations (1008 bytes) of which 14 have a route
  12 routes selected for route table installation
  3 path attribute entries (444 bytes)
  Local-RIB version 29. FIB version 29.

Status codes: > best, * invalid, s suppressed, d dampened, r rejected,
              a auto-summarized

  Prefix             Peer            Next-hop         MED LocPrf Weight Origin
> 0.0.0.0/0          61.177.2.238    61.177.2.238       1    100      0 inc.   
> 10.0.0.0/30        61.177.2.238    61.177.2.238       0    100      0 inc.   
…….
…….
> 61.155.130.192/27  61.177.2.238    61.177.2.238       0    100      0 inc.   
> 172.16.1.0/24      0.0.0.0         0.0.0.0            0         32768 inc.   
――本地vpn路由
> 192.168.1.1/32     0.0.0.0         0.0.0.0            0         32768 inc.   
――本地vpn路由
> 218.30.129.248/29  61.177.2.238    61.177.2.238       0    100      0 inc.   

gongyeyuan-erx1400#sh ip bgp vpnv4 vrf suzhou 10.0.0.0
BGP route information for prefix 10.0.0.0/30
  Received route learned from internal peer 61.177.2.238 (best route)
    Route placed in IP forwarding table
    Best to advertise to external peers
    Address Family Identifier (AFI) is ip-v4
    Subsequent Address Family Identifier (SAFI) is unicast
    Route Distinguisher (RD) is 61.177.2.96:100
    Original Route Distinguisher (RD) is 61.177.2.238:100
    MPLS in-label is none
    MPLS out-label is 589842
―――――――――――vpn 路由中携带的内层 label
    Next hop IP address is 61.177.2.238 (metric 30)
    Multi-exit discriminator is 0
    Local preference is 100
    Weight is 0
    Origin is Incomplete
    AS path is empty  
Extended communities RT:64513:100

Ø Vpn路由接收失败
现象,vrf路由表中没有相应的vpn路由。两个原因:vpn import/export 配置和远端PE的配置不一致,或者本地pe 到远端pelsp没有建立。前者可以通过检查配置确认,后者主要检查mpls方面的工作状态:
show mpls interface---
检查上联端口是否启动mpls
sh mpls interface
Interface GigabitEthernet13/0.12 Up
RSVP not configured
LDP/CR-LDP enabled with profile default
IP interfaces on this MPLS interface:
    221.224.242.78/30
        Session to 61.177.2.253 is operational (active)
        Session negotiated LDP advertisement mode is Downstream Unsolicited
        Session statistics:
          803 label alloc, 5417 label learned,
          803 accum label alloc, 5417 accum label learned,
          last restart time = 00:11:20
          Rcvd: 0 notf, 5559 msg, 5517 mapping, 0 request
                0 abort, 0 release, 0 withdraw, 1 addr
                0 addr withdraw, 6447033 msgId
                0 bad mapping, 0 bad request, 0 bad abort, 0 bad release
                0 bad withdraw, 0 bad addr, 0 bad addr withdraw
                0 unknown msg type err
                last info err code = 0x00000000, 0 loop detected
          Sent: 0 notf, 839 msg, 803 mapping, 0 request
                0 abort, 0 release, 0 withdraw, 1 addr
                0 addr withdraw, 839 msgId
        Adjacency statistics:
          156 hello recv, 136 hello sent, 0 bad hello recv
          adj setup time = 00:11:20
          last hello recv time = 00:00:02, last hello sent time = 00:00:04

MPLS Statistics:
   Rcvd: 1 failed lbl lookup, 758 octets, 0 hcOctets
         14 pkts, 0 hcPkts, 0 errors, 0 discards
   Sent: 0 octets, 0 hcOctets, 0 pkts
         0 hcPkts, 0 errors, 0 discards
   1 adjacency, 1 session, 1 accum adjace
―――检测到mpls neighbor
   156 hello recv, 137 hello sent, 0 hello rej
   1 adj setup, 0 adj deleted,
…………………

show ip tcp statistics------------
检查ldptcp连接是否正常
gongyeyuan-erx1400#sh ip tcp statistics
TCP Global Statistics:
……..
…….
  Local addr: 0.0.0.0, Local port: 646
  Remote addr: 0.0.0.0, Remote port: 0
  State: LISTEN Authentication: None
  Rcvd: 6 total pkts, 0 in-sequence pkts, 0 bytes
        0 chksum err pkts, 0 bad offset pkts, 0 short pkts
        0 duplicate pkts, 0 out of order pkts
  Sent: 0 total pkts, 0 data pkts, 0 bytes
        0 retransmitted pkts, 0 retransmitted bytes

  Local addr: 61.177.2.96, Local port: 646
  Remote addr: 61.177.2.251, Remote port: 41892
  State: ESTABLISHED Authentication: None
  Rcvd: 433 total pkts, 372 in-sequence pkts, 148603 bytes
        0 chksum err pkts, 0 bad offset pkts, 0 short pkts
        0 duplicate pkts, 0 out of order pkts
  Sent: 170 total pkts, 53 data pkts, 5653 bytes
        0 retransmitted pkts, 0 retransmitted bytes
….
….



show ip mpls binding   x.x.x.x ----
检查ldplabel 的接收和绑定情况,x.x.x.x地址为remote pe loopback,正常情况下,每一个remote pe 都会被绑定相对应的一个outgoing