示例:配置用于动态创建用户接口的 PPPoE 服务名称表
此示例说明如何配置 PPPoE 服务名称表,以根据 PPPoE 客户端在 PPPoE 协商期间提供的服务名称、代理电路标识符 (ACI) 和代理远程标识符 (ARI) 信息创建动态 PPPoE 用户接口。
在此示例中,PPPoE 服务名称表 TableDynamicPPPoE 包括一个 any 服务条目、 empty 服务条目和两个命名服务条目: Premium 和 Standard。为 TableDynamicPPPoE 是 和 ge-2/0/0.1 ge-2/0/0.2配置的 PPPoE 底层接口。仅 ge-2/0/0.1 配置为动态配置文件分配和动态 PPPoE 用户接口的创建。
在配置示例之后, 表 1 说明了路由器如何评估条 TableDynamicPPPoE 目,以便在指定的路由实例中为几个示例客户端中的每一个创建动态 PPPoE 用户接口。
要配置 PPPoE 服务名称表以创建动态 PPPoE 用户接口,请执行以下作:
配置 PPPoE 服务名称表。
protocols { pppoe { service-name-tables TableDynamicPPPoE { service any { terminate; max-sessions 100; dynamic-profile AnyProfile; agent-specifier { aci "broadway-ge-1/0/1.0" ari "london" { terminate; dynamic-profile LondonProfile; routing-instance LondonRI; } aci "groton-ge-4/0/3.32" ari "paris" { delay 5; dynamic-profile ParisProfile; routing-instance ParisRI; } } } service empty { drop; agent-specifier { aci "dunstable-ge-1/0/0.1" ari "kanata" { dynamic-profile BasicPppoeProfile; delay 10; } } } service Premium { terminate; dynamic-profile PremiumProfile; } service Standard { terminate; max-sessions 10; dynamic-profile StandardProfile; agent-specifier { aci "dunstable-ge-1/0/0.1" ari "kanata" { dynamic-profile BasicPppoeProfile; delay 10; } } } } } }为服务名称表配置 PPPoE 底层接口。
interfaces { ge-2/0/0 { vlan-tagging; unit 1 { vlan-id 1; pppoe-underlying-options { dynamic-profile BasicPppoeProfile; service-name-table TableDynamicPPPoE; } } unit 2 { vlan-id 2; pppoe-underlying-options { service-name-table TableDynamicPPPoE; } } } }
表 1 列出了几个示例 PPPoE 客户端请求中提供的服务名称、ACI 值和 ARI 值,以及路由器接收每个客户端请求的 PPPoE 底层接口的名称。“结果”列描述了路由器基于以下 两个 条件创建的动态 PPPoE 用户接口:
PPPoE 协商期间从每个 PPPoE 客户端接收的值
路由器评估 PPPoE 服务名称表中配置的条目以查找客户端服务名称和 ACI/ARI 信息匹配项的顺序,如 PPPoE 服务名称表中匹配客户端信息的评估顺序中所述
PPPoE客户端 |
服务名称 |
ACI 值 |
ARI 值 |
接收底层接口 |
结果 |
|---|---|---|---|---|---|
客户端 1 |
高级 |
百老汇-ge-1/0/1.1 |
伦敦 |
ge-2/0/0.1 |
匹配为服务配置的 |
客户端 2 |
高级 |
邓斯塔布尔-ge-1/0/1.0 |
多伦多 |
ge-2/0/0.1 |
匹配基本 |
客户端 3 |
空 |
邓斯特布尔-ge-1/0/0.1 |
卡纳塔 |
ge-2/0/0.1 |
匹配为服务和 |
客户端 4 |
空 |
斯林格-ge-1/0/0.1 |
芝加哥 |
ge-2/0/0.2 |
由于接收底层接口 |
客户端 5 |
标准 |
斯林格-ge-1/0/0.1 |
芝加哥 |
ge-2/0/0.1 |
匹配基本 |