我已在 MX80 路由器的接口上配置了订阅者管理。可以为单栈和双栈客户分配(一个)IP 地址。
为此,我创建了两个动态 VLAN 配置文件来创建虚拟 VLAN 接口。
DYNINTF-VLAN-DHCP-INET-KPN {
interfaces {
"$junos-interface-ifd-name" {
unit "$junos-interface-unit" {
proxy-arp restricted;
vlan-id "$junos-vlan-id";
family inet {
unnumbered-address lo0.0 preferred-source-address xx.xx.xx.xx;
}
}
}
}
DYNINTF-STACKED-VLAN-INET-KPN {
interfaces {
"$junos-interface-ifd-name" {
unit "$junos-interface-unit" {
proxy-arp restricted;
vlan-tags outer "$junos-stacked-vlan-id" inner "$junos-vlan-id";
family inet {
unnumbered-address lo0.0 preferred-source-address xx.xx.xx.xx;
}
}
}
}
对于堆叠 VLAN 上的流量监管,我创建了一个动态 IP 配置文件:
DYNSUB-IP-PROFILE-KPN {
interfaces {
"$junos-interface-ifd-name" {
unit "$junos-underlying-interface-unit" {
family inet {
filter {
input "$junos-input-filter";
output "$junos-output-filter";
}
}
}
}
}
}
最后但并非最不重要的是,我必须在 DHCP 组下配置 IP 配置文件才能使其处于活动状态。
dhcp-local-server {
group local-kpn {
interface xe-0/0/3.0 {
dynamic-profile DYNSUB-IP-PROFILE-KPN;
}
}
}
激活最后一个配置文件后,堆叠 VLAN 客户可以很好地应用其 IP 地址和流量策略,但单标记 VLAN 客户则不然。停用 DHCP 服务器组下的 IP 配置文件使其再次适用于单个标记的 VLAN 客户。
我将如何解决这个问题?我可以为单个标记的 VLAN 创建空白防火墙过滤器,但这似乎是一个肮脏的伎俩,不是吗?