277
In this example, Ethernet 1/1 and Ethernet 1/3 on the LAC are both user access interfaces. The
IP address of Ethernet 1/2, through which the LAC connects to the tunnel, is 1.1.2.1. The IP
address of Ethernet 1/1, through which the LNS connects to the tunnel, is 1.1.2.2.
# Create two local users, set the passwords, and enable the PPP service.
<LAC> system-view
[LAC] local-user vpdn1
[LAC-luser-vpdn1] password simple 11111
[LAC-luser-vpdn1] service-type ppp
[LAC-luser-vpdn1] quit
[LAC] local-user vpdn2
[LAC-luser-vpdn2] password simple 22222
[LAC-luser-vpdn2] service-type ppp
[LAC-luser-vpdn2] quit
# Configure local authentication for the users.
[LAC] domain aaa.net
[LAC-isp-aaa.net] authentication ppp local
[LAC-isp-aaa.net] quit
[LAC] domain bbb.net
[LAC-isp-bbb.net] authentication ppp local
[LAC-isp-bbb.net] quit
# Configure PPPoE servers on interface Ethernet 1/1 and Ethernet 1/3.
[LAC] interface ethernet 1/3
[LAC-Ethernet1/3] pppoe-server bind virtual-template 100
[LAC-Ethernet1/3] quit
[LAC] interface ethernet 1/1
[LAC-Ethernet1/1] pppoe-server bind virtual-template 101
[LAC-Ethernet1/1] quit
# Configure an IP address for interface Ethernet 1/2.
[LAC] interface ethernet 1/2
[LAC-Ethernet1/2] ip address 1.1.2.1 255.255.255.0
[LAC-Ethernet1/2] quit
# Create the VT interfaces and configure CHAP authentication.
[LAC] interface virtual-template 100
[LAC-Virtual-Template100] ppp authentication-mode chap domain aaa.net
[LAC-Virtual-Template100] quit
[LAC] interface virtual-template 101
[LAC-Virtual-Template101] ppp authentication-mode chap domain bbb.net
[LAC-Virtual-Template101] quit
# Create two L2TP groups and configure the related attributes.
[LAC] l2tp enable
[LAC] l2tp-group 1
[LAC-l2tp1] tunnel name LAC-1
[LAC-l2tp1] start l2tp ip 1.1.2.2 domain aaa.net
[LAC-l2tp1] quit
[LAC] l2tp-group 2
[LAC-l2tp2] tunnel name LAC-1
[LAC-l2tp2] start l2tp ip 1.1.2.2 domain bbb.net
# Enable the tunnel authentication and specify a tunnel authentication key.