配置 PPPoE 动态配置文件
您可以为 PPPoE 订阅者配置基本动态配置文件,用于定义动态 PPPoE 逻辑用户接口 (pp0) 的属性。
要配置基本 PPPoE 动态配置文件:
- 命名动态配置文件。
[edit] user@host# edit dynamic-profiles basic-pppoe-profile
- 指定要在
pp0
动态配置文件中配置逻辑接口。[edit dynamic-profiles basic-pppoe-profile] user@host# edit interfaces pp0
- 指定
$junos-interface-unit
为预定义变量,以表示接口的pp0
逻辑单元号。该
$junos-interface-unit
变量将替换为订阅者登录时网络提供的实际单元号。[edit dynamic-profiles basic-pppoe-profile interfaces pp0] user@host# edit unit $junos-interface-unit
- 为
pp0
接口配置 PPPoE 专用选项。- 指定
$junos-underlying-interface
预定义变量以表示路由器创建动态 PPPoE 逻辑接口的底层以太网接口的名称。该
$junos-underlying-interface
变量将替换为订阅者登录时网络提供的底层接口的实际名称。[edit dynamic-profiles basic-pppoe-profile interfaces pp0 unit "$junos-interface-unit"] user@host# set pppoe-options underlying-interface $junos-underlying-interface
- 将路由器配置为 PPPoE 服务器,也称为远程访问集中器。
[edit dynamic-profiles basic-pppoe-profile interfaces pp0 unit "$junos-interface-unit"] user@host# set pppoe-options server
- 指定
- 为
pp0
接口配置 PPP 身份验证协议。对于动态接口,路由器仅支持单向身份验证;也就是说,路由器始终充当验证方在动态配置文件中配置 PPP 身份验证时, chap and pap 语句不支持任何其他配置选项。
要配置 CHAP 身份验证:
[edit dynamic-profiles basic-pppoe-profile interfaces pp0 unit "$junos-interface-unit"] user@host# set ppp-options chap
要配置 PAP 身份验证:
[edit dynamic-profiles basic-pppoe-profile interfaces pp0 unit "$junos-interface-unit"] user@host# set ppp-options pap
- 修改 keepalive 间隔,或将路由器配置为禁用发送 keepalive 消息。
- 为
pp0
接口配置协议家族。- 指定要配置
inet
(IPv4) 或inet6
(IPv6) 协议家族。[edit dynamic-profiles basic-pppoe-profile interfaces pp0 unit "$junos-interface-unit"] user@host# edit family inet
- 指定动态 PPPoE 逻辑接口的 IPv4 或 IPv6 地址。
[edit dynamic-profiles basic-pppoe-profile interfaces pp0 unit "$junos-interface-unit" family inet] user@host# set address 6.6.6.7/32
- 为协议家族配置未编号地址。
[edit dynamic-profiles basic-pppoe-profile interfaces pp0 unit "$junos-interface-unit" family inet] user@host# set unnumbered-address lo0.0
- 指定要应用于动态 PPPoE 逻辑接口的输入和输出服务集。
[edit dynamic-profiles basic-pppoe-profile interfaces pp0 unit "$junos-interface-unit" family inet] user@host# set service input service-set inputService_100 user@host# set service input post-service-filter postService_20 user@host# set service output service-set outputService_200
- 指定要应用于动态 PPPoE 逻辑接口的输入和输出过滤器。
要控制处理过滤器的顺序,您可以选择为输入过滤器和/或输出过滤器指定优先级值。
[edit dynamic-profiles basic-pppoe-profile interfaces pp0 unit "$junos-interface-unit" family inet] user@host# set filter input pppoe-input-filter user@host# set filter output pppoe-output-filter precedence 50
- 指定要配置