Академический Документы
Профессиональный Документы
Культура Документы
@MX BNG
пример конфигурации
Версия v0.1 (21.01.2019)
Содержание
Цель..............................................................................................................................................................................2
Топология ....................................................................................................................................................................2
Железо и софт .............................................................................................................................................................3
Конфигурация – физический интерфейс...................................................................................................................3
Конфигурация – динамический профиль (для сессии) ...........................................................................................4
Конфигурация – динамический профиль (для сервиса) .........................................................................................5
Конфигурация – Радиус ..............................................................................................................................................6
Проверка......................................................................................................................................................................6
Полная конфигурация MX BNG ................................................................................................................................14
Полная конфигурация EX4550..................................................................................................................................20
1
Цель
Зафиксировать рабочую конфигурация MX BNG для packet-triggered абонентов (directly-
connected и non-directly-connected).
Топология
Radius
Vlan 30
192.168.30.2
192.168.30.1
MX80
EX4550 xe-0/0/0 xe-0/0/0
BNG
Vlan 10
192.168.10.1
10g 10g
Vlan 40
Vlan 20
Uplink
192.168.10.2 (vlan 10) – directly connected subscriber
192.168.20.2 (vlan 20) – non-directly connected subscriber
Абонент во влане 10 имеет Layer2 связность с MX (=влан 10 проходит через EX4550 на уровне
Layer2 и терминируется на MX). Абонент во влане 20 не имеет Layer2 связности с MX (=влан 20
терминируется на EX4550).
Настройки маршрутизации:
2
Железо и софт
matvey@mx80-27# run show chassis hardware
Hardware inventory:
Item Version Part number Serial number Description
Chassis G6846 MX80-P
Midplane REV 03 711-044315 CABR1821 MX80-P
PEM 0 Rev 05 740-028288 XH07739 AC Power Entry Module
PEM 1 Rev 03 740-028288 UE00180 AC Power Entry Module
Routing Engine BUILTIN BUILTIN Routing Engine
TFEB 0 BUILTIN BUILTIN Forwarding Engine Processor
QXM 0 REV 06 711-028408 CABP0309 MPC QXM
FPC 0 BUILTIN BUILTIN MPC BUILTIN
MIC 0 BUILTIN BUILTIN 4x 10GE XFP
PIC 0 BUILTIN BUILTIN 4x 10GE XFP
Xcvr 0 NON-JNPR T15F10289 XFP-10G-SR
Xcvr 1 REV 01 740-011571 C728XJ037 XFP-10G-SR
FPC 1 BUILTIN BUILTIN MPC BUILTIN
MIC 0 REV 24 750-028392 YR8017 3D 20x 1GE(LAN) SFP
PIC 0 BUILTIN BUILTIN 10x 1GE(LAN) SFP
PIC 1 BUILTIN BUILTIN 10x 1GE(LAN) SFP
Fan Tray Fan Tray
Конфигурация – Радиус
Авторизуем абонентов с любым логином и паролем, дополнительно навешивая на
абонентскую сессию сервис RATE-LIMIT с ограничением скорости 50 mbps.
Проверка
6
Проверку выполняем с помощью трафик-генератора.
7
Диагностика с MX BNG:
Type: DYN-IP
User Name: 192.168.20.2
IP Address: 192.168.20.2
Logical System: default
Routing Instance: default
Interface: demux0.3221225475
Interface type: Dynamic
Underlying Interface: xe-0/0/0.30
Interface description: -- to EX
Dynamic Profile Name: PKTS-DYN-PROFILE-2
Dynamic Profile Version: 1
MAC Address: 3c:8a:b0:10:11:41
State: Active
Radius Accounting ID: 6
Session ID: 6
PFE Flow ID: 12
VLAN Id: 30
Login Time: 2019-01-21 13:58:05 CET
Service Sessions: 1
8
matvey@mx80-27# run show subscribers extensive | no-more
Jan 21 14:01:20
Type: DYN-IP
User Name: 192.168.10.2
IP Address: 192.168.10.2
Logical System: default
Routing Instance: default
Interface: demux0.3221225474
Interface type: Dynamic
Underlying Interface: xe-0/0/0.10
Interface description: -- to EX
Dynamic Profile Name: PKTS-DYN-PROFILE-2
Dynamic Profile Version: 1
MAC Address: 00:11:01:00:00:01
State: Active
Radius Accounting ID: 5
Session ID: 5
PFE Flow ID: 10
VLAN Id: 10
Login Time: 2019-01-21 13:58:05 CET
Service Sessions: 1
Accounting interval: 600
Type: DYN-IP
User Name: 192.168.20.2
IP Address: 192.168.20.2
Logical System: default
Routing Instance: default
Interface: demux0.3221225475
Interface type: Dynamic
Underlying Interface: xe-0/0/0.30
Interface description: -- to EX
Dynamic Profile Name: PKTS-DYN-PROFILE-2
Dynamic Profile Version: 1
MAC Address: 3c:8a:b0:10:11:41
9
State: Active
Radius Accounting ID: 6
Session ID: 6
PFE Flow ID: 12
VLAN Id: 30
Login Time: 2019-01-21 13:58:05 CET
Service Sessions: 1
Accounting interval: 600
Subscribers by State
Active: 2
Total: 2
Filter: __default_bpdu_filter__
Filter: inter-ff-in_UID1004-demux0.3221225474-in
Counters:
Name Bytes Packets
__junos-dyn-service-counter 2387951370 2383185
Policers:
Name Bytes Packets
inter-plr_UID1003-filter-demux0.3221225474-in 2268879702 2264351
Filter: inter-ff-out_UID1005-demux0.3221225474-out
Counters:
Name Bytes Packets
__junos-dyn-service-counter 0 0
Policers:
Name Bytes Packets
inter-plr_UID1003-filter-demux0.3221225474-out 0 0
Filter: inter-ff-in_UID1004-demux0.3221225475-in
Counters:
Name Bytes Packets
__junos-dyn-service-counter 2389491444 2384722
Policers:
Name Bytes Packets
inter-plr_UID1003-filter-demux0.3221225475-in 2268830604 2264302
Filter: inter-ff-out_UID1005-demux0.3221225475-out
Counters:
Name Bytes Packets
__junos-dyn-service-counter 0 0
Policers:
Name Bytes Packets
inter-plr_UID1003-filter-demux0.3221225475-out 0 0
12
matvey@mx80-27# run show system license
Jan 21 14:07:50
License usage:
Licenses Licenses Licenses Expiry
Feature name used installed needed
subscriber-accounting 1 1 0 permanent
subscriber-authentication 0 1 0 permanent
subscriber-address-assignment 0 1 0 permanent
subscriber-vlan 0 1 0 permanent
subscriber-ip 0 1 0 permanent
service-dc 0 1 0 permanent
service-accounting 0 1 0 permanent
service-qos 0 1 0 permanent
service-ancp 0 1 0 permanent
service-cbsp 0 1 0 permanent
scale-subscriber 2 16000 0 permanent
scale-l2tp 0 1000 0 permanent
scale-mobile-ip 0 1000 0 permanent
…
matvey@mx80-27# run show route protocol access-internal
Jan 21 14:21:29
14
}
subscriber-management {
enable;
}
}
syslog {
user * {
any emergency;
}
host 172.30.189.13 {
any notice;
authorization info;
interactive-commands info;
}
host 172.30.189.14 {
any notice;
authorization info;
interactive-commands info;
}
file messages {
any notice;
authorization info;
}
}
compress-configuration-files;
ntp {
boot-server 172.30.207.10;
server 172.30.207.10;
}
}
dynamic-profiles {
PKTS-DYN-PROFILE-2 {
interfaces {
demux0 {
unit "$junos-interface-unit" {
actual-transit-statistics;
demux-options {
underlying-interface "$junos-underlying-interface";
}
family inet {
demux-source {
$junos-subscriber-demux-ip-address;
}
unnumbered-address lo0.0 preferred-source-address 192.168.10.1;
}
}
}
}
}
RATE-LIMIT {
variables {
var-bw mandatory;
var-burst equals "round($var-bw*6/80)";
15
inter-ff-in uid;
inter-ff-out uid;
inter-plr uid;
}
interfaces {
demux0 {
unit "$junos-underlying-interface-unit" {
family inet {
filter {
input "$inter-ff-in" precedence 100;
output "$inter-ff-out" precedence 100;
}
}
}
}
}
firewall {
family inet {
filter "$inter-ff-in" {
interface-specific;
term 1 {
then {
policer "$inter-plr";
service-accounting;
accept;
}
}
term 2 {
then accept;
}
}
filter "$inter-ff-out" {
interface-specific;
term 1 {
then {
policer "$inter-plr";
service-accounting;
accept;
}
}
term 2 {
then accept;
}
}
}
policer "$inter-plr" {
logical-interface-policer;
if-exceeding {
bandwidth-limit "$var-bw";
burst-size-limit "$var-burst";
}
then discard;
}
16
}
}
}
chassis {
network-services enhanced-ip;
}
access-profile RADIUS;
interfaces {
xe-0/0/0 {
description "-- to EX";
flexible-vlan-tagging;
mtu 9000;
encapsulation flexible-ethernet-services;
gigether-options {
no-flow-control;
}
unit 10 {
demux {
inet {
address source;
auto-configure {
address-ranges {
dynamic-profile PKTS-DYN-PROFILE-2 {
network 192.168.10.0/24 {
range R1 {
low 192.168.10.2/32;
high 192.168.10.254/32;
}
}
}
authentication {
password juniper;
username-include {
source-address;
}
}
}
}
}
}
vlan-id 10;
family inet {
unnumbered-address lo0.0 preferred-source-address 192.168.10.1;
}
}
unit 30 {
demux {
inet {
address source;
auto-configure {
address-ranges {
dynamic-profile PKTS-DYN-PROFILE-2 {
network 192.168.20.0/24 {
17
range R1 {
low 192.168.20.2/32;
high 192.168.20.254/32;
}
}
}
authentication {
password juniper;
username-include {
source-address;
}
}
}
}
}
}
vlan-id 30;
family inet {
address 192.168.30.1/30;
}
}
}
xe-0/0/1 {
description "-- to iXia";
flexible-vlan-tagging;
mtu 9000;
encapsulation flexible-ethernet-services;
gigether-options {
no-flow-control;
}
unit 40 {
vlan-id 40;
family inet {
address 192.168.40.1/24;
}
}
}
fxp0 {
unit 0 {
family inet {
address 172.30.177.49/24;
}
}
}
lo0 {
description "-- loopback";
unit 0 {
family inet {
address 192.177.0.49/32 {
preferred;
}
address 127.0.0.1/32;
address 192.168.10.1/32;
18
}
family iso {
address 49.0177.0000.0000.0049.00;
}
}
}
}
snmp {
location "AMS, EPOC location=2.04";
contact "emea-poc@juniper.net";
community public {
authorization read-only;
clients {
172.30.0.0/16;
0.0.0.0/0 restrict;
}
}
community private {
authorization read-write;
clients {
172.30.0.0/16;
0.0.0.0/0 restrict;
}
}
trap-options {
source-address 172.30.177.49;
}
}
routing-options {
static {
route 172.16.0.0/12 {
next-hop 172.30.177.1;
no-readvertise;
}
/* -- non-directly connected subscribers */
route 192.168.20.0/24 next-hop 192.168.30.2;
}
router-id 192.177.0.49;
autonomous-system 100;
}
access {
radius-server {
172.30.189.41 {
port 1812;
accounting-port 1813;
secret "$9$JVUi.QF/0BEP5BEcyW8ZUj"; ## SECRET-DATA
timeout 5;
retry 3;
source-address 172.30.177.49;
}
}
profile RADIUS {
accounting-order radius;
19
authentication-order radius;
radius {
authentication-server 172.30.189.41;
accounting-server 172.30.189.41;
options {
nas-port-id-delimiter :;
calling-station-id-delimiter :;
calling-station-id-format {
nas-identifier;
interface-description;
}
accounting-session-id-format decimal;
coa-dynamic-variable-validation;
}
}
accounting {
order radius;
inactive: immediate-update;
coa-immediate-update;
update-interval 10;
statistics volume-time;
}
service {
accounting-order radius;
}
}
report-interface-descriptions;
}
24