!
isdn switch-type basic-5ess
!
hostname r1
!
username r2 password 0 cisco
! -- hostname of other router and shared secret
!
interface BRI0/0
ip address 20.1.1.1 255.255.255.0
no ip directed-broadcast
encapsulation ppp
dialer map ip 20.1.1.2 name r2 broadcast 5772222
dialer-group 1
isdn switch-type basic-5ess
ppp authentication chap callin
! -- authentication on incoming calls only
ppp chap hostname alias-r1
! -- alternate CHAP hostname
!
access-list 101 permit ip any any
dialer-list 1 protocol ip list 101
!
路由器 2
!
isdn switch-type basic-5ess
!
hostname r2
!
username alias-r1 password 0 cisco
! -- alternate CHAP hostname and shared secret
! -- The username must match the one in the ppp chap hostname command
! -- on the remote router
!
interface BRI0/0
ip address 20.1.1.2 255.255.255.0
no ip directed-broadcast
encapsulation ppp
dialer map ip 20.1.1.1 name
alias-r1 broadcast 5771111
! -- dialer map name matches alternate hostname "alias-r1"
dialer-group 1
isdn switch-type basic-5ess
ppp authentication chap
!
access-list 101 permit ip any any
dialer-list 1 protocol ip list 101
!