Juniper SYSTEM BASICS - CONFIGURATION GUIDE V 11.1.X Configuration Manual page 537

System basics configuration guide software for e series broadband services routers
Table of Contents

Advertisement

Chapter 8: Writing CLI Macros
authTypeStr :=env.getline("authentication (1 = None, 2 = PAP, 3 = CHAP, 4 =
PAP/CHAP; 5 = CHAP/PAP)?");
authType := env.atoi(authTypeStr);
endwhile #>
<# endif #>
<# vpStartStr := env.getline("Starting VP number?");
vpStart:=env.atoi(vpStartStr)#>
<# vpEndStr := env.getline("Ending VP number?"); vpEnd
:=env.atoi(vpEndStr)#>
<# vcStartStr := env.getline("Starting VC number?");
vcStart:=env.atoi(vcStartStr)#>
<# vcEndStr := env.getline("Ending VC number?"); vcEnd
:=env.atoi(vcEndStr)#>
<# loopbackStr := env.getline("Loopback interface number or <cr>?") #>
<# vp := vpStart; while vp <= vpEnd, ++vp #>
<# vc := vcStart; while vc <= vcEnd, ++vc #>
interface atm <#slotPort $ '.' $ ++i;'\n'#>
atm pvc <# i; ' '; vp; ' '; vc; ' '; vcTypeStr;'\n'#>
<# if encapType = encapPpp #>
encap ppp
<# if authType = authPap#>
ppp authentication pap
<# elseif authType = authPapChap#>
ppp authentication pap chap
<# elseif authType = authChapPap#>
ppp authentication chap pap
<# elseif authType = authChap#>
ppp authentication chap
<# endif #>
<# elseif encapType = encapBridged #>
encap bridged1483
<# endif #>
<# if loopbackStr != "" #>
ip unnumbered loopback <# loopbackStr;"\n" #>
<# endif #>
!
<# endwhile #>
!
<# endwhile #>
<# if encapType = encapPPP #>
<# authNone:=1; authPap:=2; authChap:=3; authPapChap:=4; authChapPap:=5 #>
<# while (authType < authNone || authType > authChapPap );
authTypeStr :=env.getline(" authentication (1 = None, 2 = PAP, 3 = CHAP, 4 =
PAP/CHAP; 5 = CHAP/PAP)?" );
authType := env.atoi(authTypeStr);
endwhile #>
<# endif #>
<# vpStartStr := env.getline(" Starting VP number?" );
vpStart:=env.atoi(vpStartStr)#>
<# vpEndStr := env.getline(" Ending VP number?" ); vpEnd
:=env.atoi(vpEndStr)#>
<# vcStartStr := env.getline(" Starting VC number?" );
vcStart:=env.atoi(vcStartStr)#>
<# vcEndStr := env.getline(" Ending VC number?" ); vcEnd
:=env.atoi(vcEndStr)#>
<# loopbackStr := env.getline(" Loopback interface number or <cr>?" ) #>
<# vp := vpStart; while vp <= vpEnd, ++vp #>
<# vc := vcStart; while vc <= vcEnd, ++vc #>
interface atm <#slotPort $ '.' $ ++i;'\n'#>
atm pvc <# i; ' '; vp; ' '; vc; ' '; vcTypeStr;'\n'#>
<# if encapType = encapPpp #>
507
Practical Examples

Advertisement

Table of Contents
loading

This manual is also suitable for:

Junose 11.1

Table of Contents