示例:为 VPLS 配置 DSCP 分类
此示例说明如何为虚拟专用 LAN 服务 (VPLS) 配置 DSCP 分类器。
要求
此示例使用以下硬件和软件组件:
M 系列多服务边缘路由器(仅限 M120 和 M320)、MX 系列 5G 通用路由平台或带 ATM 接口的 T 系列核心路由器(仅限 TX Matrix Plus)。
Junos OS 10.4 或更高版本。
概述
在此示例中,您在使用ether-vpls-over-atm-llc
封装的 ATM 接口at-4/1/1
上配置 DSCP 分类器dscp_vpls
。分类器dscp_vpls
应用于接口,接口列于入口 PE 路由器上的 VPLS 路由实例vpls1
中。
配置
CLI 快速配置
要为虚拟专用 LAN 服务 (VPLS) 快速配置 DSCP 分类器,请将以下命令复制到文本文件,删除所有换行符,然后将命令粘贴到 CLI 中。
user@host# set interfaces at-4/1/1 mtu 9192 user@host# set interfaces at-4/1/1 atm-options vpi 10 user@host# set interfaces at-4/1/1 unit 0 encapsulation ether-vpls-over-atm-llc user@host# set interfaces at-4/1/1 unit 0 vci 10.128 user@host# set interfaces at-4/1/1 unit 0 family vpls user@host# set class-of-service classifiers dscp dscp_vpls forwarding-class expedited-forwarding loss-priority low code-points 000010 user@host# set interfaces at-4/1/1 unit 0 classifiers dscp dscp_vpls user@host# set routing-instances vpls1 instance-type vpls user@host# set routing-instances vpls1 interface at-4/1/1.0 user@host# set routing-instances vpls1 route-distinguisher 10.255.245.51:1 user@host# set routing-instances vpls1 vrf-target target:1234:1 user@host# set routing-instances vpls1 protocols vpls site-range 10 user@host# set routing-instances vpls1 protocols vpls no-tunnel-services user@host# set routing-instances vpls1 protocols vpls site vpls-1-site-1 site-identifier 1
为虚拟专用 LAN 服务 (VPLS) 配置 DSCP 分类器
逐步过程
以下示例要求您在配置层次结构中的各个级别上导航。有关导航 CLI 的信息,请参阅《Junos OS CLI 用户指南》中的在配置模式下使用 CLI 编辑器。
要为虚拟专用 LAN 服务配置 DSCP 分类器 (VPLS:
将 ATM 接口
at-4/1/1.0
和封装配置为ether-vpls-over-atm-llc
。[edit interfaces] user@host# set at-4/1/1 mtu 9192 user@host# set at-4/1/1 atm-options vpi 10 user@host# set at-4/1/1 unit 0 encapsulation ether-vpls-over-atm-llc user@host# set at-4/1/1 unit 0 vci 10.128 user@host# set at-4/1/1 unit 0 family vpls
配置 DSCP 分类器
dscp_vpls
。[edit class-of-service] user@host# set classifiers dscp dscp_vpls forwarding-class expedited-forwarding loss-priority low code-points 000010
将分类器
dscp_vpls
应用于 ATM 接口at-4/1/1.0
。[edit interfaces] user@host# set at-4/1/1 unit 0 classifiers dscp dscp_vpls
将 ATM 接口虚拟电路
at-4/1/1.0
包含在路由实例vpls1
配置中。user@host# set routing-instances vpls1 instance-type vpls user@host# set routing-instances vpls1 interface at-4/1/1.0 user@host# set routing-instances vpls1 route-distinguisher 10.255.245.51:1 user@host# set routing-instances vpls1 vrf-target target:1234:1 user@host# set routing-instances vpls1 protocols vpls site-range 10 user@host# set routing-instances vpls1 protocols vpls no-tunnel-services user@host# set routing-instances vpls1 protocols vpls site vpls-1-site-1 site-identifier 1
结果
在配置模式下,输入 、 show class-of-service
和show routing-instances
命令,show interfaces
以确认您的配置。如果输出未显示预期的配置,请重复此示例中的说明,以更正配置。
user@host# show interfaces at-4/1/1
mtu 9192; atm-options { vpi 10; } unit 0 { classifiers { dscp dscp_vpls; } encapsulation ether-vpls-over-atm-llc; vci 10.128; family vpls; }
user@host# show class-of-service
classifiers { dscp dscp_vpls { forwarding-class expedited-forwarding { loss-priority low code-points 000010; } } }
user@host# show routing-instances
vpls1 { instance-type vpls; interface at-4/1/1.0; route-distinguisher 10.255.245.51:1; vrf-target target:1234:1; protocols { vpls { site-range 10; no-tunnel-services; site vpls-1-site-1 { site-identifier 1; } } } }