找回密码
 注册
查看: 1001|回复: 0

华为路由器:PPPOE配置模拟实验及NAT配置

[复制链接]

1

主题

0

回帖

12

积分

管理员

积分
12
QQ
发表于 2022-3-16 09:39:09 | 显示全部楼层 |阅读模式
实验环境5 n. l8 V7 ?. |3 ?% s  _0 r  g
0 E1 a" z/ q* Z- X9 _; Y3 ]
pppoe-client上面的接口信息6 L4 Q& ]1 `# J
+ y- o/ D" J" N; S5 @5 {4 h- R
[AR1]dis ip interface brief
5 l4 O& ^  l+ U, B*down: administratively down7 K: o: g) o5 W; x- O
^down: standby5 N) l! x+ u/ [/ }1 e1 v) T
(l): loopback
& w3 K$ O3 s1 u(s): spoofing6 J) k8 e5 ~" u6 \8 u: z3 ]
The number of interface that is UP in Physical is 2' d1 r  U8 G$ ?" b. a3 X
The number of interface that is DOWN in Physical is 1
3 k2 P, X$ K: ]7 C5 Z, YThe number of interface that is UP in Protocol is 1: v6 z' I5 J, J
The number of interface that is DOWN in Protocol is 2
8 d4 d/ b9 W# X' [- E0 h2 x; @5 j: N6 Z4 Q+ Q
Interface                         IP Address/Mask      Physical   Protocol  
) G* P9 l5 \! B# R- ?: iGigabitEthernet0/0/0              unassigned           up         down      
- [/ s  F% [$ E! n4 LGigabitEthernet0/0/1              192.168.1.254/24     down       down      ' L& o; u1 T& v5 a3 O
NULL0                             unassigned           up         up(s)     
& e0 E8 v& k2 _+ y. b$ U% ~
% ^! V6 V# o' g" g' X3 s0 t; F: E2 }/ |, Q- ^% h; l
配置了基于接口的DHCP
0 H: ^, m/ Q4 d' @5 ?6 E  N: |" W6 m( F- e. O8 I: |' W: }9 p/ l! W* L
interface GigabitEthernet0/0/1
  J$ y! X3 N4 O6 a) l ip address 192.168.1.254 255.255.255.0 + g' l0 w1 t6 r9 }" N. O
dhcp select interface3 C8 q8 ~" a2 D- n5 e1 a  v
dhcp server dns-list 8.8.8.8 ! n( N1 f, _) U* D! j% I0 Q
dhcp server domain-name pokes.com, A$ l9 i, x  {. J
; ^7 _1 E6 n) u( V' H2 D/ h' u
注意事项:AR1、AR2的物理接口g0/0/0不配地址.+ }6 j8 u/ r9 s; |
  D: E+ m5 h% k0 W9 R6 \9 O
一、pppoe-server的配置& s; d9 g2 L/ [# y- p: ]! n6 K
1、pppoe-server 配置地址池
% T  o7 _+ Q, i[pppoe-server]ip pool pokes            #创建名为pokes的地址池,名字可以随便起,后面要调用
5 O+ Y, y. o6 r. m8 nInfo: It's successful to create an IP address pool.
$ U, T1 r6 ?3 A[pppoe-server-ip-pool-pokes]network 10.1.12.0 mask 24   #地址池为10.1.12.0/24$ v9 g8 d( P6 G- j' v5 j
[pppoe-server-ip-pool-pokes]dis th
/ O3 W( H- u) ?4 _) h[V200R003C00]& m: S7 q3 `: }# q4 C! q6 e
#
8 ]9 y! E- G' G1 D# wip pool pokes
# H% v7 {5 G, u5 H* [% s3 M network 10.1.12.0 mask 255.255.255.0 ' C# j, E% d; \, |9 z2 {: v) I
#; g# t' g2 T  G0 @
return9 x! ^; d0 f3 i) f  D! l8 ~+ s
[pppoe-server-ip-pool-pokes]q# h* m" p) `! R$ P
9 K4 l  C/ V9 [& @- `5 x3 K  b  B! A: Z
2、配置虚拟口关联地址池( y: j: y4 Y8 @; V) X! a
配置虚拟口关联地址池,即创建Virtual-Template 1模版。
. z2 r" W8 m% |9 a0 z* a% o  t( |
( I4 r4 }) g& ]* @9 W/ |4 ^6 `1 [3 a[pppoe-server]interface Virtual-Template 1    #创建虚拟接口1# g# R; c# ]3 Z
[pppoe-server-Virtual-Template1]ip add 10.1.12.2 24                   #虚拟接口1的地址6 {, K5 c1 p4 V
[pppoe-server-Virtual-Template1]ppp authentication-mode chap   #认证类型, m! J2 w4 h' Q6 n+ m
[pppoe-server-Virtual-Template1]remote address pool pokes      #客户端的地址池pokes
6 u% v" Z1 ^; [, J[pppoe-server-Virtual-Template1]dis th3 T  x6 M7 H% Y8 ?
interface Virtual-Template1
$ p9 w  W9 t/ Q ppp authentication-mode chap   L$ N# {! m" `& x5 A1 W
remote address pool pokes
1 F1 v7 h/ K4 Z/ w ip address 10.1.12.2 255.255.255.0
# I% Q) l" s+ X1 }" c8 N0 r$ m' C0 u4 _( }; J$ J- q5 F' A
[pppoe-server]int g0/0/0       
* O( h. C! s! r" t4 r1 [! U[pppoe-server-GigabitEthernet0/0/0]pppoe-server bind virtual-template 1   #将虚拟接口1关联到g0/0/0接口6 l0 |* }; P$ n1 F( Y  Y" w
[pppoe-server-GigabitEthernet0/0/0]dis th
+ f' p, l( v, R% }[V200R003C00]8 |9 T& W: M# ~
#3 M4 U* o) m. `+ A8 i
interface GigabitEthernet0/0/09 D& l  a8 Z- ]9 e1 W
pppoe-server bind Virtual-Template 1
& f0 P* l% H' z3 b! ^#
" }- Y) B8 e7 R( Dreturn
  {* {; `# D2 d- ^& @5 I; K[pppoe-server-GigabitEthernet0/0/0]
3 r3 n1 y0 k; W7 s0 l7 U  |4 }# b. B/ I3 R
3、创建pppoe拨号的账号( J' ?! i4 K7 m1 D8 ]& t2 a
按理我们应该创建pppoe拨号的账号。
' V) X/ ~* r7 d& O$ C, S- [8 x这里为了演示拨号失败,我们这里先不新建账号,后面再新建。, o! n' M# x* _: b/ b
5 x3 a4 g6 A, E+ F& b# K+ h
二、pppoe-client的配置) u$ l7 `, Y( p6 c, b& @
[pppoe-client]dialer-rule   
6 q/ ]# N- p: K' K' F[pppoe-client-dialer-rule]dialer-rule 1 ?* P4 q, _% @9 K" d& Z
  acl   Permit or deny based on access-list   
1 e2 e8 |3 r) W+ ?$ x9 O  ip    Ip
8 e& B1 H3 m$ W1 V1 K& c8 l  ipv6  Ipv6       
9 l5 h( n& Z! n9 R' i[pppoe-client-dialer-rule]dialer-rule 1 ip permit   #创建拨号规则,允许ip流量触发拨号- B; ^8 e3 w2 {

. N% C( N% v7 g5 C[pppoe-client]interface Dialer 1
( R! a* ~: H/ l- N- XJul 15 2021 18:55:22-08:00 pppoe-client %%01IFPDT/4/IF_STATE(l)[0]:Interface Dia& y. c% J. K9 P  t
ler1 has turned into UP state.
0 n& c1 d5 _" D9 g4 \. O[pppoe-client-Dialer1]ip add        : M  y: x$ V; p2 h% d. P% V
[pppoe-client-Dialer1]ip address ppp       
9 Y7 W/ w" t) w7 E% g& f) h) u/ P[pppoe-client-Dialer1]ip address ppp-negotiate  #地址采用ppp协商
+ `+ _6 [% E# g5 D
! ~" o! T1 ~4 I0 s4 l0 v[pppoe-client]interface Dialer 1                #创建接口拨号组1% Z# u$ |" U3 b1 Z$ d& @7 _
[pppoe-client-Dialer1]ip address ppp-negotiate  #ip地址采用ppp协商
1 @; h6 M: a9 x! S" B2 a[pppoe-client-Dialer1]dialer user zhprny        #此用户不用于认证,是标识作用以及和dialer绑定
2 F4 p' n6 |* ?[pppoe-client-Dialer1]dialer bundle 1           #设备通过Dialer bundle将物理接口与拨号接口关联起来。% I; R9 I: w# R0 v! i
[pppoe-client-Dialer1]dialer-group 1             #放到一个拨号访问组1中
3 J( t, ]! |5 h- r) b  l" ~, p7 V[pppoe-client-Dialer1]ppp chap user pokes        #指定dialer1接口的编号,拨号账号
- l$ C$ m% n  j) F  b[pppoe-client-Dialer1]ppp chap password 123456   #拨号的密码3 G& E. }9 W9 ~# A% o
; @' _- |& }+ m$ w' ^
# c# Z7 c6 r% D: v& M" L
[pppoe-client-Dialer1]dis th6 a% S. ~1 f/ Z% e% }% A
[V200R003C00]
1 f) s: H# i' R4 c2 g#" K" ~. a2 c" B
interface Dialer1. L5 l" b0 J+ P! ^, q0 U5 j5 i7 `
link-protocol ppp+ S+ a! _0 H4 l: U* c
ppp chap user pokes
$ b4 t# p% q5 g" v ppp chap password cipher %$%$I/!'WCyd<7p[~8;,>51L,$sl%$%$
  d1 W8 m9 S$ D! z; T& W ip address ppp-negotiate
$ o4 a$ t: o+ p' w0 Y dialer user zhprny
3 a0 X9 N3 f5 \% |7 E& r dialer bundle 14 p' u4 M/ A) p
dialer-group 1" o( |) I5 l6 x4 T

8 i2 N1 @4 }& A4 b4 k[pppoe-client-GigabitEthernet0/0/0]; d' r; o, n% d6 S, b/ X, U% ^
Jul 15 2021 19:07:54-08:00 pppoe-client %%01IFNET/4/LINK_STATE(l)[0]:The line pr; M7 x( ^8 Y) a9 N2 x  q7 M* W
otocol PPP on the interface Dialer1:0 has entered the UP state.  #PPP已进入启动状态
+ y" Q) o1 v2 u2 A2 l& \+ L[pppoe-client-GigabitEthernet0/0/0]' G# g! W/ v6 R) B
Jul 15 2021 19:07:54-08:00 pppoe-client %%01IFNET/4/LINK_STATE(l)[1]:The line pr; f$ l: T! {# F+ }/ Y
otocol PPP on the interface Dialer1:0 has entered the DOWN state. #PPP已进入关闭状态  w( D' s4 X8 B, S' _2 H- M

3 G2 ~$ [  ^5 _: F  `/ u#不停的循环。。。。& S4 B( z- k5 d2 E
1 z' P  c8 ^4 i5 q9 _  S! M; ~
7 g- T4 L  X5 L, `" N
#原因是没有认证成功,因为我们在PPPOE-server上面还没有创建认证用户和密码
* n3 g3 E! ]4 j3 d* @# o0 Z3 ]" G& d* U" ?
三、pppoe服务器上新建认证用户( x0 C! {& t, u$ U
我们到服务器上直接新建认证用户:
9 i$ z6 l+ [) j; h" `- V8 a, m+ f% ?6 o
[pppoe-server]aaa
9 H2 }, V8 c& N' F* }[pppoe-server-aaa]local-user pokes password cipher 123456" m& ^# Q0 _- F2 D& A( d/ Y( a" V
Info: Add a new user.
4 i& s% `, f  B. n& ]# K[pppoe-server-aaa]local-user pokes service-type ppp    #类型为ppp- E: p- ^+ z5 ?

; x" }$ s9 a0 o, Q
  v9 ]1 ]+ o- }+ ?- N四、客户端验证结果. r& z* B7 `( }6 f
1、认证成功信息3 c/ s  d! h- J: ~  T2 ?
然后客户端就会出现认证成功的提示:
: f6 g% o7 t" Q. m! _2 X9 C5 o% M4 ?- Y) y6 i
[pppoe-client-GigabitEthernet0/0/0]
1 I& q8 V7 z, i9 F. L8 }- l  JJul 15 2021 19:09:23-08:00 pppoe-client %%01IFNET/4/LINK_STATE(l)[10]:The line p
; z. c+ D5 Y$ E7 Q3 [rotocol PPP on the interface Dialer1:0 has entered the UP state. 4 S* G" x% A. a4 u* Y; Y2 U
[pppoe-client-GigabitEthernet0/0/0]
9 _! K# _5 P. @- `9 MJul 15 2021 19:09:23-08:00 pppoe-client %%01IFNET/4/LINK_STATE(l)[11]:The line p! }: ]5 D0 y2 ~  b0 L8 H4 e
rotocol PPP IPCP on the interface Dialer1:0 has entered the UP state.
7 g; ^, L* W( h- e7 v[pppoe-client-GigabitEthernet0/0/0]q
9 r# w0 n" [9 H9 V9 l7 d( [[pppoe-client]dis ip in b: A0 i/ R; K' {; e- u  c: {: z
*down: administratively down0 C5 i7 h8 B3 G/ d9 J
^down: standby, D! S+ }4 @) I: r
(l): loopback
- M; g+ d0 r$ b( g5 a. _(s): spoofing8 W4 ?! `$ p3 r$ l6 t
The number of interface that is UP in Physical is 4
8 a0 |! A6 E4 ^3 o4 xThe number of interface that is DOWN in Physical is 0
- ?9 Z& f- O7 t# s7 o; QThe number of interface that is UP in Protocol is 3/ q  A; F- q2 n+ V* B+ ~
The number of interface that is DOWN in Protocol is 1( P+ ~2 x7 \# I% I

5 u' f4 b1 Q1 R' MInterface                         IP Address/Mask      Physical   Protocol  
4 b7 X- b+ ]$ D- ^. ZDialer1                           10.1.12.254/32       up         up(s)     #拿到了PPPOE服务器上的地址
5 Y% u! A9 a8 g5 J$ D" ]0 c+ c8 gGigabitEthernet0/0/0              unassigned           up         down      . o& D  d+ H  [  j- T/ Q. p
GigabitEthernet0/0/1              192.168.1.254/24     up         up        
. h; Y" @- ^1 n# ~- n: F* r) iNULL0                             unassigned           up         up(s) 8 \+ f- b- W1 p/ G

& N- ]* ?% R2 k# ]1 i# C/ k6 E0 t' I3 a5 _3 X: d1 C) g
2、pppoe-server 信息
" h1 D- U+ U1 P<pppoe-server>dis interface Virtual-Template 1
& l/ c3 b' I5 K* `& eVirtual-Template1 current state : UP: t; l/ Y" q+ P- T& Y
Line protocol current state : UP
, W5 g- v, ]. r( X) kLast line protocol up time : 2021-07-15 19:09:22 UTC-08:009 z! b  `8 g; H% h/ |5 Y
Description:HUAWEI, AR Series, Virtual-Template1 Interface
* B( v& g' \1 s2 R; a$ lRoute Port,The Maximum Transmit Unit is 1492, Hold timer is 10(sec)
: \* w& E% t1 G4 H9 @7 C# s7 ]Internet Address is 10.1.12.2/24  Z1 N7 L9 p# c
Link layer protocol is PPP
5 @  p  e( Y9 pLCP initial
( q; N; ]4 u: {$ jPhysical is None
9 X% h: B7 [0 b! {/ e' C6 @1 [Current system time: 2021-07-15 20:27:28-08:00+ ~) ?5 W/ X! E- A9 F& R0 |( |
    Last 300 seconds input rate 0 bits/sec, 0 packets/sec
$ C  n) D  [; K0 Z. I2 R; B0 a    Last 300 seconds output rate 0 bits/sec, 0 packets/sec' a$ [* l! U9 {- z# `
    Realtime 0 seconds input rate 0 bits/sec, 0 packets/sec# n$ h7 W/ Z" ]9 \- \$ N% k
    Realtime 0 seconds output rate 0 bits/sec, 0 packets/sec$ L3 ^8 h3 F& n; e
    Input: 0 bytes
6 @* t, ~2 m, n    Output:0 bytes$ y8 V: n2 e3 j! p' e
    Input bandwidth utilization  :    0%
8 G: P# L" Z7 T$ S1 f9 p    Output bandwidth utilization :    0%
! O2 Z( u. M* t  Y' n- y7 e
0 l! J, D. D7 x. P4 v<pppoe-server>
' z8 U4 l! h) Z# x+ \% W* P6 B* q1 w& Z5 I  u
; o; O. P) c3 y
3、pppoe-client信息
5 r8 d! p1 M) ?- B; t! }<pppoe-client>dis interface Dialer 1
! b7 V" g8 S: @8 s2 }# ]( a* H0 _Dialer1 current state : UP
/ V! M6 K. o' S- e& C# xLine protocol current state : UP (spoofing)2 D# X& z8 J8 J+ ~5 F# v+ S
Description:HUAWEI, AR Series, Dialer1 Interface
% U  A5 ~0 F6 u. R7 [. X( URoute Port,The Maximum Transmit Unit is 1500, Hold timer is 10(sec)
/ x! w9 q) T4 W+ Z; F* ^8 cInternet Address is negotiated, 10.1.12.254/32, I) N( g( ^3 b( o( L# A( o  Z
Link layer protocol is PPP
$ a  Z" P: X5 lLCP initial
$ N- ]- @0 K0 ^5 Y: `- [Physical is Dialer
( C# X# ^# b2 v( A" \0 f! CCurrent system time: 2021-07-15 20:23:56-08:00
8 n4 F" I& s: Z    Last 300 seconds input rate 0 bits/sec, 0 packets/sec9 p6 h) Z$ O6 |3 S' m0 N4 ^0 r# b  E
    Last 300 seconds output rate 0 bits/sec, 0 packets/sec
$ V+ ^' _* ]4 ^) l    Realtime 0 seconds input rate 0 bits/sec, 0 packets/sec& p8 |3 t' }7 b9 T5 s" x( w5 t
    Realtime 0 seconds output rate 0 bits/sec, 0 packets/sec) {2 M9 U- Y4 W: h. _% |# ^; K
    Input: 0 bytes* P: z# E+ m' o
    Output:0 bytes% {' u8 O; L- O: x! U( n
    Input bandwidth utilization  :    0%3 y. [$ S3 W6 g% P
    Output bandwidth utilization :    0%
3 e$ _. B' t  X" x* L/ u, ZBound to Dialer1:0:: o" c: I2 S4 e2 a' ]" D" |) F8 M
Dialer1:0 current state : UP ,
8 M+ R$ w! G* Q6 K" O! {Line protocol current state : UP
4 n- e" R0 V& f' ^  Q# w5 d4 N" l' S4 u4 {( t0 D; [$ i
Link layer protocol is PPP
' t& O9 j) A2 v9 ~& Q+ H1 HLCP opened, IPCP opened
! |: W3 l( W' U$ |' ~9 X0 ~Packets statistics:5 F( z. n9 E" G+ ~: {$ i' ?
  Input packets:0,  0 bytes" Z0 w+ b8 P+ ]& u4 L$ y
  Output packets:4, 336 bytes
6 R* o# G, D, u8 i  FCS error packets:0& {. r) o4 j, q: r$ F
  Address error packets:0
& s) a* b7 m% i  Control field control error packets:0$ E3 G+ m) z3 R0 p8 q- d$ H: [

& m- J; q+ _7 Y: G+ _+ ]/ d9 `+ v1 E/ l. W. c* V
<pppoe-client>
  U8 E! F6 w" w$ h% M8 W
4 Y* R2 a1 X, l& F五、NAT的配置
$ [' ]+ y0 ]5 {/ A用PC2直接ping 10.1.12.254是可以通的。10.1.12.254是AR1的g0/0/0口获取到的地址,其实就是我们常说的WAN口地址。8 _0 e; l, A1 [# x7 A) q# }" T
2 E0 y# D$ Q" t) R  n
PC2>ping 10.1.12.2545 E7 e, U4 j; [

/ H% g5 c) t- \4 JPing 10.1.12.254: 32 data bytes, Press Ctrl_C to break
( r; q  f; O5 s$ lFrom 10.1.12.254: bytes=32 seq=1 ttl=255 time=63 ms# \9 A. v5 A- t3 C$ ~
From 10.1.12.254: bytes=32 seq=2 ttl=255 time=31 ms+ ?) G( E  I8 h$ d
From 10.1.12.254: bytes=32 seq=3 ttl=255 time=47 ms
0 s" F' r$ t9 h" \/ o1 OFrom 10.1.12.254: bytes=32 seq=4 ttl=255 time=31 ms
* Y8 a9 f. L' nFrom 10.1.12.254: bytes=32 seq=5 ttl=255 time=47 ms( H0 ]0 R' T& {
+ `% @! H# i- h9 D8 n
--- 10.1.12.254 ping statistics ---1 c9 o/ c) O% ?: F
  5 packet(s) transmitted: Y+ l. F& |) a
  5 packet(s) received1 L; V7 r7 J  E% C$ `
  0.00% packet loss
/ L/ U( O6 q( N% H  J) E  round-trip min/avg/max = 31/43/63 ms
# c8 D4 N8 @% b4 o/ U( V
) ]6 O  _7 t% sPC2>ping 10.1.12.2
( Y5 ]9 C! f. a! V( j* j( T! p" _0 Q0 t3 t$ q0 j) N
Ping 10.1.12.2: 32 data bytes, Press Ctrl_C to break% Y7 h* B& Y% h/ ]* c- W" s: S
Request timeout!7 N# F; X9 I! A/ o% B  J9 e5 D
Request timeout!
5 c# b% c* a. ?! f( QRequest timeout!* C) w" W3 f! Y
Request timeout!
/ ]6 Y8 N" ~4 D3 N/ O$ y& rRequest timeout!1 Q/ H1 f5 M7 L# i+ R
7 R8 f7 K4 m# \2 {
--- 10.1.12.2 ping statistics ---
0 {0 C  d0 B9 G+ m! F4 w  5 packet(s) transmitted! w$ J; M# i! J/ m
  0 packet(s) received7 d1 j" G2 [9 a
  100.00% packet loss
1 O2 l# a3 ?6 b. O! b2 u- m#但是无法ping通10.1.12.2
: b  e. ~4 o6 V, x5 d5 N, K0 D$ @% [

+ E* q' l: j# u- R; ?: {( K0 N- U无法ping通10.1.12.2的原因是:我们没有做NAT .接下来我们在pppoe-client上面做NAT- t4 |6 s8 N1 n6 [

% N- @7 \9 V2 F2 k" i$ U+ L- D- B; [1、这里配置规则2000
$ d  d, d5 E; }* K& w! i5 L[pppoe-client]acl number 2000        ; P! Y  s* h# \8 U. Y/ D
[pppoe-client-acl-basic-2000]rule permit source 192.168.1.0 0.0.0.2554 g$ {; R- Q& g

% H" w1 w; `! U- o2、将规则2000绑定到接口
% _/ X$ y8 s4 P* T$ F$ l; M- T如下接口信息,需要注意的是pppoe的接口是Dialer1,并不是GigabitEthernet0/0/0口。我们必须将规则绑定在Dialer1口,最容易犯错的就是直接绑定在g0/0/0口。. s' x# ^7 s, L+ ?
" {4 R0 @% e8 g
[pppoe-client]dis ip int b& ]: a7 Y' U) W* q
*down: administratively down
# {/ n7 V4 l/ N0 f+ k! n^down: standby
) I% P; u* w& J: M" d$ k(l): loopback& S+ D& F8 j. c5 C4 z
(s): spoofing7 r( E8 e8 f( t" y( P5 Z" ~: H
The number of interface that is UP in Physical is 4
- M9 K. h$ Y) l. Y( F( r- f1 ZThe number of interface that is DOWN in Physical is 0
# r. T( L" W% I! }The number of interface that is UP in Protocol is 3: P- Q0 }# u/ G0 T! `& d9 l' ?. P
The number of interface that is DOWN in Protocol is 1
9 W4 \! v  A; S3 r) G: z" [1 k& l5 f" S
Interface                         IP Address/Mask      Physical   Protocol  * z# W( {# I7 G$ j  j6 p0 U
Dialer1                           10.1.12.254/32       up         up(s)     + ]! m( Y- H9 Z5 l" S, Z
GigabitEthernet0/0/0              unassigned           up         down      7 e9 C( i- p3 L8 s. o
GigabitEthernet0/0/1              192.168.1.254/24     up         up        
* n( T* f' W% b# m$ {NULL0                             unassigned           up         up(s)     
. Y& F3 q" M* F, q; R: G) [, K) Z[pppoe-client]. z6 A0 O( D5 e% ^* I
% z$ E* k% Y$ l' }4 R9 C2 M1 ~
[pppoe-client]int Dialer 1       
$ R/ \* m5 a+ {8 ]1 g& \[pppoe-client-Dialer1]nat outbound 2000
  v6 H6 k( v; f& c) L[pppoe-client-Dialer1]dis th
2 H9 J  A9 o3 g! `[V200R003C00]
7 x+ ^+ f$ X" p' [#
+ x; S/ D5 }. _9 u) ?+ n- hinterface Dialer13 [! o" P9 y9 ^2 Q9 {/ J( B% u
link-protocol ppp
' U8 B, V$ ~7 i& w2 J) B( V6 U ppp chap user pokes
& [& j. }% V0 I( \" d. P" u ppp chap password cipher %$%$I/!'WCyd<7p[~8;,>51L,$sl%$%$
9 H  I8 x; M0 e6 E+ f ip address ppp-negotiate
0 N' ~3 s: s& n" L' V dialer user zhprny9 \8 X0 p3 Y! M4 N# ~8 f( Q# S
dialer bundle 1
1 |/ U9 ]# H% a* {. s8 K9 L dialer-group 1/ i3 T  l9 H, U7 x
nat outbound 2000
/ y, {; {- R5 c, ^/ I7 x#
0 b8 i8 p% X; A( c+ I% i0 @2 Y( Qreturn
! l& S: U2 U9 y# `+ `' M' f[pppoe-client-Dialer1]' x  X8 f( a2 [* h  L8 q/ s

" _7 j1 A* G1 e. q; M6 S9 Y  [接下来我们就可以ping通10.1.12.2 了。
' N8 Q  M! ?& R8 D: r1 ^9 ^& n1 O
PC2>ping 10.1.12.2
: @8 s0 ]9 Q* ?' d8 n1 d$ X9 n6 _4 q  q5 z
Ping 10.1.12.2: 32 data bytes, Press Ctrl_C to break# f! l( R9 n" F7 S
From 10.1.12.2: bytes=32 seq=1 ttl=254 time=31 ms
& q; r3 h: s: ?From 10.1.12.2: bytes=32 seq=2 ttl=254 time=32 ms
2 O  r! z2 x! W( \$ ~From 10.1.12.2: bytes=32 seq=3 ttl=254 time=46 ms
" C8 R& o+ f- T& ]From 10.1.12.2: bytes=32 seq=4 ttl=254 time=32 ms. y" ?" O  _0 o3 y' ~0 k4 l3 B
From 10.1.12.2: bytes=32 seq=5 ttl=254 time=31 ms
' v" ^- v0 f, }  x! \8 N# e! A( U
--- 10.1.12.2 ping statistics ---. d( N3 W( Q# i4 H  L  |8 L* ?' p
  5 packet(s) transmitted, A& ^1 n) L" {& ~% P
  5 packet(s) received& \0 x' Z( K, f# j/ _. {
  0.00% packet loss
; {# u1 V! |1 A+ w- d- s  round-trip min/avg/max = 31/34/46 ms
. h! y! ~0 L/ x6 n" r  Z
2 F3 a9 ^1 ~0 j
3 e4 q/ U; @. ^) \" N3 E: z8 @
您需要登录后才可以回帖 登录 | 注册

本版积分规则

返回首页|Archiver|手机版|小黑屋|易陆发现技术论坛 ( 蜀ICP备2026014127号-1 )

GMT+8, 2026-6-12 04:06 , Processed in 0.018870 second(s), 23 queries .

Powered by Discuz! X5.0

© 2001-2026 Discuz! Team.

快速回复 返回顶部 返回列表