Dax Router Guide
Dax Router Guide
Dax Router Guide
&200210$18$/
)25
';035287(56
9HUVLRQQ
'DWH
H1RY
G
5HYLVLRQ 'DWHG 1RY
1
Dear Dax User,
Congratulations!! You are now a proud owner of this DAX DXMP ROUTER.
We are sure you will be delighted with the features and performance of your new
product. And, the Dax support, if you need it.
This DAX DXMP ROUTER has unique user-friendly features and benefits. And, is
designed to increase the reliability and efficiency of your network.
We at Dax have offered the highest level of pre/post sales support in India for 15
years and are committed to providing you with International quality, Indian market
savvy products. This DAX DXMP ROUTER is a reflection of that commitment.
It is with this confidence that we promise you a 3 Years Carry-in warranty of which
Instant Replacement Anywhere is provided during the first year of warranty.
Please contact me (or any Dax Office) if and when you need us, we will endeavor
to win your confidence too.
“Happy Daxing”
Sujit
Country Manager - Dax
)&&:DUQLQJ
This equipment has been tested and found to comply with the limits of a Class B
computing device, pursuant to Part 15 of the FCC rules. These limits are designed
to provide reasonable protection against harmful interference in a residential
installation. This equipment generates, uses and can radiate radio frequency energy
and, if not installed and used in accordance with the instructions, may cause
harmful interference to radio communications.
If you suspect this product is causing interference, turn your computer ON and OFF
while your radio or TV is showing interference. If the interference disappears when
you turn the computer OFF and reappears when you turn the computer ON, then
something in the computer is causing interference.
You can try to correct the interference by one or more of the following measures:
CE Marking Warning
This is a Class A product. In a domestic environment this product may cause radio
interference in which case the user may be required to take adequate measures.
MP Series Router Manual
Configuration Guide &
Technical Manual
CONTENTS
The last configuration mode provides users with the interface of the English version, which is mainly used for users to
monitor the working status of a network and to collect statistical information of the system.
This manual describes the configuration mode of the router through the interface console. The other two modes, which
configure the router through the interface LINE in 56/336modem and Telnet remote login, are similar to the former. The
detail of the last mode that configures the router through SNMP can refer to the router network managing system
specifications.
InfoExpress IOS of Maipu’s MP Router series provides a special subsystem dealing with commands for management and
execution of system commands, which is called shell. The main functions of shell are as follows:
When a user configures a router through the command shell, the system provides many kinds of run modes for the execution
of the command. Each command mode respectively supports the special InfoExpress IOS configuring command. Accordingly
this attains the aim of hierarchy protection of the system, and ensures against unauthorized access to the system.
The Shell subsystem presently provides the following modes for running the configuring commands, and each different mode
is corresponding with a different system prompt that is employed to tell users in which mode he/she is presently operating.
These modes are:
Table 1-1 describes methods of entering different command modes and how to switch between different modes.
Table 1-1 the InfoExpress system modes and the switch methods between modes
Configures the
The In global router(cfg-crypto-trans)# Execute the command exit encryption transform
encryption configuration to come back to the global set.
transform mode, a user configuration mode.
configura- enters the mode
tion mode through the
command crypto
ipsec transform-
set, and designates
the corresponding
parameters
simultaneously.
In global
configuration
mode, a user
enters the mode
The through the
Execute the command exit Configures the
encryption command crypto
router(cfg-crypto-map)# to come back to the global encryption mapping
mapping map, and
configuration mode. items.
configura- designates the
tion mode corresponding
keys and
parameters
simultaneously.
In global
configuration
mode, a user
enters the mode
The IKE through the
policy Configures the IKE
command crypto Execute the command exit policy.
router(config-isakmp)#
Configura- isakmp, and to come back to the global
tion mode designates the configuration mode.
corresponding
keys and
parameters
simultaneously.
In global
configuration
The public mode, a user
key chain Configures the RSA
enters the mode router(config-pubkey- Execute the command exit
configura- public key to be
through the chain)# to return to the global used.
tion mode command crypto configuration mode.
key pubkey-
chain rsa.
In config-pubkey-
chain mode, a user
enters the mode
through the
Public key command named-
Execute the command exit
configura- key or Configures the
router(config-pubkey-key)# to return to the config-
addressed-key public key.
tion mode pubkey-chain mode.
and designates the
corresponding
keys and
parameters
simultaneously.
In the global
The DHCP configuration
Configura- mode, a user Execute the command exit
router(dhcp-config)# Configures DHCP.
enters the mode to return to the global
tion mode through the configuration mode.
command
router(config)#ip
dhcp pool, and
designates
thecorresponding
key words and
parameters
simultaneously.
Note
The word router is the default system name of a router when it leaves the factory. Users can rename the system name by
executing the command hostname in the global configuration mode, and the alteration can go into effect instantly.
Choosing a terminal:
The terminal can be a standard one with RS-232 serial port or a common PC and the later is used more frequently. If making
configuration from the remote end, you will need two more modems.
After affirming that at either the router or the terminal is shutdown, please connect the RS-232 serial port of the terminal with
the Console port of the router. The connection relationship is shown in figure 1-2:
Constructing local
configuration environment
MAIPUROUTER
PC for
configuration
Configuring
port
Serial of PC
Cable of
configuring prot
Figure 1-2 connection sketch map of local configuring the router
Figure 1-3 Creating a Connection
Creating a
connection:(Figure
Power up the terminal, configuring the communication parameters of the terminal: 9600bps Baud rate, 8 data1-3)
bits, no parity,
1 stop bit, and no flow control, choose VT100 as the type of terminal.
Choose a name for the
connection
If the PC is running Win95/98/2000/NT operating system, you can use the Hyper Terminal – Maipu
program, and set the serial port
parameters of HyperTerminal program according to above parameters.
(Or choose any other
The following example shows the HyperTerminal program running in Windows NT:name)
Parity ---no
Stop bit----1
Flow control---None
Power on the router, and press Enter the key on the terminal, then a prompt “router>”will be displayed on the
terminal and the router can be configured. (Where the word “router” is the actual name of the router.)
1.3.2 Making configuration through the LINE port of the 56/336modem module
If the 56/336modem module has been configured in the router, the DIP dial-up switch of the module can be used to configure
the working mode of the port LINE .The usage of the switch DIP can be shown in the table 1-2:
If the IP address of each interface on the router has been configured correctly, then Telnet can be used to log in the router
through LAN or WAN and the router can be configured.
6HU YHU
- Connect the network interface of computer with the Ethernet port of the router on the LAN.
- Run the Telnet client application program on a computer in the LAN.
- Configure the default mode (preference) of the Telnet terminal.
The contents of the configuration should be set as: terminal ->default mode -> simulation option select VT100/ANSI.
Note:
During the configuration of the Telnet client program, the option “local response (each display)” must be canceled.
Otherwise it will repeatedly display the contents inputted by the user which will adversely effect the normal employment of
the command edit function of the shell subsystem.
Type in the IP address of the router, and establishing Telnet connection to the router.
Set the Host Name as having the IP address of the router: 128.255.255.1
(The other operations are the same as the configuration through the console interface.)
Connect the configured computer to the remote router through LAN router
Run the Telnet client program application program on the locally configured computer
The following steps are the same as that of configuration through LAN
:$1
/$1
6\QFKU RQRXV
DV\QFKU RQRXV SRU W 6\QFKU RQRXV
/RFDO DV\QFKU RQRXV SRU W
U RXW HU
5RXW HU ZDL W L QJ I RU
FRQI L JXU DW L RQ
Run the Telnet client program on the local router, and configure a remote-end router by logging on to its network. The
method is the same as the one of configuring a router through Telnet on network. The connection figuration is as follows:
&RQI L JXU L QJ U HPRW H HQG U RXW HU W KU RXJK O RFDO U RXW HU
3& 3& 3&
:$1
6\QFKU RQRXV
3& I RU $V\QFKU RQRXV /$1
FRQI L JXU DW L RQ
3& VHU L DO
&RQI L JXU L QJ /RFDO 6\QFKU RQRXV
U RXW HU
SRU W $V\QFKU RQRXV
5RXW HU ZDL W L QJ
&DEO H RI I RU FRQI L JXU DW L RQ
FRQI L JXU L QJ SRU W
/$1 6HU YHU
Note:
When configuring the router through Telnet, do not alter the IP address of the WAN interface hastily. Only when make
sure that the other parameters are configured correctly can you alter the IP address. After the address is altered, Telnet would
disconnect and reestablish the connection. So the connection must be established again after the new IP address is inputted to
the host.
If users log into a Maipu router from a Linux system, the configuration should be made as follows:
First, input the user’s name and password into the Linux system;
Run Telnet client program in shell environment of Linux system to log in the router, using the following command:
telnet 128.255.255.1
After the command is executed, the output is as follows:
Connected to 128.255.255.1 ...done
Display the system prompt of the router:
router>
Press the keys “^” and “]” simultaneously to return to the prompt of telnet program:
telnet>
Execute the command to cancel the local binary mode:
telnet> unset binary
Already in network ASCII mode with remote host.
router>
After the above operations are completed, the command editing environment in shell system can work normally.
IF users log in the router through another type of Telnet client program, and the command edit environment works
abnormally, please configure the Telnet client program according to the above mentioned specifications.
The Command Line interface is an interactive interface provided by the shell subsystem for users to configure and use a
router. Users can perform the corresponding configuration tasks through the command line interface. At the same time, users
can also examine the system information and see the running status of the system through the interface.
The Command Line interface provides users with the following functions:
- System help information management;
- Inputting and editing of system commands;
- Interface history commands management;
- Terminal displaying system management.
By means of the above help methods, users can get various kinds of help information, illustrated respectively as follows:
1) In any command mode, type help to obtain simple descriptions about the help system:
router>help
Help may be requested at any point in a command by typing a question mark: '?'. If nothing matches, the help list will be
empty and you must backup until entering a '?' shows the
available options.
2) In any command mode, type in a question mark “?” to view all possible commands and their simple descriptions in this
mode. The following command lists all commands that can be executed in the privileged user mode:
router#?
Command Description
bootparams Print/Modify system boot parameters
bridge Transparent bridge two scc interfaces
Clear reset function
Clock Config the system clock information
Configure Turn on configuration commands mode
console-speed Set console speed
Copy Copy a file to another
Debug Debugging functions, see also undebug
Disable Turn off privileged commands
display Show something for debug purpose
exit Exit from current EXEC mode
filesystem Turn on file system management commands
mode
help Description of the interactive help system
language Set help information language
logout Exit from EXEC shell
memdump Dump memory image
more Format showing output
mrt Mrouted
netstat Show active connections for Internet protocol
socket
no Negate a command or set its defaults
pad Open a X.29 PAD connection
phonerxgain Voip card receive gain adjust
phonetxgain Voip card transmit gain adjust
ping Send echo messages
quickping Send echo messages
reload Halt and perform a cold restart
reset Set something of runing system
rlogin Open a rlogin connection
sendtrap Send a trap to a specified host or all the host in
the trap host list
set Set something of runing system
show Show running system information
spy Control collecting task activity data
4) Type in a command followed by one question mark “?” separated by a blank, if there is a parameter in this place, the
related descriptions of the relevant parameters will be listed:
router(config)#interface ?
group Interface group
fastethernet Fast Ethernet network interface
loopback loopback interface
dialer Dialer interface
tunnel Tunnel interface
multilink Multilink interface
virtual-template Virtual Template interface
serial serial network interface
5) Type in a character string closely followed by one question mark “?” and all keywords which begin with the same
character string and their descriptions will be listed.
router#d?
display Show something for debug purpose
disable Turn off privileged commands
debug Debugging functions,see also undebug
6) Type in a command followed by a character string closely with one question mark “?” and all keywords which begin with
the character string and their descriptions will be listed.
router#show h?
Command Description
Hosts Print current host tables information
When users type in any and all commands, the syntax of the commands will be examined. If the syntax is correct, then the
commands will be executed correctly, otherwise error messages will be reported to users. Common error messages are shown
in table 1-3:
Table 1-3 Error prompt messages of Command Line
Note:
When the cursor key is used to access the history commands and telnet runs in Windows98/NT system to log in the
router, the option “terminal->premier option->simulation option” should be configured as type VT-100/ANSI.
Typing in any other keystroke, the system displays the system prompt directly.
Table 2-1 shows all commands by which the configuration tasks described above will be completed:
When the router leaves the factory, its default system name is router. Users can change the system name at any time
according to their needs. This change takes effect immediately; the new system name will appear in the next system prompt.
The following example will change the system name from “router” to “router_1”:
Command Task
There is an independent clock system is installed in each Maipu router to record the current system time which includes
information includes year, month, date, hour, minute, second and week. When the system starts, the system time rests at
00:00:00 January 1,1970. Through the execution of the command clock, the calendar system of the router can be set to the
current time as shown in the following example:
router#clock 2001 11 15 9 36 10 The function of the executed command in the privileged user mode is
to set the time of the system calendar as 09:36:10, November 15 , 2001.
router#show clock Displays the current time of the
system.
UTC:THU NOV 15 09:36:15 2001 The current time is 09:36, November 15, 2001,default
timezone is UTC.
Note: The command show clock can be executed either in the common user mode
or in the privileged user mode, and the function is just the same in both the modes.
Note: Because there is no real time system (i.e.the system clock is still running after it is powered off), the system clock
will return to 00:00:00 January 1,1970 each time the router is turned on.
After the commands are executed, the users “Maipu” and “Maipuxf” will be permitted to access the router.
Configuring the superuser
router#configure terminal Enter the global configuration mode
router(config)#user root password 0 root Add a user “root” to the system with its corresponding password
“root”
The system prescribes that the name of the super user is root
examining the information of system users
router#show user
After the above command is executed in the privileged user mode, you can examine the registered users
Deleting the system user:
router#configure terminal
router(config)#no user Maipu Delete the system user “Maipu”
After the command is executed, the router will deny the access of the user “Maipu” to the router.
Note: The passwords and the relevant cipher showed in the Maipu router can be configured in the global
configuration mode. The parameters no service password-encrypt and service password-encrypt decide whether the
encryption is needed. For example, if there is the configuration of service password-encrypt, then the user name and
the corresponding passwords are shown as follows:
user Maipuxf password 7 \XPXXXOYTYO
Any option related to the password should carefully considered during configuration. Option 7 is defined for special
use. Please do not use this option in your configuration!
Command Description
router(config)#enable password password Configure the password of the super user.
router(config)#enable timeout <0_0x7FFFFFFF> Configure the time out value
Note:
The default value of time out is 300 seconds, or 5 minutes. If the value is set as 0, then there will never be a time out.
The Maipu router has three kinds of storage media, and its functions are as follows:
o FLASH: Stores router application programs, configuration files, BootROM programs etc.
There are four types of the files managed by the Maipu router:
o Router application program files ----used for route forwarding, files management, system management, etc.
o Configuration files ----Store the system parameters configured by users
o BootROM files ---- Store system initialized data
o Other files ---- for example, the dial tone memory file of second dial-up
o
2.2. 2 Management of the Router File System
Each Maipu router constructs a file system based on DOS in the system flash to store the information that rarely needs to be
changed, such as a router application program (protocol software, device program, drivers, etc.) and BootROM program etc.
The file system is called TFFS (True Flash File System). In the file system configuration mode, the system provides a set of
commands to manage the file system, which are showed in the table 2-2:
Table 2-2 the command list of the file system management
The file system management of the router is composed of two parts: they are file management and directory management.
Because TFFS is based on DOS file system, long file names are not supported. Each directory name can be a maximum of 8
characters in length. Each file name follows the 8.3-naming standard.
total number of sectors: 5687 There are 5687 sectors all together in the file system.
bytes per sector: 512 Each sector has 512 bytes;
media byte: 0xf8 Type of medium: 0xf8;
# of sectors per cluster: 4 Each cluster has 4 sectors;
# of reserved sectors: 1 One reserved sector;
# of FAT tables: 2 Two FAT tables;
# of sectors per FAT: 5 Each FAT table occupies 5 sectors.
max # of root dir entries: 240 The root directory can contain at most
240 files or directories;
# of hidden sectors: 1 One hidden sector;
removable medium: false (This device can’t be removable;
disk change w/out warning: not enabled The file system doesn’t warn about modification;
auto-sync mode: not enabled Auto synchronization of the auto file
system isn’t supported;
long file names: not enabled Long file name isn’t supported;
exportable file system: not enabled The file system can’t be replaced;
lowercase-only filenames: not enabled File name does not differentiate the uppercase or the lowercase.
volume mode: O_RDWR (read/write) The file system is read and written;
available space: 2893824 bytes The current useable space of the
system is 2893824 bytes;
max avail. config space: 2893824 bytes The maximum useable space of the system is 2893824 bytes.
Or execute the command show file in the privileged user mode:
The meaning is the same as volume.
The file management commands in the file system configuration mode, allow users to operate all files in TFFS including:
o List files (directories);
o Copying a file;
o Deleting a file;
o Displaying a file.
Aftering executing the command filesystem to enter the file system configuration mode, execute the command dir in
this mode and all files and subdirectories will be listed out in the current directory.
( 3 ) Deleting files
router(config-fs)#delete startup Deletes the file startup.
The Data of this file will be lost! if OS is deleted, the system will hangup!
Please confirm to continue(Yes/No)y After Y(Yes) is confirmed, the file will be deleted, otherwise
N(No) represents that the operation will be canceled.
router(config-fs)#dir
interface fastethernet0
exit
interface serial0
physical-layer sync
encapsulation PPP
exit
2.2.3 Directory management
router(config-fs)#
The above information indicates that the system is presently located in the directory /flash.
router(config-fs)#
The above information indicates that the system is currently located in the directory /flash/Maipuxf.
router(config-fs)#rmdir MProuter1
router(config-fs)#dir
size date time name
---- ----------- ----------- ----------
512 JAN-01-1980 00:00:00 . <DIR>
512 JAN-01-1980 00:00:00 .. <DIR>
2.2.5 Management of Router Configuration Files
The configuration file exists in the file system in the form of text. Its format is as follows:
In order to save the memory space of the device flash, only those commands in the configuration modes (including
the global configuration mode, the interface configuration mode, the access list configuration mode and the routing
protocol configuration mode etc.) are saved.
The organization of commands regards the command mode as standard, and all commands in the same mode are
organized together to form a paragraph.
Paragraphs are arranged in a certain order: the global configuration mode, the interface configuration mode and the
routing configuration mode etc..
Sort the commands according to the relation among them, all related commands are grouped together and a blank
line is used to separate groups.
The following is an example of the configuration file of Maipu router: (The details relating to the meaning of this information
will be introduced in following chapters)
router#sh run
Building Configuration...done
Current configuration:
version 4.2.7(YD)-2(integrity)
hostname router
enable password [WOWWWNXSX encrypt
enable timeout 0
no service password-encrypt
no service enhanced-secure
interface loopback0
exit
interface fastethernet0
ip address 192.168.0.83 255.255.255.0
exit
interface ethernet0
exit
interface serial3
Physical-layer sync
encapsulation ppp
ip address 1.1.1.2 255.255.255.0
exit
The configuration file of Maipu routers can be edited in a text editor (for example, wordpad) according to the format
prescribed in the above section, and then it can be downloaded to router through FTP or TFTP. This operation can be used
by terminal users or through Telnet.
The following example is given to explain how to download the router configuration file through FTP:
The aim of the above command is to download the configuration file config from the root directory of disk J of the computer
whose address is A.B.C.D to a router, and write it into the current directory of the router TFFS with the name startup.
Executing the command dir, you can see that a new file startup has been added into the current directory.
router(config-fs)#dir
size date time name
---- ----------------- ----------- ---------
512 JAN-01-1980 00:00:00 MPROUTER <DIR>
580 JAN-01-1980 00:00:00 STARTUP
630 JAN-02-1980 00:00:00 CONFIG
Downloading configuration files via TFTP is very similar to downloading via FTP, the only difference between them is that
the computer needs to run TFTP SERVER.
Step 4: Restart the router and execute the configuration file ---- startup, and modify the
system configurations successfully.
The following command can be executed to save the current running configuration into the remote host through TFTP:
r o u t e r # c o p y r u n n i n g - c o n f i g t f t p A . B . C . D WORD
The address of the remote host
The following command can be executed to save the startup configuration file into the remote host through TFTP:
r o u t e r # c o p y s t a r t u p - c o n f i g t f t p A . B . C . D WORD
The following command can be executed to save the configuration files of the remote host into the startup configuration file
(STARTUP) of the router through TFTP:
router#copy tftp A.B.C.D WORD startup-config
line vty 0 2
exec-timeout 5 0
absolute-timeout 2
timeout login respond 60
privilege level 14
autocommand show mem
autocommand-option delay 5 nohangup
password 0 vty
Command Description
Stack Displays the usage information of each task stack of
the system.
Memory Displays the system memory information.
Mbuf Displays the system buffer information.
Process Displays the system task/process information.
Device Displays the system physical and logical device
information.
Interface Displays the system network interface information
Host Displays the system interior host table information.
Arp Displays the system ARP table information.
Ip Displays the statistic information of IP layer
(including TCP and UDP).
Bootparams Displays the system startup parameters.
Startup-config Displays the contents of the system startup
configuration file.
About Displays the system copyright information.
Version Displays the system hardware/software version
information.
SUMMARY:
status bytes blocks avg block max block
------ --------- -------- ---------- ----------
current
free 35241056 16 2202566 26850984
alloc 21077416 20082 1049 -
cumulative
alloc 21571048 25563 842 -
code
code 10785360 - - -
STATISTICS:
Available bytes 35241056
Used bytes 21077416
Total bytes 56318472
Used bytes percent 37%
(5) Displaying the status information of about all of the system interfaces
router#show interface
loopback (unit number 0):
Flags: (0x8069) UP LOOPBACK MULTICAST ARP RUNNING
Type: SOFTWARE_LOOPBACK
Internet address: 127.0.0.1
Netmask 0xff000000 Subnetmask 0xff000000
Metric: 0, MTU: 32768, BW: 8000000Kbps
0 packets received; 0 packets sent
0 multicast packets received
0 multicast packets sent
0 input errors; 0 output errors
0 collisions; 0 dropped
fastethernet (unit number 0):
Flags: (0x8063) UP BROADCAST MULTICAST ARP RUNNING
Type: ETHERNET_CSMACD
Internet address: 192.168.0.83
Subnetmask 0xffffff00
Broadcast address: 192.168.0.255
Ethernet address is 00:01:7a:00:39:be
Rate: 100Mbit/s Duplex: full duplex
Babbling recvive 0, babbling transmit 0, heartbeat fail 0
Tx late collision 0, Tx retransmit limit 0, Tx underrun 0
Tx carrier sense 0, Rx length violation 0
Rx not aligned 0, Rx CRC error 0, Rx overrun 894
Rx trunc frame 0, Rx too small 0, Rx alloc mbuf fail 212682
Metric: 0, MTU: 1500, BW: 100000Kbps
235216 packets received; 230496 packets sent
229133 multicast packets received
223888 multicast packets sent
0 input errors; 0 output errors
0 collisions; 0 dropped
ethernet (unit number 0):
Flags: (0x8062) DOWN BROADCAST MULTICAST ARP RUNNING
Type: ETHERNET_CSMACD
Ethernet address is 00:01:7a:08:39:be
Metric: 0, MTU: 1500, BW: 10000Kbps
0 packets received; 0 packets sent
0 multicast packets received
0 multicast packets sent
0 input errors; 0 output errors
0 collisions; 0 dropped
serial (unit number 3):
Flags: (0x8070) DOWN POINT-TO-POINT MULTICAST ARP RUNNING
Type: PPP
Internet address: 1.1.1.2
Subnetmask 0xffffff00
Destination Internet address: 0.0.0.0
Metric: 0, MTU: 1500, BW: 128Kbps
2034 packets received; 1848 packets sent
0 multicast packets received
0 multicast packets sent
0 input errors; 0 output errors
0 collisions; 0 dropped
This will be explained in detail in chapter 17 “Network Debugging and Fault Diagnosis”.
1)SysLog can record every level system information and save those in flash file. In general, sysLog only record information
which level is emergencies(level 0), alerts( level 1), critical(level 2), errors(level 3) or warnings(level 4), of course, you can
change this by sysLog configuration command.
The corresponding command is:
router(config)#logging trap level <CR>
<0_7> Logging severity level
alerts Immediate action needed (severity=1)
critical Critical conditions (severity=2)
debugging Debugging messages (severity=7)
emergencies System is unusable (severity=0)
errors Error conditions (severity=3)
informational Informational messages (severity=6)
notifications Normal but significant conditions (severity=5)
warnings Warning conditions[default] (severity=4)
Table 2-5 sysLog severity level
severity level key-word description
0 emergencies System is unusable
1 alerts Immediate action needed
2 critical Critical conditions
3 errors Error conditions
4 warnings Warning conditions
5 notifications Normal but significant conditions
6 informational Informational messages
7 debugging Debugging messages
After configure some severity level for sysLog, all levels more severer than this level will be recorded in flash logging file.
For example, if you configure “ logging trap notifications”, then those logging information from level 0 to level 5 could be
record.
& Note:
After a level is defined, the level or lower level of information will be recorded into the logging file. For example, if level 5 is
defined, then level 0~5 of information will be recorded.
2) Examine the logging:
router#show logging
3) clear the logging
router#clear logging
4)ÔOptionalÕEnable the message timestamp in the global configuration mode. router(config)#service
timestamps log datetime
& Notice:
The command above is used to add the timestamp to any logging information according to the date and time set by the
router.
(2)There are two set of commands which are provided to trun on/off the switch of spying cpu. One is spy cpu/no spy cpu in
the privileged user mode; the other is check cpu enable/check cpu disable in the global configuration mode which can be
saved in configuration file.
The following table is the comment of check cpu command in the global configuration mode:
router(config)#check cpu enable turn on the switch of spying cpu , system begins to collect
the data of cpu utilization for every running task
router(config)#check cpu disable turn off the switch of spying cpu, system stop collecting
the data
of cpu utilization for every running task
router(config)#check cpu time- set time-interval value of updating cpu current
interval <1_3600> utilization, default is 2 seconds
router(config)#check cpu view set stype of showing cpu, parameter simple indicates that
[simple|_CR_] only display running task’s cpu utilization.
router(config)#check cpu check some parameters and status, such as switch status
parameter of spying cpu.
(3)In the privileged user mode, command show cpu display current cpu utilization rate for every task, the following is a
example of show cpu:
router#show cpu
NAME TID PRI total% ( ticks) delta% ( ticks) current%
-------- ----- --- --------------- --------------- ------
tCheckCpu 37640824 30 0%( 80) 0%( 2) 0%
tShell1 37840344 20 35%( 5868) 0%( 0) 0%
tFwdTask 41410224 45 15%( 2478) 0%( 0) 0%
tNetTask 41420760 50 5%( 918) 0%( 0) 0%
KERNEL 0 0 4%( 780) 0%( 0) 0%
INTERRUPT 0 0 0%( 12) 0%( 0) 0%
IDLE 0 0 38%( 6260) 99%( 398) 99%
& ö
noteö
Because task tCheckCpu will go on to collect cpu utilization data at interval of some time(default is 2 seconds),
some cpu resource will be used. Suggest not trun on the switch of spying cpu if checking cpu utilization is not needed.
1) Provide the tools to examine the utilization of CPU. After enabling the switch monitoring CPU, the CPU utilization of
each task in a period can be examined.
2) Provide 2 groups of commands to enable/disable the switch monitoring the CPU utilization: spy cpu/no spy cpu in the
privileged user mode and check cpu enable/chech cpu disable in the global configuration mode. The command check cpu
enable can be saved in the configuration file.
The related commands in the global configuration mode are described as follows:
Command Description
router(config)#check cpu enable Enable the switch monitoring the CPU and start to collect the
data of the CPU utilization.
router(config)#check cpu disable Disable the switch monitoring the CPU and stop collecting the
data of the CPU utilization. The default status is disable.
router(config)#check cpu time- Set the interval of refreshing the CPU utilization. The defaut
interval <1_3600> interval is 2 seconds.
router(config)#check cpu view Whether to display in the simple mode. Namely that only the
[simple|_CR_] CPU task is disaplayed. The simple mode is disabled by default.
router(config)#check cpu parameter Examine some current parameters and status of check cpu, for
example, whether to enable the monitoring switch.
In the privileged user mode, use the command show cpu to display the CPU utilization.
For example:
router#show cpu
NAME TID PRI total% ( ticks) delta% ( ticks) current%
-------- ----- --- --------------- --------------- ------
tCheckCpu 37640824 30 0%( 80) 0%( 2) 0%
tShell1 37840344 20 35%( 5868) 0%( 0) 0%
tFwdTask 41410224 45 15%( 2478) 0%( 0) 0%
tNetTask 41420760 50 5%( 918) 0%( 0) 0%
KERNEL 0 0 4%( 780) 0%( 0) 0%
INTERRUPT 0 0 0%( 12) 0%( 0) 0%
IDLE 0 0 38%( 6260) 99%( 398) 99%
& Note:
When the switch monitoring the CPU is enabled, the task tCheckCpu can not stop collecting the CPU data, which will
occupy some CPU source. So, if it is unnecessary to diagnose the CUP utilization of each task, you had better not enable the
switch.
Maipu's MP Series routers supports Internet network protocols. The Internet Protocol is the protocol based on packets and is
used to exchange data through a computer network. IP is the foundation of all other protocols in the Internet protocol stack.
IP deals with addressing, fragmenting, reassembling and disassembling of the protocol information; datagrams. As the
network layer protocol, IP processes address routing and controls the transmission of data packets. As network layer
protocols, Transmission Control Protocol (TCP) and User Datagram Protocol (UDP) are established on the IP layer. TCP is a
connection-based protocol, which provides the reliable data transmission service while UDP is connectionless protocol,
which provides unreliable data transmission service. MP series routers support all the demands prescribed in the RFC of
Internet Protocol (IP), which includes the services such as IP, ICMP, IGMP, TCP, and UDP etc.
• IP address configuration
• IP protocol configuration
• ICMP protocol configuration
• IGMP protocol configuration
• TCP protocol configuration
• UDP protocol configuration
3.1 IP Address Configuration
Usually, IP addresses of different classes are intended for use in different network systems. For large-scale network systems,
Class A addresses are used, while Class B and Class C IP addresses would most likely be used for medium and small scale
network systems. Class D and E addresses are reserved for special use.
With the development of the Internet, the IP addresses become limited and class address distribution can lead to the wasting
of IP addresses. To solve this problem the concept of "subnet" has emerged. A "subnet" uses several bits of a host bits of a
net address as the subnet, so the same network address can span mutliple physical networks.
An interface often has a primary IP address. The following tasks should be done in the interface configuration mode to
allocate a primary IP address and network mask to a network interface.
Command Task
Ip adderss <ip-address> <mask> Set master IP address for the interface
A subnet mask is used to identify the network number of an IP address. When a mask is used to determine a subnet in a
network, the mask is regarded as a subnet mask.
Note: Maipu MP series routers only support network masks which are composed of several continuous “1” bits with left
alignment.
In addition, Maipu MP series routers supports the assigning of many IP addresses to a broadcasting/multicasting network
interface. So you can assign some unlimited secondary addresses, which can be used in various occasions. The most
popular applications are shown in the following descriptions:
• There may not be enough host addresses for a given network section. For instance, your subnet allows up to 254
host addresses for a logical subnet, however, your physical subnet has 300 actual host addresses. Two logical
subnets on the physical subnet can exist after introducing secondary IP addresses to a router or an access server.
• In the past, many networks used Layer-2 bridges, instead of subnets. The use of the secondary addresses can help
covert the network into a subnet, which is a network based on routers. A bridge router in an old network can easily
establish several subnets in this network segment.
• Two subnets in a single network can be separated by another network under other conditions. You can establish a
network from subnets, so that these subnets can be separated physically by another network by use of secondary
addresses. Note that a subnet can not appear at several active interfaces at the same time.
Note: If any router in the network segment uses a secondary address, all the other routers in the same segment must use the
secondary addresses in the same network or subnet.
Command Description
The following example shows how to assign a primary IP address and two secondary IP addresses to the interface
Fastethernet0:
router#configure terminal
router(config)#interface Fastethernet0
router(config-if)#exit
router(config)#
& Note:
Those secondary IP addresses configured for the same interface have priority according to their configuration time. At
the same time, these IP addresses are not required in the same net section thereby allowing routers to forward datagrams
quickly.
The IP unnumbered process is a method to saving IP addresses on the Internet network. You can enable IP unnumbered on a
serial-interface, instead of assigning a visible IP address to the interface. Whenever an unnumbered interface produces a
packet (for example, when updating a routing list), it will use the interface address designated by you as the source address of
IP packet. It will also that designated interface address to determine which route process is sending the updated content to
this unnumbered interface. There are some limitations. They are:
• A serial-port presently only supports Point-to-Point Protocol (PPP). The High-Level Data Link Control (HDLC),
Link Access Process Balance (LAPB), Serial Line Internet Protocol (SLIP) and Channel interface will be supported
in the future.
• The command ping EXEC cannot be used to test and connect the interface since it has no IP address. But the Simple
Network Management Protocol (SNMP) can be used to remotely monitor the status of the interface.
For details, please refer to RFC 1195; It is not necessary to assign an IP address to
each port.
& Note:
Be sure to use an unnumbered serial line among different main networks. At each end, if there are different main
networks are assigned to your unnumbered any routing protocol running through serial lines will be configured not to
announce subnet information.
To enable an IP process on an unnumbered serial port, the following task should be finished in the interface configuration
mode:
Table 3-3
Command Description
The specified interface, not another unnumbered one, must be another interface in the router with at least one IP address. The
designated interface must also be valid.
With regard to the point-to-point protocols on the data link layer supporting IP address negotiation, you can enable IP address
negotiation on an interface with no IP address. Typically, PPP running over serial lines is used to access Internet via an ISP.
IP address negotiation of the serial port is enabled by the commands (listed in the table 3-4), which allows the local interfaces
to receive the IP address assigned by the interface of the opposite terminals.
Table 3-4
Command Description
Use the command show interface to display IP address configurations after you have completed the interface IP address
configurations.
3. 2 Address Resolution
Maipu MP series routers permit you to designate IP addresses through address resolution and naming service.
A device may have a data link (MAC) address (which uniquely identifies an interface on a LAN), and it can also has a
network address (which identifies the network and the host number in which the device is located). In order to communicate
with a device on an Ethernet network, for example, a Maipu MP series router must first decide the 48 bits MAC address of
that device. The process used to determine the MAC address from an IP address is called address resolution. The process
used to determine an IP address from a MAC address is called reverse address resolution (RAR).
Maipu routers support the Address Resolution Protocol (ARP). ARP is used to associate an IP address with a MAC address.
Taking an IP address as input, ARP can determine its MAC address. Once a MAC address is determined, the IP
address/MAC address association is kept in the ARP cache for high-speed searches. Then IP datagrams are encapsulated into
frames to be sent out onto the network.
ARP provides a dynamic mapping from an IP address to a MAC address. Because most hosts support dynamic address
resolution, it is not usually necessary to add a static entry into the Address Resolution Protocol (ARP) cache. You can
define one globally ---- write a permanent entry into the ARP cache, if the entry is defined for necessity. MP router
software will translate the 32-bit IP address into a 48-bit MAC address by that entry.
In order to display the cache being used by the system, users can examine the contents of the ARP cache by typing the
command show arp EXEC. In order to remove all dynamic entries from the ARP cache, users can type the privileged EXEC
command clear arp.
IP provides a naming method to enable a device to be identified by its location in IP. This is a hierarchical naming method
provided for domains. To trace a domain name, IP defines the conception of name server, which is used to keep a cache (or
database) that holds the mapping information from a domain name to an IP addresses. To map a domain name into an IP
address, you must first identify a host name, and then specify a domain name server to enable the Domain Naming System,
which is a global naming method to uniquely identify a network device on an internetwork.
Maipu routers holds a table that saves host names and their corresponding IP addresses. The table is also called the host
name-to-address mapping table. High-level protocols, such as the remote logon, use host names to identify network devices
(hosts). IP addresses or routers and other network devices should be associated mutually by static or dynamic tools.
When the dynamic mapping cannot be used, addresses can be distributed to host names manually.
To specify a domain name or a host name to an address, users can execute the following commands in the global
configuration mode:
You can designate a default domain name for a router. The domain name will be used by the system to finish the domain
name request. You can designate either a single domain name or a series of domain names. Any IP host name without a
domain name will have a specified domain name before it is added to the host table.
Execute any following task in global configuration mode in order to designate a domain name:
Execute the following commands in the global configuration mode to specify one or hosts (up to 6) as domain name servers
to provide name information service for DNS:
When resolving a name by use of the name service, the system will first use the default local name Cache, and then it uses
DNS service to complete name resolution. Users can also designate that the system only use the DNS service (so you need
not map an IP address into a host name manually) or first use the DNS service, and then use the local name CACHE to
achieve name resolution.
ip name-order {dns-first|dns-only|local-first}
3.3.5.1 Debug commands
command Task
Display the debugging information in duration of get ip address
Debug name-server
from dns server
3.4 IP Protocol
Each Maipu router enables IP route forwarding by default. But it can be disabled under certain conditions, which can be
realized under the following operations:
In the global configuration mode, users can disable IP routing forwarding by typing the command no ip routing.
In the global configuration mode, users can enable IP routing forwarding by typing the command ip routing.
Each Maipu router enables the acceptance of IP redirection by default. But in under certain conditions, IP redirection can be
disabled. This can be accomplished by the following commands (in the global configuration mode):
The redirection packet of icmp can result in the update of the routing table. The default setting of a Maipu Router is not to
update route after the router receives the redirection icmp packet. But users can select the route update.
The IP fast transmission is realized through route cache mechanism. The purpose of the route cache is to reduce the repeated
searching of a routing table and to accelerate the packets sending speed through using previous cache searching results. But
under certain circumstances, users can choose to enable/disable the following two places to process route cache.
1) Fast transmitting route cache. Before sent to IP layer to deal, some packets received by interface can be transferred
directly if they match the route that stored in the cache.
2) When there are packets sent down from the user layer, if the destination is the same each time and the route is UP, the
route in the cache can be used without searching the routing table. Only one route, which is the result of recently searching
the routing table, is stored in cache.
The Table 3-5 lists the commands to configure the UDP properties:
Table 3-5 UDP properties configuration
Table 3-5
Command Description
ip option default-ttl [1-255] Configure the Time-To-Live of the IP protocol
ip option fragment-ttl [1-255] Configure the Time-To-Live of IP fragment
Displaying IP Statistics
router#show ip
statistics
In the Internet Protocol stack, the Internet Control Message Protocol (ICMP) provides services such as controls, error reports
and network tests, etc. for other protocols in the Internet stack. The Maipu router supports RFC792, RFC950 and RFC1122.
router#sh ip icmp
16 calls to icmp error ---The times for system to call ICMP to send error
messages
0 error not generated because --- The number of ICMP errors generated due to
old message was icmp timeout
0 message with bad code fields ---The number of packets with bad code field
The Internet Group Management Protocol (IGMP) assists IP to provide other applications with multicast service in the
Internet Protocol stack. Maipu routers support RFC1122.
0 reports for local groups received ----The number of reports for local groups received
3.7TCP protocol
The Transmission Control Protocol (TCP) provides a highly reliable datagrams transmission service between application
programs. Maipu Routers support RFC793, RFC813, RFC879, RFC896 and RFC1122.
ip tcp segment-size [256-4028](default: 512) Configures the size of the maximum TCP segment
ip tcp round-trip [1-100](defult: 3) Configure the maximum TCP round trip time
ip tcp idle-timeout[3-144000](default: 14400) Configure the idle time of the connection that is before the
first testing of keeping alive
ip tcp keep-count[3-20](default: 8) Configure the maximum keeping alive times when the
opposite terminal has no response
routerr#show ip tcp
0 data packet (0 byte) retransmitted ---The resent packets number (byte number)
0 ack for unsent data ---The number of the packets asked not to be sent
0 completely duplicate packet (0 byte) ---The completely duplicate packet number (byte)
0 packet with some dup. Data ---The partial duplicate packet number (byte)
(0 byte duped)
0 packet (0 byte) of data after window ---The number of the packets outside of the
window (byte)
0 packet received after close ---The number of the received packets after
closing connection.
0 discarded for bad checksum ---The number of the packets discarded because
of bad checksum
0 discarded for bad header offset field ---The number of the packets discarded because
of bad header offset field
0 discarded because packet too short ---The number of the packets discarded because
of too short
0 segment updated rtt (of 0 attempt) ----No packet used to update round trip time
The User Datagram Protocol (UDP) provides the basic service of data transmission between application programs. Maipu
MP series routers support RFC768.
0 bad data length field ---The number of the packets with bad UDP data
length field
0 broadcasts received with no ports ---The number of the broadcast packets received
with no ports
16 pcb cache lookups failed ---The number of PCB Cache lookups failed
16 pcb hash lookups failed ---The number of PCB Hash lookups failed
A socket is a mechanism that network application programs use to access lower layer network resources. Maipu MP series
routers supports the standard socket interface mechanism and a series of socket applications. The command Show Ip Sockets
can be used to display the usage situation of the TCP/UDP connection used by the current system, and can helpful to
troubleshoot.
router#show ip sockets
Proto -- indicates the protocol used by the current connection: TCP or UDP
Local Address -- indicated the local address and port number of the current connection
Foreign Address – remote address and port number of the current connection
This chapter mainly describes the interfaces supplied by Maipu series routers and how to configure them. And the main
contents of this chapter are listed as follows:
z Interface type supported by Maipu series routers
z Configuring Ethernet interfaces
z Configuring high-speed serial interfaces
z Configuring a 16-asyn-port/printing module
z Configuring a CE1 module
z Configuring an 8-syn-port module
z Configuring a built-in base-band modem module
z Configuring a built-in frequency-band modem module
z Configuring an ISDN module
4.1 Interface Types
This section mainly describes the interface types supported by Maipu series routers and how to configure them.
2) Ethernet_SNAP
The foregoing frame formats are used to encapsulate the network-layer IP protocol. When receiving data, the Ethernet port
can automatically recognize frame formats. But when transmitting data, the port can do nothing but make encapsulation
according to the specified frame format.
4.2.2 Configuring Network Address
Currently, MPROUTER can support noting but IP protocol on the network layer. And the network/host address and sub-net
mask need be configured by means of the following command:
Command Descriptions
router#configure terminal The user enters the global configuration
mode from the privileged user mode.
router(config)# interface fastethernet0 Enter the configuration status of the
interface f0.
router(config-if-fastethernet0)#ip address A.B.C.D Configure the IP address and sub-net mask
mask of the interface f0.
router(config-if-fastethernet0)#ip address A.B.C.D Configure the secondary address of the
mask secondary interface f0.
Note:
A.B.C.D is the IP address of the interface, and mask is the sub-net mask of the interface.
Notice:
Sixty-four secondary addresses can be configured at best on the Ethernet interface. And there is no limit of the
secondary addresses for the master interface.
Note:
A.B.C.D is a host name or IP address and H.H.H is a MAC address. H means a hexadecimal number between 0 and FFF.
4.2.4.2 Examining ARP Buffer
To display the contents of the ARP cache used by the system, you can use the command show arp to examine the cache.
router#show arp
LINK LEVEL ARP TABLE
destination gateway flags Refcnt Use Interface
-----------------------------------------------------------------------
129.255.117.5 0050.ba27.e285 405 2 32455 fastethernet0
129.255.150.1 0050.ba27.d0f5 405 2 1011270 fastethernet0
-----------------------------------------------------------------------
Noteö
ö
1ì Destination: the destination IP address÷
To refresh the ARP item, you can use the privileged EXEC command clear arp to do it.
router#clear arp
4.2.5 Proxy ARP
If an ARP request is transmitted from a host in a network to a host in another network, the router connecting the two
networks can answer the request. The foregoing procedure is called Proxy ARP. This way can make the end sending the ARP
request mistake that the router is the destination host. In fact, the destination host is on another side of the router. In this way,
the router, whose function is equivalent to the proxy of the destination host, can transmit packets to the destination host. Ô
RFC1027Õ
Maipu router supports the proxy ARP.
Execute the following command in the interface configuration mode:
Command Descriptions
router(config-if-fastethernet0)#ip proxy-arp Enable the proxy ARP.
router(config-if-fastethernet0)#no ip proxy-arp Disable the proxy ARP.
Note:
The proxy ARP is enabled by default.
The following example is about the typical ARP application and configuration:
035287(5 5287(5
3&e
| 3&e
|
Noteö
ö
If ARP proxy is disabled on the Ethernet of MPROUTER, PC1 fails to ping 136.1.2.55 successfully. This is because:
For packets in the same network, PC1 firstly broadcasts the ARP request so as to acquire the MAC address of the destination
host. After getting the address, PC1 transmits the packet to the destination. In the foregoing example, both the destination
host and PC1 on the same network (which can be known according to the mask of PC1), but they are not located in the same
network physically. If there is no response after PC1 sends the ARP request, then PC1 pings unsuccessfully. Here, if
MPROUTER enables ARP proxy, MPROUTER can use its MAC address to answer the request sent by PC1, and PC1 can
ping successfully. The ARP proxy of MPROUTER is mainly applied to this case.
4.2.6 Monitoring and Maintenance
When finishing the configuration of the Ethernet interface, you can enter the privileged user mode and execute the command
show interface to display the diverse configuration parameters and current operational status of the Ethernet interface.
RouterÏshow interface fastethernet0
fastethernet (unit number 0):
Flags: (0x8063) UP BROADCAST MULTICAST ARP RUNNING
ÔProtocol signal UPÕ
Type: ETHERNET_CSMACD
ÔInterface type: CSMA/CDÔIEEE802.3ÕÕ
Internet address: 129.255.117.22
ÔPort addressæ129.255.117.22Õ
Netmask 0xffff0000 Subnetmask 0xffff0000
ÔNetwork maskæ255.255.0.0 Sub-net maskæ255.255.0.0Õ
Broadcast address: 129.255.255.255
ÔBroadcast addressæ129.255.255.255 Õ
Metric: 0, MTU: 1500, BW: 100000Kbps, DLY: 100 usec
ÔMaximal transmitting unitæ1500çbandwidthæ100MçDelayæ100 microsecondsÕ
Ethernet address is 0001.7a00.0016
ÔMAC address:0001.7a00.0016Õ
Rate: 100Mbit/s Duplex: full duplex
ÔRateæ100Mç Operational modeæfull duplex modeÕ
Babbling recvive 0, babbling transmit 0, heartbeat fail 0
Tx late collision 0, Tx retransmit limit 0, Tx underrun 98
Tx carrier sense 0, Rx length violation 0
Rx not aligned 4, Rx CRC error 13, Rx overrun 68
ÔIn the received frames, there are 4 un-aligned ones, 13 CRC error’s ones and 68 overrun ones. Õ
Rx trunc frame 0, Rx too small 0, Rx alloc mbuf fail 0
5 minute input rate 19000 bits/sec ,12 packets/sec
ÔThe input rate is 19000 bits/sec, namely 12 packets/sec, in the late 5 minutes.Õ
5 minute output rate 6000 bits/sec ,2 packets/sec
ÔThe output rate is 6000 bits/sec , namely 2 packets/sec, in the late 5 minutes.Õ
63200024 packets received; 9128013 packets sent
Ô63200024 packets are receivedçand 9128013 packets are sentÕ
57157487 multicast packets received
Ô57157487 multicast packets are receivedÕ
1045 multicast packets sent
Ô1045 multicast packets are sent.Õ
37 input errors; 0 output errors
ÔThere are 37 input errors and 0 output error.Õ
0 collisions; 24166659 dropped
ÔThere is 0 collision; and 24166659 packets are discarded.Õ
4.3Configuring High-speed Serial Interface
Maipu router can provides two kinds of high-speed serial interfaces: one can support both synchronous and asynchronous
operation mode, called a synchronous/asynchronous serial interface; another can operate only in the asynchronous operation
mode, such as a configuration interface. The configuration interface Console is used to connect with user terminals and
serves as the configuration and monitoring interface of the router. Generally, you need not configure the configuration
interface, and it is not also recommended for you to do it.
The serial interface of Maipu router supports the following applications:
1) Connecting with the external Modem, and serving as a dialup interface or a backup interface;
3) Supporting link-layer protocols, such as PPP, SLIP, FR, X25 and HDLC;
4) The extended synchronous/asynchronous serial interface or asynchronous serial interface can support link-layer
protocols, such as PPP, SLIP, X25, HDLC and FRÔbut the asynchronous serial interface can not support FRÕ.
The main contents of this section are listed as follows:
Command Descriptions
physical-layer async Configure the asynchronous operation mode for the serial interface
0Äserial0Å.
speed 9600 Configure the bund rate 9600 for the asynchronous serial interface.
And the baud rate can be select from 1200bps/2400bps/4800bps/
9600bps/ 19200bps/38400bps/57600bps/115200bps.
databits 8 Configure the databits of the asynchronous serial interface: 8. And
the value can be selected from 5/6/7/8.
stopbits 1 Configure the stopbits of the asynchronous serial interface: 1. And
the value can be selected from 1/2.
parity none Configure the parity of the asynchronous serial interface: none.
And the value can be selected from even/none/odd/space/mark.
flow-control none Configure the flow-control of the asynchronous serial interface:
none.
And the value can be hardware flow-control (none) or software
flow-control.
maxinum-rx-unit 128 Configuring the maximal unit-receivable of the asynchronous
serial-interface; the scope of the maximal unit-receivable supported
by the serial interface is between 128 and 4096.
Tx-on dcdÉdsr Set the sending condition of the serial interface. And the default
condition is dcdÉdsr.
Noticeö
ö
When the asynchronous serial interface connects with the external Modem, the baud rate is applied to the
communication between the serial interface and the Modem. So their baud rate can be set differently. The line rate can be
determined after the Modem makes negotiation with the serial interface. And when two serial interfaces connect together
directly, they need be configured with the same baud rate.
When working in the hardware flow-control mode, the asynchronous serial interface can, by means of detecting the CTS
signal, determine whether to send data; and when working in the software flow-control mode, the asynchronous serial
interface can, by means of judging the flow-control character äXON/XOFFå, determine whether to send data.
4.3.2 Configuring a Synchronous Serial Interface
Without any configuration, a synchronous serial interface can work in the synchronous operation mode. The synchronous
serial interface can work in the DTE/DCE mode. When working in the DTE mode, the external DCE equipment (such as the
external synchronous Modem) connecting with the interface provides the clock source; and when working in the DCE mode,
the router connecting with the interface provides the clock source.
The synchronous serial-interface can provide a V.24/V.35 interface. By means of internal jumper, the router can provide
different types of interfaces.
For example, you can execute the following command to configure the serial interface 0 Ôserial0Õand make it work in the
synchronous operation mode:
RouterÔconfig-if-serial0ÕÏphysical-layer sync
4.3.2.1 Configuring the Operation Mode of a Synchronous Serial Interface
By default, a synchronous serial interface works in the DTE mode. And you can make the interface work in the DCE mode
through configuring DCE clock rate and adopting the DCE cable.
The different operation modes of the synchronous serial interface are corresponding with the different clock options:
1) If the synchronous serial interface works in the DTE mode, the serial interface receives the clock provided by the
external DCE equipment. Here, the DTE serial interface can not only select the receiving /sending clock of the
DCE equipment as itself receiving/sending clock, but also regard the sending clock of the DCE device as itself
receiving/sending clock. For example, you can use the following command to set the sending clock of the DCE
device as itself receiving/sending clock:
RouterÔconfig-if-serial0Õ)#clock multiplex Configuring the DTE clock multiplex.
When the interface works in the DTE mode, to eliminate the half clock cycle of the line some time, you can invert the
receiving clock of the DTE.
RouterÔconfig-if-serial0Õclock invert Configuring the DTE clock invert.
Noteö
ö
2) If the synchronous serial interface works in the DCE mode, the serial interface need provide the clock for the
external equipments. For example, you can use the following command to set the DCE clock rate:
RouterÔconfig-if-serial0Õ# clock rate 128000 Configuring the DCE clock rate as 128000.
Noteö
ö
In the synchronous operation mode, the serial interface can support a very wide clock rate scope. The lowest clock rate
is 1200bps, and the highest rate is related with the operation mode of the interface.
The highest clock rates supported by the interfaces in the different interface modes are different:
· In the V.24 mode, the highest clock rate can reach 200kbpsç
· In the V.35 mode, the highest clock rate in the DTE mode can reach 8Mbps and that in the DCE mode can reach
2Mbps.
Noteö
ö
The basic configuration of an 8 syn/asyn expansion interface is the same as that of the high-speed WAN interface. And
the different between them is that the rate supported by the former is relatively lower.
4.3.3 Monitoring and Maintenance
When finishing the configuration of the interface, you can enter the privileged user mode and execute the command show
interface to display the diverse configuration parameters and current operational status of the interface.
RouterÏshow interface serial0
serial (unit number 0):
Flags: (0x8071) UP POINT-TO-POINT MULTICAST ARP RUNNING
(Protocol signal : UP)
Type: PPP
(Interface typeæPPP)
Internet address: 10.1.1.1
(Port addressæ10.1.1.1)
Netmask 0xff000000 Subnetmask 0xffffff00
(Network maskæ255.0.0.0 Sub-net maskæ255.255.255.0)
Destination Internet address: 10.1.1.2
(The IP address of the opposite endæ10.1.1.2)
Metric: 0, MTU: 1500, BW: 128Kbps, DLY: 20000 usec
(Maximal transmitting unitæ1500çbandwidthæ128KçDelayæ20 microseconds)
5 minute input rate 790000 bits/sec ,14 packets/sec
ÔThe input rate is 790000 bits/sec, namely 14 packets/sec, in the late 5 minutesÕ
5 minute output rate 788000 bits/sec, 12 packets/sec
ÔThe output rate is 788000 bits/sec, namely 12 packets/sec, in the late 5 minutesÕ
1761641 packets received; 1827994 packets sent
(1761641 packets are received; and 1827994 packets are sent.)
0 multicast packets received
(0 multicast packet is received.)
0 multicast packets sent
(0 multicast packet is sent.)
148 input errors; 146 output errors
(There are 148 input errors 146 output errors)
0 collisions; 9 dropped
(There is 0 collision; and 9 packets are discarded)
lcp:OPENED, ipcp:OPENED, cdpcp:OPENED
rxFrames: 2296829, rxChars –1694564374
Ôthe number of the received frames is 2296829, and total bytes of the received frames are –1694564374.Õ
txFrames: 2275846, txChars –1714594630
ÔThe number of the sent frames is 2275846, and total bytes of the sent frames are –1714594630.Õ
rxNoOctet 17, rxAbtErrs 6, rxCrcErrs 0
ÔIn the received frames, there are 17 un-aligned ones. Six received frames are discarded and there exists no CRC
error’s frame. Õ
rxOverrun 0, rxLenErrs 0, txUnderrun 0
Ôthere exists 0 rxOverrun frame, 0 rxLenErr frame and 0 txUnderrun frame.Õ
rate=2000000 bps
(The line rate is 2M)
DCD=up DSR=up DTR=up RTS=up CTS=up Txc=up
4.4 Configuring a 16-asyn-serial-interface module
Maipu router contains a 16-asyn-serial-interface module. The module adopts the interface standard—RS-232, uses DB25
(M)/DB25 (F) connectors and RJ45 socket, supports 9600bps-115200bps baud scope, operates in the DTE or DCE mode.
Additionally, the module can support the following services:
z Connecting with a terminal (with the function of terminal-number fixing)
z Connecting with ATM (automated teller machine)
z Connecting with a PC station
z Connecting with a router
z Connecting with a frequency-band/base-band Modem
z Supporting PC/router dialup access
z Other serial equipment.
Noticeö
ö
For the low-end routers including MP1700, MP2500 and MP2600 etc, only the slot S0 can support the CE1 module.
Noteö
ö
1) Number: The channel-group number. When an E1 data line is configured, the scope of the channel-group number is
from 0 to 30.
2) Range: The value scope to which one or more time-slots in a channel-group belong. The first time-slot number is 1,
and its range is from 1 to 31.
Notice:
1) When a time-slot is configured, the time-slot-number of the start-time-slot must be more than that of the stop-time-
slot, or else, the time-slot-number is invalid.
2) If two channels are configured with the repeating time-slot, the configuration is invalid and no interface can be
generated.
3) When a time-slot is configured, the scope of the time-slot must match with a channel-group-number. And it is the
service provider that defines time-slots including a channel-group.
The following example defines three channel-groups: channel-group 0 includes a single time-slot, channel-group 2 includes
three time-slots and channel-group 7 includes a single time-slot.
Command Descriptions
router(config)#controller e1 0/0 Use the slot-number and unit-number to
determine the location (0/0) of the controller and
enter the E1 configuration mode.
router(config-controller)#channel-group 0 Configure time-slot 1 for channel-group 0.
timeslots 1
router(config-controller)#channel-group 2 Configure 3~5 time-slots for channel-group 2.
timeslots 3-5 (That is to say that the rate of the channel-group 2
is 192K)
router(config-controller)#channel-group 7 Configure time-slot 7 for channel-group 7.
timeslots 6
router(config-controller)#framing crc4 Enable CRC4
router(config-controller)#linecode hdb3 Configure the line code as HDB3.
After finishing the configuration above, you can perform the interface configuration. The interface form is s0:0 s0:2 s0:7.
Command Descriptions
router(config)#interface s0/0:0 Enter the channel-group 0.
router(config-if-serial0/0:0)# encapsulation ppp Encapsulate the link-layer protocol as PPP.
router(config-if-serial0/0:0)#ip add 1.1.1.1 Configure the IP address 1.1.1.1 and subnet mask
255.0.0.0 255.0.0.0.
router(config-if)#exit
router(config)#interface s0/0:2 Enter the channel-group 2.
router(config-if-serial0/0:2)# encapsulation hdlc Encapsulate the link-layer protocol as HDLC.
router(config-if-serial0/0:2)#ip add 2.2.2.1 Configure the IP address 2.2.2.1 and subnet mask
255.0.0.0 255.0.0.0.
router(config-if)#end
Noticeö
ö
When multiple time-slots are configured, “-” is used between the start-slot and the stop-slot.
4.5.2 Monitoring a CE1 Module
After finishing the interface configuration, the user can enter the privileged user mode and execute the command show
interface to display the parameter configuration and current operation status of the channel-group. Each parameter is the
same as that of the serial interface.
When the interface information is examined, the massive error frames can be discovered from the E1 statistics information,
the link-layer negotiation is slow, and there exists packet loss during the PING course.
The possible causes:
7KH&(PRGXOHFDQVXSSRUWWZRNLQGVRIFRQQHFWLRQFDEOHVRQHLV
QRQ-EDODQFHFRD[LDOFDEOHDQGWKHRWKHULV
balance twisted-pair cable. When equipment connection is performed, the impedance may be unmatched.
4.6 Configuring an E1 module
By default, an E1 interface follows G.703 and the total bandwidth 2.048Mbit/ is used for data transmission. When the E1
interface is used for the frame structure, the interface can be used for G.704 no-channel associated signaling and G.704
channel associated signaling structure: the sixteenth time-slot of the former structure can be used to transmit data, and the
sixteen time-slot of the latter structure can be used to transmit signalings except data; and time-slot 0 of the foregoing two
structures can not be used to transmit data.
When the E1 interface is employed, the total time-slots can be optionally bound together to serve as an logical interface that
has the same logic as that of the synchronous serial-interface and can support PPP, X.25 and HDLC protocols.
The main contents of this section are listed as follows:
z Configuring an E1 interface
z Monitoring an E1 interface
4.6.1 Configuring an E1 Interface
The configuration tasks of an E1 interface are listed as follows:
z Configuring the physical-layer operation parameters of an E1 interface
z Configuring the link-layer operation parameters of an E1 interface
Noticeö
ö
1) By default, G.703 is configured as the transparent 2M mode, and the clock as the line clock.
2) Nothing but the serial-interface 0 of low-end routersäincluding MP1700, MP2500 and MP2600åcan support the E1
module.
3) The E1 interface can only operate in the synchronism mode.
Noticeö
ö
1) The link-layer protocols of the E1 interface can be configured as nothing but the synchronism mode;
2) By default, the link-layer protocol configured for the E1 interface is HDLC.
The following example defines an E1 interface: 1-31 time-slot, CCS mode, line clock, no CRC4, PPP link-layer
protocol, IP address 1.1.1.1 and 8-bit mask.
Command Descriptions
router(config)#interface serial0/0 Enter the E1 interface.
router(config-if-serial0/0)#timeslots 1-31 Set the E1 interface to use 1-31 time-slot.
Router(config-if-serial0/0)#ts16 Set the operation mode of the E1 interface as CCS.
Router(config-if-serial0/0)#no crc4 Set the E1 interface to perform no CRC4 check for
the received data and fill no CRC4 checksum in the
transmitted data.
Router(config-if-serial0/0)# encapsulation ppp Configure the link-layer protocol as PPP.
Router(config-if-serial0/0)#ip address 1.1.1.1 Configure the IP address 1.1.1.1 and 8-bit mask of
255.0.0.0 the E1 interface.
Noticeö
ö
When multiple time-slots are configured, “-” is used between the start-slot and the stop-slot. And when a single time-slot
is configured, the time-slot can be directly filled in. when the E1 interface is configured as the CAS mode, the sixteenth time-
slot is only used to transmit signalings
4.6.2 Monitoring an E1 Interface
After finishing the interface configuration, the user can enter the privileged user mode and execute the command show
interface to display the parameter configuration and current operation status of the E1 interface. Each parameter is the same
as that of the serial interface.
When the interface information is examined, the massive error frames can be discovered from the E1 statistics information,
the link-layer negotiation is slow, and there exists packet loss during the PING course.
After finishing the interface configuration, the user can enter the privileged user mode and execute the command show run
interface to display the time-slots occupied by the E1 interface.
The possible causes:
7KH(LQWHUIDFHVXSSRUWVWZRNLQGVRIFRQQHFWLRQFDEOHVRQHLV
QRQ-EDODQFHFRD[LDOFDEOHDQGWKHRWKHULV
balance twisted-SDLUFDEOH:KHQD
HTXLSPHQWLVFRQQHFWHGWKHLPSHGDQFHPD\EHXQPDWFKHG6RWKH
FDEOHLV
often used. When the E1 cable connects with other equipments, pay attention to whether the parameters (such as CRC4,
CCS/CAS, clock mode and time-slot) of the equipment match with those of the other equipments.
4.7 Configuring an 8-port Synchronous Module
An 8s module is an 8-port high-speed synchronous serial-interface module. The 8S module can be used to avoid the non-
synchronous rate between the serial-interface clock based on the bus clock and the factual clock of the V.35 interface. The 8S
module shares 32 time-slots with other TDM bus modules (expect the E1 module), can only operate in the synchronism mode
and support 64K/128K. When an 8S module is inserted into Maipu router, eight interfaces sync0~sync7, which support PPP,
X.25 and HDLC protocols, will be added.
The main contents of this section are listed as follows;
z Configuring an 8S interface
z Monitoring an 8s Interface
4.7.1 Configuring an 8S Interface
The configuration tasks of an 8S interface are listed as follows:
z Configuring the physical-layer operation parameters of an 8s interface
z Configuring the link-layer operation parameters of an 8s interface
Configuring the physical-layer operation parameters of an 8s interface
RouterÔconfig-if-sync0Õ ?
Command Descriptions
RouterÄconfig-if-sync0Å# nrzi-encoding Set the line encoding mode of the interface as the
NRZI-encoding (Non-Return-To-Zero-Inverted-
encoding). The negation form of the command is used
to cancel the NRZI-encoding.
Router Ä config-if-sync0 Å #no nrzi- Set the line encoding mode of the interface as NRZ-
encoding encoding (Non-Return-To-Zero) (the default mode is
the NRZ-encoding.)
Router Ä config-if-sync0 Å # txphase/ Set the transmitting/receiving phase of the interface as
rxphase the rising edge or falling edge.
txphase txup : representing that the channel
sends data at the rising edge.
txdown: representing that the channel sends data at
the falling edge.
rxphase rxup : representing that the channel
receives data at the rising edge.
rxdown: representing that the channel receives data at
the falling edge.
Router Ä config-if-sync0 Å #clock rate Set the clock rate of the interface and configure a bit
<64000/128000> rate receivable for the interface processor. The negation
form of the command is used to cancel the
configuration.
Router Ä config-if-sync0 Å #clock <rx/tx> Set the receiving/transmitting clock of the interface as
<in/out> the interval/external clock.
Notice:
1) The default configuration is: the NRZ-encoding mode, transmitting data at the falling edge and receiving data at the
rising edge, adopting the interval clock as the clock source for transmitting/receiving data.
2) Configure the receiving/transmitting phase, which, generally, need be reconfigured.
3) NRZI is mainly applied to the EIA/TIA-232 connection in the IBM environment.
4) When the clock frequency of the interface is configured, the effect of 0 is equal to that of the command no clock
rate, which means that the interface occupies no time-slot of the TDM bus.
Configuring the link-layer operation parameters of an 8s interface
RouterÔconfig-if-serial0Õë
Command Descriptions
Router Ä config-if-sync0 Å # encapsulation < Configure the protocol that is used on the link layer
Configure encapsulation protocol> of the 8S interface.
RouterÄconfig-if-sync0Å #ip address <unicast Configure the IP address and subnet mask of the 8S
address> < network mask> interface.
Notice:
1) The link-layer protocol configured on the 8S interface can but be synchronous;
2) The default link-layer protocol of the 8S interface is HDLC.
The following example defines an 8S interface (for example interface sync0 ): the NRZ-encoding mode, sending data at the
falling edge and receiving data at the rising edge, the clock frequency 128000, adopting the interval clock as the clock source
for transmitting/receiving data, PPP link-layer protocol, IP address 1.1.1.1 and 8-bit mask.
Command Descriptions
router(config)#interface sync0 Enter the 8s interface sync0.
router(config-if-sync0)#clock rate 128000 Set the clock rate of the interface as 128000.
Router(config-if-sync0)# txphase txdown Set that the data is transmitted at the falling edge of
the interface.
Router(config-if-sync0)# rxphase rxup Set that the data is received at the rising edge of the
interface.
Router(config-if-sync0)# clock rx in Set the receiving clock as the external clock.
Router(config-if-sync0)# clock tx in Set the transmitting clock as the external clock.
Router(config-if-sync0)# encapsulation ppp Set the link-layer protocol as PPP.
Router(config-if-sync0)#ip address 1.1.1.1 Configure the E1 interface: the IP address—1.1.1.1,
255.0.0.0 the mask—8-bit.
noticeö
ö
Noteö
ö
The single-port 128 module supports the 64k/128k synchronous communication mode.
4.8.2 Configuring an 8-port 128 Modem Module
An 8-port base-band modem module can be inserted in the upper or lower layer of the expended slot or both.
1ÕSupporting the link-layer protocols including HDLC, PPP, Frame Relay and X.25 etc.
2ÕSupporting the network-layer protocols such as IP and IPX;
The configuration tasks of the 8-port 128 modem module are listed as follows:
1) Configuring the baud rate;
2) Configuring the line mode;
3) Configuring the operation parameters of the link-layer protocols;
4) Configuring the IP address.
Configuring the clock of the synchronous interface:
RouterÔconfigÕÏ
Command Descriptions
router(config)#interface ebm4/0 Configure the interface ebm4/0 of the 8-port base-
band 128 modem module.
router(config-if-ebm0)#clock rate Configure the clock rate: 64Kbps/128kbps. (The
64000|128000 default value is 64Kbps)
router(config-if-ebm0)#line mode lt|nt Set the line mode: LT/NT(The default mode is
NT ).
router (config-if-ebm0)#ip address 1.1.1.1 The IP address of the port is 1.1.1.1, and the
255.0.0.0 corresponding subnet mask is 255.0.0.0.
router (config-if-ebm0)#enca ppp Encapsulate the PPP protocol.
router(config)#interface ebm4/1 Configure the interface ebm4/1 of the built-in 128
module.
router(config-if-ebm1)#line mode lt|nt Same as above.
router(config-if-ebm1)#enca ppp Same as above.
router(config-if-ebm1)#ip address 2.2.2.1 Same as above.
255.0.0.0
router(config-if-ebm1)#clock rate 64000 Same as above.
…………………. ………………….
Noteö
ö
1) Eight interfaces can support nothing but the synchronism operation mode;
2) Because the base-band MODEM adopts two B channels and the line baud rate need be the integer times of B, namely
the integer times of 64K, the baud rate can be configured only as 64K and 128K.;
3) For the base-band Modem on the other end, its configuration except the operation mode and address must be the same
as that of the modem on this end.
Notice:
1) If the DIP switch of the module is ON, then the bi-direction loop is enabled on the module.
2) When more than 2 ports of the 8-port 128 module operate simultaneously in the NT mode, the data transmission
clock source of the LT equipment connecting with the two ports must be consistent, like a MP9400 128 card in DDN network.
4.9 Configuring a Built-in MODEM Module
Maipu router supports many kinds of built-in frequency-band MODEM modules, such as single-port 1M56/1M336 Modem
module and four-port 4M336/4M56 Modem module. Each kind of interface can operate in the synchronism/asynchronism
mode. For these interfaces, their configuration mode is the same as that of the other serial interfaces, and the difference is that
they support the leased line or dialup line mode, the clock mode in the synchronism mode (internal clock, external clock and
slave clock).
The main contents of this section are listed as follows:
z Configuring a built-in Modem;
z Debugging a built-in Modem.
4.9.1 Configuring a Built-in MODEM Module
The configuration of a single-port MODEM module is the same as that of a multi-port one.
RouterÔconfigÕÏ
Command Descriptions
Router(config)#interface serial0 Enter the configuration mode of the interface
serial0.
router(config-if-serial0)#physical-layer Configure the synchronism/asynchronism operation
sync/async mode.
router(config-if-serial0)#enca ppp Encapsulate the PPP protocol.
router(config-if-serial0)#ip address 2.2.2.2 The IP address of the port is 2.2.2.2, and the
255.0.0.0 corresponding mask is 255.0.0.0.
router(config-if-serial0)#modem clock-rate Configure the Modem line rate in the synchronism
33600 modem.
router(config-if-serial0)#speed 115200 Configure the Modem line rate in the asynchronism
modem.
router(config-if-serial0)#mode clock-mode Configure the Modem clock mode (the external
external/internal/slave clock, the internal clock and slave clock) in the
synchronism modem.
router(config-if)#modem party Configure the Modem answer/origination.
answer/originate
router(config-if-serial0)#mode line leased Configure the leased line mode for Modem.
router(config-if-serial0)#dialer string 5148295 Configure the phone number for the Modem to dial
up in the dialup mode.
router(config-if-serial0)#mode enable/disable Enable/disable the Modem configuration.
Noteö
ö
1) The line rate and clock type need be configured in the synchronism mode. And in the dialup mode, a phone number
of the answer party need be configured on the call origination;
2) When in the synchronism/asynchronism mode, the highest line rate is 33600bps/115200bps.
3) Both sides of modems need select consistent modulation protocol, line rate, synchronism/asynchronism mode, error
control protocol and compression protocol in the asynchronism mode. And when in the synchronism mode, both sides need
select the Modem synchronous clock.
4) Call/Answer configuration: the MODEM to originate the relation is called call origination, and the other party is
called answer.
4.9.2 Built-in MODEM Debugging
Open the MODEM debugging switch and observe its dialup status and related information:
mp2600#debug modem interface-number
Close the MODEM debugging switch:
mp2600#no debug modem interface-number
The following example describes how to use the default system scripts to dial out:
maipu2#debug modem serial0
serial0: Config modem for dialing out
serial0: AT configurating command:
AAT&FE0Q0W1S95=44S36=5S25=0X0
AAT&D2&Q5
AATM1L1
serial0: Success to send the 0th group configuring command
serial0: Success to send the 1st group configuring command
serial0: success to configure modem
serial0: Start dialing automatically
serial0: Dialing timeout is set as 45s(DL-mode)
serial0: Dialing 81...
4.11Configuring an Interface-group
Bind multiple interfaces together as an interface-group. Once interface commands are configured in the interface-group, all
interfaces in the interface-group will automatically generate those commands. This can reduce the repeat of configuring the
same commands on each interface.
The main contents of this section are listed as follows:
z Basic interface-group configuration commands
z An example of interface-group configuration
z Configuration and statistics information of an interface-group
4.11.1 Basic Interface-group Configuration Commands
Create an interface-group:
router(config)#interface group <0-255> ?
Syntax Descriptions
Adopt the enumeration mode to specify some
Enum
interfaces for the generation of an interface-group.
Set the interface range of the interface-group through
Range
specifying the start interface and end interface.
Display all interfaces contained by the interface-
Display
group.
Note:
1) The type of each interface in an interface-group should be the same. (such as asynchronous interface.)2) The
above are the basic commands to create an interface-group. If no interface-group is created, the system will display the
inexistence of the command (such as the command show if-group) related with the interface-group. The commands
related with the configuration and statistics information of the interface-group do not exist until at least one interface-
group is created.
4.11.2 An example of interface-group configuration
Configure interface-group parameters:
Syntax Descriptions
Set interface-group 2 containing 16
router(config)#interface group 2 range async1/0
asynchronous interfaces (from interface async1/0
async1/15
to async1/15).
Encapsulate the terminal protocol on the
router(config-if-group2)#encapsulation terminal
interface-group.
router(config-if-group2)#speed 9600 Configure the rate on the interface-group.
router(config-if-group2)#flow-control software
Configure the flow-control on the interface.
65535
Configuration resultÖ
router#show running-config
...
interface group 2 range async1/0 async1/15 (Configure an asynchronous interface-group.)
....
interface async1/0 (Configure the asynchronous interface contained by the interface-group to be
automatically generated on the interface-group.)
speed 9600
databits 8
stopbits 1
parity none
flow-control software 65535
tx-on dsr
encapsulation terminal
exit
interface async1/1
speed 9600
databits 8
stopbits 1
parity none
flow-control software 65535
tx-on dsr
encapsulation terminal
exit
.... (The following configuration is omitted)
show if-group
Use the command above to display all interface information of each interface-group.
ÏCommand modeÐthe privileged user configuration mode.
Maipu routers supports the following familiar WAN protocols: PPP, HDLC, X.25, LAPB, X.25, frame relay, SLIP, ISDN
and dial-up connection. This chapter describes how to configure Maipu’s MP series routers to connect with a WAN (for
ISDN and dial-up connection information please refer to Chapter 6).
o PPP protocol
o HDLC protocol
o SLIP protocol
o TCP/IP header compression
o X.25 protocol
o Frame Relay protocol
5. 1 PPP Protocol
The topics addressed in this section are as follows:
o Brief Introduction of PPP
o Description of basic PPP instructions
o PPP configuration examples
o Configuring PPP authentication
o Monitor and debug PPP information
o PPP address pool
o PPP multilink
o PPP data compression
5.1.1 Brief Introduction of PPP
The PPP protocol is a kind of data link layer protocol used to transmit network layer packets on the connection from point to
point. PPP includes Link Control Protocol (LCP), Network Control Protocol (NCP), Authentication Protocol (PAP and
CHAP), and it can support synchronous/asynchronous line. PPP can be applied to serial systems with different properties to
transmit many kinds of network layer protocol data. PPP is a universal method of connecting various kinds of hosts, bridges
and routers.
Command Description
In many network modes, IP addresses are distributed in the direction of upper-end to lower-end, so at the lower-end address
negotiation is used to negotiate the address of opposite terminal. For the point-to-point link layer protocol, it supports IP
address negotiation, so it can configure IP address negotiation properties of an interface without an IP address. There are
some typical examples, such as running PPP protocol in serial line to access the Internet through an ISP, configuring the IP
address negotiation of local serial interface, permitting the local interface to receive the address distributed by the opposite
terminal. The relevant configuration commands are as follows:
Command Description
no Ip address negotiated Does not accept the IP address distributed by the opposite
terminal.
U RXW HU
Illustration:
1. The port S0 (3.3.3.1) of local router connects with the port S0 (3.3.3.2) of the opposite router.
Note:
1. Configuration of router2 and router1 are only different in host name, IP address and
clock. In all other respects they are the same.
2. Only encapsulation of the data link layer PPP protocol is discussed in this example. Other configurations of the
physical layer and the network layers can refer to the relevant chapters.
URXWHU
''1 V
URXWHU
1. Because the CHAP authentication needs to check user names, the command hostname is needed to determine the
names of two sides.
2. An example configuration:
V
U RXW HU
''1 V
U RXW HU
Illustration:
1. As is shown in the figure aboveÈthe routers router1 and router2 connect with each other through S0, encapsulate
the PPP protocol, and an address pool is configured in router1 (Users can also configure a default address pool). In
router2 the address negotiation is configured to learn the IP address distributed by the opposite router.
Command Task
Router(config)#ip local pool goat 10.0.0.2 10.0.0.10 Defines an address pool called goat with
network addresses from 10.0.0.2 to 10.0.0.10.
Router(config)#interface serial0 Enters the interface S0.
Router(config-if-serial0)#physical-layer sync Configures it as the synchronous mode.
Router(config-if-serial0)#clock rate 128000 Configures the clock rate.
Router(config-if-serial0)#encapsulation ppp Encapsulates the PPP protocol.
Router(config-if-serial0)#peer default ip address pool goat Designates the opposite terminal to use the
addresses in address pool goat (distribute
addresses from big to small).
Router(config-if-serial0)#ip address 10.0.0.11 255.0.0.0 Configures the IP address.
Router(config-if-serial0)#exit
Command Task
Notice:
1. If you want to use a default address pool, you must first configure the default address pool, then enable it. After ip
add negotiated is configured on the opposite router, it will work. If ip address-pool local is configured in the
global configuration mode, then all the interfaces will use the default address pool, and then it is unnecessary to
configure peer default ip address pool.
2. If you want to use a given address pool, you must first configure the given address pool, and then configure peer
default ip address pool-name on the given interface.
PPP multilink binding can be used to provide load balance for dialup lines (PSTN/ISDN) or synchronous lines, enhance line
throughput and reduce the transmission delay among systems. By means of the PPP multilink binding, a packet can be
divided into multiple slices, which can be transmitted over the multiple parallel links simultaneously and then can be restored
to the original packet orderly.
The PPP multilink supports three binding modes: multilink, dialer and BRI. Dialer and logical interface multilink modes are
applied to the binding of physical interfaces, and the BRI mode is applied to the binding of B channels (MP router can also
support the binding of two ISDN B channels.). The three binding modes support the corresponding network modes
respectively.
The multilink binding mode: the mode is generally applied to synchronous line binding (such as DDN and SDH) instead of
dialup line binding (such as PSTN and ISDN).
The dialer binding mode: the mode is generally applied to the PSTN dialup line binding instead of the ISDN dialup line
binding. Besides that, the mode can also be applied to the synchronous line binding, but it is not recommended.
The BRI binding mode: when the multilink is adopted, the mode can be applied to nothing but the binding of two B channels
of ISDN dialup line.
The following three examples are given respectively for the foregoing three kinds of multilink binding modes.
ä1å
å The multilink binding mode
PXO W L O L QN PXO W L O L QN
6 6
6 6
U RXW HU U RXW HU
Illustration:
As shown in the figure above, two private lines are adopted for the connection of Router1 and Router2. To use PPP
multilink, you should firstly establish a multilink interface respectively for Router1 and Router2 and bind the physical
interfaces to the multilink interface.
1) The multilink interface of router1 is configured as follows:(the related configuration of router2 is similar to that of
router1)
Syntax Descriptions
router1#configure terminal Enter the global configuration mode.
router1(config)#int multilink1 Create a multilink logical interface multilink1.
router1(config-if-multilink1)#ip add 2.0.0.1 Configure the IP address.
255.0.0.0
router1(config-if- multilink1)#encapsulation ppp Enable the PPP protocol.
router1(config-if- multilink1)#ppp multilink Enable the PPP multilink.
2) The physical interface of router1 is configured as follows:(the related configuration of router2 is similar to that of
router1)
Syntax Descriptions
router1(config)#int s1/0 Enter an interface.
router1(config-if-serial1/0)# encapsulation ppp Encapsulate the PPP protocol.
router1(config-if-serial1/0)#multilink-group 1 Relate the physical interface with the multilink
interface.
router1(config-if-serial1/0)#physical-layer sync Configure the synchronous mode.
router1(config)#int s2/0 Enter an interface.
router1(config-if-serial2/0)# encapsulation ppp Encapsulate the PPP protocol.
router1(config-if-serial2/0)#multilink-group 1 Relate the physical interface with the multilink
interface.
router1(config-if-serial2/0)#physical-layer sync Configure the synchronous mode.
ä2å
å The dialer binding mode
GL DO HU GL DO HU
6 6
3671
6 6
U RXW HU U RXW HU
Illustration:
As shown in the figure above, two physical interfaces (frequency-band modem interface or serial interface adopts the
external modem mode) are adopted for the connection of Router1 and Router2. To use PPP multilink, you should firstly
establish a dialer interface respectively for Router1 and Router2 and bind the physical interfaces to the dialer interface.
1) The dialer interface of Router1 is configured as follows. (The configuration of the dialer interface on Router2 is
similar to that of Router1.)
Syntax Descriptions
router1#configure terminal Enter the global configuration mode.
router1(config)#dialer-list 1 protocol ip permit Define a dialer-list.
router1(config)#int dialer1 Create a dialer interface dialer1.
router1(config-if-dialer1)#ip add 2.0.0.1 255.0.0.0 Configure the IP address.
router1(config-if-dialer1)#encapsulation ppp Enable the PPP protocol.
router1(config-if-dialer1)#dialer in-band Enable DDR of the interface.
router1(config-if-dialer1)#dialer-group 1 Define an access group for access control.
router1(config-if-dialer1)#ppp multilink Enable the PPP multilink.
router1(config-if-dialer1)#dialer string Configure the phone number for dialer (two
phone numbers need be configured for two lines)
router1(config-if-dialer1)#dialer load-threshold Specify the load-threshold (such as 1) for the
dialer.
2) The physical interface of Router1 is configured as follows. (The configuration of the physical interface on Router2 is
similar to that of Router1)
Syntax Descriptions
router1(config)#int s1/0 Enter an interface.
router1(config-if-serial1/0)# encapsulation ppp Encapsulate the PPP protocol.
router1(config-if-serial1/0)#dialer rotary-group 1 Relate the physical interface with the dialer
interface.
router1(config-if-serial1/0)#physical-layer async Configure the asynchronous mode (Generally,
PSTN adopts the asynchronous modes)
router1(config)#int s2/0 Enter an interface.
router1(config-if-serial2/0)# encapsulation ppp Encapsulate the PPP protocol.
router1(config-if-serial2/0)#dialer rotary-group 1 Relate the physical interface with the dialer
interface.
router1(config-if-serial2/0)#physical-layer async Configure the asynchronous mode (Generally,
PSTN adopts the asynchronous modes)
The above is the basic configuration of the modem. If the interface adopts the external modem mode,
modem out need still be configured on the serial-interface more.
ä3å
å The BRI binding mode
bri0/0 bri0/0
2.0.0.1/8 2.0.0.2/8
B channel 0 B channel 0
ISDN
B channel B channel
1 1
router1 router2
Illustration:
As shown in the figure above, one ISDN line is employed for Router1 and Router2 to access ISDN. Two B channels of
the line are bound together for a PPP multilink. By default, two B channels are bound with the BRI interface. Thereby, the
BRI binding mode needs no manual configuration of the binding of two B channels and the BRI interface.
1) The BRI interface of Router1 is configured as follows. (The configuration of the BRI interface on Router2 is similar
to that of Router1)
Syntax Descriptions
router1#configure terminal Enter the global configuration mode.
router1(config)#dialer-list 1 protocol ip permit Define a dialer-list.
router1(config)#int bri0/0 Enter the BRI interface.
router1(config-if- bri0/0)#ip add 2.0.0.1 255.0.0.0 Configure the IP address.
router1(config-if- bri0/0)#encapsulation ppp Enable the PPP protocol.
router1(config-if- bri0/0)#dialer in-band Enable the interface DDR.
router1(config-if- bri0/0)#dialer-group 1 Define an access group for access control.
router1(config-if- bri0/0)#ppp multilink Enable the PPP multilink.
router1(config-if- bri0/0)#dialer string Configure an ISDN number for dialup
router1(config-if- bri0/0)#dialer load-threshold Specify the load-threshold (such as 1) for the
dialer.
Command Description
Note 1:
1. Predicor is an algorithm that lays on dense memory and little usage of CPU;
2. Stacker is an algorithm that lays on dense CPU and little usage of memory.
3. display this compression information to refer to debug ppp commands
Note 2:
1. For all the functions achieved by PPP (for example, compression and reliable-link etc.), Users need to configure it
from both sides. If only one side configures a function while the other one does not, the function will not work.
Illustration:
The predictor compression is adopted for the connection of the port S1/0(3.3.3.1) of the local router router1 and the
port S1/0 (3.3.3.2) of the opposite router router2.
A) Router1 is configured as follows.
Syntax Descriptions
router1#configure terminal Enter the global configuration mode.
router1(config)#interface s1/0 Enter the interface S1/0.
router1(config-if-serial1/0)#physical-layer sync The physical layer operates in the
synchronous mode.
router1(config-if-serial1/0)#encapsulation ppp Encapsulate the link-layer protocol
PPP.
router1(config-if-serial1/0)#ppp compress predictor Configure the predictor compression.
router1(config-if-serial1/0)#ip address 3.3.3.1 255.0.0.0 Configure the IP address.
router1(config-if-serial1/0)#clock rate 128000 Provide the clock rate.
router1(config-if-serial1/0)#exit
B) Router2 is configured as follows.
Syntax Descriptions
router2(config)#interface s1/0 Enter the interface S1/0.
router2(config-if-serial1/0)#physical-layer sync The physical layer operates in the
synchronous mode.(Corresponding
with the opposite end)
router2(config-if-serial1/0)#encapsulation ppp Encapsulate the PPP protocol.
router1(config-if-serial1/0)#ppp compress predictor Configure the predictor compression.
router2(config-if-serial1/0)#ip address 3.3.3.2 255.0.0.0 Configure the IP address.
router2(config-if-serial1/0)#exit
5.1.9 PPP BACP (Bandwidth Allocation Control Protocol) and PPP BAP
ppp multilink
To enable the multilink PPP on an interface and dynamic bandwidth allocation, use the interface configuration
command ppp multilink. To disable the multilink PPP or dynamic bandwidth allocation, use the negation of the commaand
to disable it.
ppp multilink [ bap ]
no ppp multilink [ bap ]
Syntax Description
Bap Enable BACP/BAP bandwidth allocation negotiation(optional).
ÏBy defaultÐdisabled.
ÏCommand modeÐthe inteface configuration mode
Illustration:
Router1 and router2 are connected directly in the MPLS core network.
A) Router1 is configured as follows.
Syntax Descriptions
router1#configure terminal Enter the global configuration mode.
router1(config)#interface s1/0 Enter the interface S1/0.
router1(config-if-serial1/0)#physical-layer sync The physical layer operates in the
synchronous mode.
router1(config-if-serial1/0)#encapsulation ppp Encapsulate the link-layer protocol
PPP.
router1(config-if-serial1/0)#ppp mpls Configure PPP to support MPLS.
router1(config-if-serial1/0)#mpls ip Configure an interface to support
MPLS.
router1(config-if-serial1/0)#ip address 3.3.3.1 255.0.0.0 Configure the IP address.
router1(config-if-serial1/0)#clock rate 128000 Provide clock rate.
router1(config-if-serial1/0)#exit
B) Router2 is configured as follows.
Syntax Descriptions
router2(config)#interface s1/0 Enter the interface S1/0.
router2(config-if-serial1/0)#physical-layer sync The physical layer operates in the
synchronous mode.(Corresponding
with the opposite end)
router2(config-if-serial1/0)#encapsulation ppp Encapsulate the PPP protocol.
router1(config-if-serial1/0)#ppp mpls Configure PPP to support MPLS.
router1(config-if-serial1/0)#mpls ip Configure an interface to support
MPLS.
router2(config-if-serial1/0)#ip address 3.3.3.2 255.0.0.0 Configure the IP address.
router2(config-if-serial1/0)#exit
Illustration:
The DES encryption is adopted for the connection of the port S1/0(3.3.3.1) of the local router router1 and the port
S1/0 (3.3.3.2) of the opposite router router2. Ä
A) Router1 is configured as follows.
Syntax Descriptions
router1#configure terminal Enter the global configuration mode.
router1(config)#interface s1/0 Enter the interface S1/0.
router1(config-if-serial1/0)#physical-layer sync The physical layer operates in the
synchronous mode.
router1(config-if-serial1/0)#encapsulation ppp Encapsulate the link-layer protocol
PPP.
router1(config-if-serial1/0)#ppp encrypt des 123 Configure the DES encryption key
(must be consistent with that of the
opposite end)
router1(config-if-serial1/0)#ip address 3.3.3.1 255.0.0.0 Configure the IP address.
router1(config-if-serial1/0)#clock rate 128000 Provide the clock rate.
router1(config-if-serial1/0)#exit
B) Router2 is configured as follows.
Syntax Descriptions
router2(config)#interface s1/0 Enter the interface S1/0.
router2(config-if-serial1/0)#physical-layer sync The physical layer operates in the
synchronous mode.(Corresponding
with the opposite end)
router2(config-if-serial1/0)#encapsulation ppp Encapsulate the PPP protocol.
router1(config-if-serial1/0)#ppp encrypt des 123 Configure the DES encryption key
(must be consistent with that of the
opposite end)
router2(config-if-serial1/0)#ip address 3.3.3.2 255.0.0.0 Configure the IP address.
router2(config-if-serial1/0)#exit
3& U RXW HU
6
03 03
3671
Illustration:
PC connects to the router through the PSTN dialer, and the router allocates DNS, WINS address and an IP address
to PC.
The router is configured as follows.
Syntax Descriptions
router1#configure terminal Enter the global configuration mode.
router1(config)#interface s1/0 Enter the interface S1/0.
router1(config-if-serial1/0)#physical-layer async The physical layer operates in the
asynchronous mode.
router1(config-if-serial1/0)#encapsulation ppp Encapsulate the link-layer protocol
PPP.
router1(config-if-serial1/0)#modem out Set the external MODEM mode.
router1(config-if-serial1/0)#ip address 3.3.3.1 255.0.0.0 Configure the IP address.
router1(config-if-serial1/0)# peer default ip address 3.3.3.2 Allocate an IP address to PC.
router1(config-if-serial1/0)#ppp ipcp dns 1.1.1.1 1.1.1.2 Allocate DNS address to PC.
router1(config-if-serial1/0)#ppp ipcp wins 2.1.1.1 2.1.1.2 Allocate WINS address to PC.
router1(config-if-serial1/0)#exit
ro u ter
D ia lu p a c c e s s s y s t e m
S 1 /0
163
M P336
605
PSTN
Illustration:
When a dialup access system (or PPPOE access system) is performing the chap authentication, the null name is
sent to the lower-end equipment. Thereby, the downlink equipments can not search the related password from the user
base according to the username of the upper-end equipment. Hare, it is necessary to configure the chap authentication
of null username for MP router.
The router is configured as follows.
Syntax Descriptions
router1#configure terminal Enter the global configuration mode.
router1(config)#interface s1/0 Enter the interface S1/0.
router1(config-if-serial1/0)#physical-layer async The physical layer operates in the
asynchronous mode.
router1(config-if-serial1/0)#encapsulation ppp Encapsulate the link-layer protocol
PPP.
router1(config-if-serial1/0)#modem out Configure the external MODEM
mode.
router1(config-if-serial1/0)#ip address 3.3.3.1 255.0.0.0 Configure the IP address.
router1(config-if-serial1/0)#ppp chap hostname abc Configure the username allocated by
the access system.
router1(config-if-serial1/0)#ppp chap password 123 Configure the password allocated by
the access system.
router1(config-if-serial1/0)#dialer string 163 Set the called number 163 of the
access system.
router1(config-if-serial1/0)# modem party originate Set MODEM as the call origination.
router1(config-if-serial1/0)# modem enable Enable the modem.
router1(config-if-serial1/0)#exit
5.2 HDLC protocol
router(config-if- XXX)#
Command Description
V
U RXW HU
''1 V
U RXW HU
Illustration:
1. As shown in the figure above, router1 and router2 connects to each other through serial port s0 and use HDLC
protocol.
2. The port S0 (3.3.3.1) of local router router1 connects to the port S0 (3.3.3.2) of the opposite router router2.
Maipu routers can be configured to work in HDLC bridge mode. In this mode the equipment connected together at the two
ends of the bridge can transmit data transparently through the TCP/IP network. From the viewpoint of users, the equipment at
two ends of bridge was connected to each other through a pair of MODEMs would be connected to each otherØwhile the
intermediate TCP/IP network looks like a direct-cable.
1) Configuring instructions
router(config-if-XXX)#
Command Description
encapsulation hdlc
bridge ip <A.B.C.D> <bridge prot number> Configures the local IP address (equipment as
<client / server> server)/peer IP address(equipment as client) and the
bridge-connection port.
2) A sample configuration
,3
1HW ZRU N
5RXW HU $ 5RXW HU %
Illustration:
Through the configuration showed in the above figure, the user PCs Equipment A and B connect on the both sides of the
bridges to routerA and routerB which can transmit data transparently across the TCP/IP network
3) Displaying Information
The command “show interface” allows users to examine the current connection status of the bridge.
For example:
routerA#show interface serial3
serial (unit number 3):
Flags: (0x80f0) DOWN POINT-TO-POINT MULTICAST RUNNING
Type: HDLC
Metric is 0
Maximum Transfer Unit size is 1500
0 packets received; 0 packets sent
0 multicast packets received
0 multicast packets sent
5 input errors; 0 output errors
0 collisions; 0 dropped
hdlc version: v1.27
hdlc bridge client: 6.1.1.1,5000, connect The bridge is at the status of connected.
rxFrames 1744, rxChars 74436
txFrames 1738, txChars 74410
rxNoOctet 0, rxAbtErrs 0, rxCrcErrs 0
rxOverrun 0, rxLenErrs 0, txUnderrun 0
DCD=up DSR=up DTR=up RTS=up CTS=up TxC=up
rate=128000 bps
SLIP is a kind of protocol widely used at present to transmit IP datagrams on a serial line. While it is a very p ractical
standard while not an Internet standard. It is only a protocol used to encapsulate IP datagrams, and only defines the sequence
of the characters in the IP datagram that is encapsulated in the link layer frame format and is sent over a serial line, without
providing the functions such as dynamical IP address distribution, datagram type identity, error checking/correction and data
compression etc.
5.3.2 An example of configuration
SLIP configuration is simple, which generally includes about several procedures: configuring the physical layer as
asynchronous, the link layer encapsulating SLIP and peer IP address. In addition, properly asynchronous configuration is
must.
V
U RXW HU
''1 V
U RXW HU
Illustration:
1. As shown in the above figure, router1 and router2 connect to each other through serial port s0 and both run the
SLIP protocol.
Note:
1. Peer ip add A.B.C.D is used to designate the IP address of the opposite side.
TCP/IP packet header compression is geared toward protocols and it only compresses TCP/IP packet headers. So the frame
header of the second layer will not be changed. The data frame whose TCP/IP packet header has been compressed will be
transmitted on the WAN link.
In other words, TCP/IP packet header compression is more useful with the minitype packets that only have several bytes
(such as a telnet packet). The packet header compression protocols supported by Maipu routers are: X25 protocol, Frame-
relay protocol, PPP protocol and HDLC protocol. This kind of packet can also be applied to the dial-up WAN link protocol.
Because data compression wll bring additional process, packet header compression is usually used on the low-speed link, for
example, the 64Kb/S link.
Command Description
Command Description
The second layer of X.25 or namely LAPB corresponds with the data link layer of the OSI reference mode. LAPB prescribes
the format (called frame) to exchange data on the physical link, to check losing sequence and losing frame, to perform frame
retransmission and frame acknowledge
router(config-if-XXX)#lapb ?
Command Description
V V
;
URXWHU URXWHU
A. The configuration of router1:
Command Task
Router1#configure terminal
Router1(config)#interface s0 Enters port S0.
Router1(config-if-serial0)#physical-layer sync The physical layer works in the synchronous
mode.
Router1(config-if-serial0)#encapsulation x25 Encapsulates the data link layer protocol
X.25.
Router1(config-if-serial0) x25 dte Configures X.25 as DTE mode.
Router1(config-if-serial0)x25 address 200 The X.121 address is 200
Router1(config-if-serial0)x25 map ip 3.3.3.2 100 Establishes the map between the IP address
of the opposite terminal and the X.121
address.
Router1(config-if-serial0)#ip address 3.3.3.1 255.255.255. Configures the IP address of port S0.
Ü
Router1(config-if-serial0)#end
Command Description
A subinterface is a virtual interface that is capable of connecting to some networks through a physical interface. For the
routing protocol using the split-horizon rule, subinterface is needed to decide which host needs routing updates. In a WAN
environment, if sub-interface (X.25) is used, other routers that are connected through the same physical interface may not
receive the route update information. Compared with the routers connected through the different physical interfaces, the
subinterface can be used and it can be regarded as a separate interface. Then the host can be connected to different
subinterfaces of the same physical interface. The route process regards each subinterface as an independent route update
source; so all the subinterfaces can be fit for receiving route update information.
A subinterface has two types: point to point and point to multipoint. The default is point to multipoint. At the current time,
X.25 of Maipu routers only support the point-to-multipoint subinterface.
1. When the subinterface is configured, X.25 must be configured on the master-interface. And the x25 address x121-
address also needs to be configured (if the subinterface uses the map mapping) or x25 ltc ltc-nunber is configured
(if the subinterface uses the pvc mapping), and the ip-address is configured on the master interface.
2. If a sub-interface wants to be up, the master-interface must be up first. If the master-interface is shutdown, it is
natural that the subinterface will be down.
U RXW HU
V
V
;
V
U RXW HU
V
U RXW HU
Illustration:
The above figure represents how to configure a subinterface on router1 so as to connect the whole X.25 network. Router2
corresponds with the master interface of router1 while router3 corresponds with the subinterface of router1.
Note:
1. The router can be used as a local or a remote switch, and it can switch X.25 data streams through TCP. Which is
called XOT (X.25 Over TCP) usually.
1. SVC switching
router(config)#
Command Task
router (config)#x25 routing Configures it as an X.25 switch.
X.25 data streams can be routed between local serial ports. In this situation, the static routing command is needed to map
X.121 address to the serial port. The router permits the X.25 interface connected to different ports to perform Switched
Virtual Circuit (SVC) connection, and this is called local X.25 connection.
Remote X.25 switching enables the X.25 interface connected with different routers to establish the switched virtual circuit
(SVC) and permanent virtual circuit (PVC). Remote X.25 switching is achieved through using tunnel technology for all X.25
calls and data streams between routers on the TCP connection. In order to enable remote switching, users can use the
command “X25 router”:
6 6
U RXW HU U RXW HU U RXW HU
[ [
Illustration:
As shown in the figure above, we premise that router3 is used as the X.25 switch, and that router2 and router4 perform
communication between them through the X.25 switching function of router3. The X.121 address of the serial-port s2 of
router2 is 200 while the X.121 address of the serial-port s3 of router4 is 100. We also need to configure the IP addresses of
router2 and router4 by manually.
Command Task
Command Task
There are two kinds of PVC switching functions: one is the local PVC switching and the other is the XOT switching that is
used to connect two lines of PVC through TCP/IP network.
The commands of X.25 PVC:
router (config-if-serial3)#x25 pvc Circuit number interface type number pvc number1
Command Description
Command Description
B.Example
V V
U RXW HU U RXW HU U RXW HU
[ [
Illustration:
As shown in the above figure, the PVC between router2 and router3 is 1, while the PVC between router4 and router3 is 2.
Router3 is used as a PVC X.25 switch. The usage of the interface can be seen from the above figure.
Relevant configuration:
The configuration of router2:
Command Task
Command Task
router3(config)#x25 routing
Configures it as X.25 switch.
router3(config)#int s2 Enters the interface s2 mode.
router3(config-if-serial2)#physical-layer sync Configure it as the synchronization mode.
router3(config-if-serial2)#clock rate 128000 Configures the clock.
router3(config-if-serial2)#encapsulation x25 Encapsulates X.25 protocol.
router3(config-if-serial2)#x25 dce Encapsulates X.25 as DCE mode.
router3(config-if-serial2)#x25 ltc 16 Configures the value of 1tc.
router3(config-if-serial2)#x25 pvc 1 interface serial 3 pvc Configures the switching PVC.
2
router3(config-if-serial2)#lapb dce Encapsulates LAPB as DEC mode.
router3(config-if-serial2)#int s3 Enters the interface s3.
router3(config-if-serial3)#physical-layer sync Configures it as the synchronization mode.
router3(config-if-serial3)#clock rate 128000 Configures the clock.
router3(config-if-serial3)#encapsulation x25 Encapsulates X.25 protocol.
router3(config-if-serial3)#x25 ltc 16 Configures the value of 1tc.
router3(config-if-serial3)#x25 dce Encapsulates X.25 as DCE mode.
router3(config-if-serial3)#lapb dce Encapsulates LAPB as the DEC mode.
router3(config-if-serial3)#x25 pvc 2 interface serial 2 pvc Configures switching PVC.
1
router3(config-if-serial3)#exit Configuration has been finished.
Command Task
6 V V
39& U RXW HU
6
U RXW HU
Illustration:
1. As shown in the above figure, X.25 protocol runs between router1 and router2, and it also runs between router3
and router4. However, the PPP protocol runs between router2 and router3. The PVC value and the situation of the
corresponding interface connection can be derived from the above figure.
Command Task
Command Task
Command Task
Command Task
1. Configuring instructions
Command Task
2. An example`
LegendÖ
Router1 and router2 is connected directly throuth X.25
A Configuration of router1
Command Task
Router1(config)#interface s1/0 Enters the interface mode
Router1(config-if-serial1/0)#encapsulation Encapsulates X.25 protocol.
x25
Router1(config-if-serial1/0) x25 dte Configures X.25 as DTE mode
Router1(config-if-serial1/0)x25 address 100 Configure X.121 address as 200
B Configureation of router2
Command Task
Router2(config)#interface s1/0
Router2(config-if-serial1/0)#clock rate 128000 Configure the clock rate
Router2(config-if-serial1/0)#encapsulation
x25
Router2(config-if-serial1/0)x25 dce
Router2(config-if-serial1/0)x25 address 200 Configure X.121 address to 200
Router2(config-if-serial1/0)#end Configuration has been finished.
Router2#pad 100 PAD to peer
Router1> Login
Syntax Descriptions
lapb k Configure the maximal number of uncertained frames,
namely window size.
lapb modulo Configure LAPB basic (mode 8)/extended (mode16)
protocol mode.
lapb N1 Configure the maximal number of bits contained in a
frame.
lapb N2 Configure the maximal times of data packet
retransmission.
lapb T1 Configure the value of the retransmission timer.
lapb T2 Configure the value of the acknowledgement timer.
lapb T4 Configure the value of the idle timer.
4) x.25-profile
Use the command x.25-profile to relate a X.25 Profile with some frame-relay PVC on a frame-relay interface;
otherwise, use the negation of the command to cancel the relation.
frame-relay interface-dlci number
x25-profile name
no x25-profile name
Syntax Descriptions
Number The DLCI number of the frame-relay PVC related
with X.25 profile
Name The name of X.25 profile related with PVC
£By default¤There exists no relation.
£Command mode¤the frame-relay DLCI configuration mode.
5) Use the following command to send out a X.25 call through the frame-relay network:
x25 route address interface serial-interface dlci number
Syntax Descriptions
Address The X.121 destination address.
serial-interface Route the selected call to the specified frame-relay
serial interface.
Number The frame-relay DLCI number used to transmit the
call.
An Example of Configuring X.25 over Frame-relay Network
Frame relay
Illustration:
As shown in figure above, a connection between RouterA and RouterB is established through a X.25 packet switching
network; the interconnection between RouterB and RouterC is realized through a frame-relay switching network; and the
connection between RouterC and RouterD is established through a X.25 packet switching network. By means of Annex.G,
X.25 packets between RouterA and RouterD are transmitting over the frame-relay network.
RouterC(config-if-serial1/0)#exit
RouterC(config)# x25 route 70 interface serial1/0 dlci 200 Transmit a X.25 call over the specified
frame-relay PVC.
RouterC(config)# x25 route 71 interface serial2/0 Transmit a X.25 packet.
Frame relay is a protocol standardized by ANSI and CCITT, and it can provide remarkable performance/price ratio to busting
out traffic (for example, LAN inter-connection and SNA). Frame relay is a kind of interface protocol between the Customer
Premise Equipment (CPE), such as a router or Front End Processor, and a WAN sending data to remote CPE.
Command Description
V V
)U DPH
U RXW HU U HO D\
U RXW HU
Illustration:
The S0 port (3.3.3.1) of local router router1 connects to the S0 port (3.3.3.2) of the opposite router router2.
Users can examine the PVC status of frame relay, and “ACTIVE” indicates that the PVC is in usable status. Users can also
examine all the frame relay interfaces or a given one to determine the given PVC status and the statistic number of
received/sent packets.
A. Displaying all status information of virtual link (of interface) on the local router
show frame-relay pvc [interface serial number]
PVC statistics for interface serial0 (Frame Relay DTE)
DLCI = 17, DLCI USAGE = LOCAL, PVC STATUS = ACTIVE, INTERFACE = serial0
input pkts 10 output pkts 10 in bytes 1040
out bytes 1040 dropped pkts 0 in FECN pkts 0
in BECN pkts 0 out FECN pkts 0 out BECN pkts 0
in DE pkts 0 out DE pkts 0
Command Description
show frame-relay lmi [interface serial number] Displays LMI statistic of frame relay.
debug frame-relay lmi [interface serial number] Displays LMI running data of frame
relay.
debug frame-relay packet [interface serial number] Displays data operation beared by frame
relay.
debug frame-relay log [interface serial number] Displays frame relay events and error
indication.
Notice:
o The physical layer must be in synchronous mode.
o The IP addresses of the ports of two connected routers must be in the same network segment.
o When show int s n shows that the interface is “UP”and show frame map shows that status is“ACTIVE”, it is
indicated that frame relay has connected with the WAN port and can begin to transmit data.
o Description of the basic instructions of frame relay Reverse Address Resolution Protocol
o A typical configuration example of frame relay Rdverse Address Resolution Protocol
o Debugging/monitoring of frame relay Reverse Address Resolution Protocol
A. Description of the basic instructions of frame relay Reverse Address Resolution Protocol
router(config-if)#
Command Description
B. The diagram below shows a typical configuration example of frame relay Reverse Address Resolution Protocol
V V
)U DPH
U RXW HU U HO D\
U RXW HU
Illustration:
1. The port S0 (3.3.3.1) of the local router router1 connects to the port S0 (3.3.3.2) of the opposite router router2.
Displaying packets receiving/sending status of frame relay Reverse Address Resolution Protocol
show frame-relay inarp
Frame Relay Inarp statistics for interface serial2:
InARP requests sent 5, InARP replies sent 0
InARP request recvd 0, InARP replies recvd 4
A subinterface inherits the properties of a masterinterface, so before the subinterface is configured, the frame relay must be
encapsulated on the main interface. [LMI]
Command Description
Command Description
V
V )U DPH U HO D\
U RXW HU V
V
U RXW HU
Illustration:
1. The above example explains how to configure the subinterface on the router A so as that the whole frame relay
network can be connected. The router router2 connects to the main interface of router1 while the router router3
connects to the subinterface of router1.
router(config)#frame-relay switching
Command Description
Configure the router, through the commmand frame-relay switching, to execute the switch function in frame relay network.
When the router runs as a Router(config)#frame-relay switching switch, data stream can be exchanged between two serial
ports of the router through the command frame-relay. The router executes PVC data exchange between two serial ports.
Command Description
The interface configuration can be applied to frame relay switch through the command frame-relay intf-type. The type of
frame relay switch is decided by the functions of the router in frame relay network.
router(config-if-XXX)#frame-relay intf-type [dte |dce |nni]
C. The command Frame-relay intf-type
Router(config-if-XXX)#
Command Description
Command Task
Command Task
Command Task
Command Task
Frame-relay
Frame-relay
frame-relay de-group
To eable DE bit discarding rule on DLCI, use the command frame-relay de-group, or else, use the negation of the
command to disable it.
Frame-relay de-goup de-list-number dlci
Syntax Description
De-list-number DE list number
Dlci DLCI number
ÏBy defaultÐdisabled
ÏCommand modeÐthe interface configuration mode
frame-relay congestion-management
To enable the DE rule on an interface, use the command frame-relay congestion-management, or else, use the
negation of the command to disable it.
ÏBy defaultÐdisabled.
ÏCommand modeÐthe interface configuration mode
2) Configuration examples
An example of the configuration command DE-list frame-relay de-list
define DE list 1 for IP fragment packets / Set DE bit for packets of the IP fragment.
frame-relay de-list 1 protocol ip fragment
define DE list 2 for port 500 of UDP packets / Set DE bit for UDP packets whose port number is 500.
frame-relay de-list 2 protocol ip udp 500
£By default¤If the peak rate is omitted, the adopted default value is the line rate.
£Command mode¤the map type configuration mode.
frame-relay adaptive-shaping
Use the command frame-relay adaptive-shaping to specify the rate adjust mode for the PVC related with some map
type; otherwise, use the negation of the command to deny the rate adjust.
frame-relay adaptive-shaping { becn | foresight}
no frame-relay adaptive-shaping
Syntax Descriptions
Becn Perform the rate adjust according to BECN message.
Foresight Perform the rate adjust according to foresight message.
£By default¤The command is disabled.
£Command mode¤the map type configuration mode.
frame-relay custom-queue-list
Use the command frame-relay custom-queue-list to specify the custom-queue for the PVC related with some map
type; otherwise, use the negation of the command to restore the default value of the PVC queue.
frame-relay custom-queue-list list-number
no frame-relay custom-queue-list list-number
Syntax Descriptions
list-number The list-number of the queue.
£By default¤The default queue is FCFS (First Come First Service).
£Command mode¤the map type configuration mode.
frame-relay priority-group
Use the command frame-relay priority-group to specify the priority queue for the PVC related with some map type;
otherwise, use the negation of the command to restore the default value of the PVC queue.
frame-relay priority-group list-number
no frame-relay priority-group list-number
Syntax Descriptions
list-number The list-number of the queue.
£By default¤The default queue is FCFS.
£Command mode¤the map type configuration mode.
frame-relay traffic-shaping
Use the command frame-relay traffic-shaping to make traffic shaping effective for all PVC of a frame-relay interface;
otherwise, use the negation of the command to disable the function of traffic shaping.
frame-relay traffic-shaping
no frame-relay traffic-shaping
£By default¤The command is disabled.
£Command mode¤the interface configuration mode.
frame-relay class
Use the command frame-relay class to relate a map type with an interface or a sub-interface; otherwise, use the
negation of the command to cancel the relation.
frame-relay class name
no frame-relay class name
Syntax Descriptions
name The name of the map class related with the
interface/sub-interface.
£By default¤There exists no relation.
£Command mode¤the interface configuration mode.
class
Use the command to relate a map type to some PVC; otherwise, use the negation of the command to cancel the relation.
class name
no class name
Syntax Descriptions
Name The name of the map class related with the PVC.
£By default¤There exists no relation.
£Command mode¤the DLCI configuration mode.
5.6.11.2 An example of traffic shaping configuration
Frame relay
Illustration:
As shown in figure above, an interconnection between RouterA (the port s0/0 192.168.2.1) and RouterB (the port s1/0
192.168.2.2) is established through a frame-relay network. The frame-relay traffic shaping policy is adopted to limit data
transmission rate over the specified PVC between RouterA and RouterB and provide high priority service for Telnet data
transmission between RouterA and RouterB.
Frame
relay
Illustration:
As shown in figure above, in the one-point-to-multi-point frame-relay network, all routers are required to adopt the
point-to-point sub-interface configuration mode. The interface f0 of RouterA has three sub-interfaces that belong to three
different VLANs respectively. And the interface S0/0 also has three sub-interfaces that are related with three different
VLANs respectively; the interface f0.1 of RouterB belongs to Vlan1 and the interface s1/0.1 is related with Vlan1; the
interface f0.1 of RouterC belongs to Vlan2 and the interface s2/0.1 is related with Vlan2; the interface f0.1 of RouterD
belongs to Vlan3 and the interface s3/0.1 is related with Vlan3.
NoticeÖ
Vlan-bridge is required to adopt the point-to-point sub-interface configuration mode.
Chapter 6 DDR and Interface Backup
This chapter mainly describes how to configure a Maipu Router to perform the remote dialer access through PSTN and ISDN
(Integrated Services Digital Network).
A built-in frequency-band modem in a Maipu router supports several dialer modes, such as synchronism, asynchronism,
dialer line, and leased line etc. This section describes how to configure the built-in frequency-band modem in a Maipu router
to perform the remote dialer function.
Command Description
Note:
1. The above commands can be used similarly when MP336/56MODEM is connected externally
Command Description
dialer string <number> Configures the telephone number of the called side. The number can only
be composed of Arabic numerals (When the exterior line of the built-in
modem is a dialer line, the number needs to be configured; when the
exterior line of the modem is a leased line, the number does not need to be
configured.)
Note:
1. Many called numbers can be configured. After this, when the router dials a number, it will adopt the polling dialer
(Namely, the first number is dialed; if it is busy, then the second number is dialed in turn, and so on)
2) Examples of usage of configuring commands
A. A leased line mode
6
5RXHU
6
5RXHU
Illustration:
1. The built-in frequency-band MODEM is configured on the interface interface serial2 of router1 and router2. And
the leased line mode is configured.
3. router1 is a caller that uses the internal clock, while router2 is the answer that uses the slave clock. The line speed
is 9600.
Command Task
6
3671
6 5RXHU
5RXHU
Illustration:
1. The built-in frequency-band MODEM is configured on the interface serial2/0 of router1 and router2. And the dialer
mode is configured.
2. Router1 is a caller and router2 is an answer.
router2
Command Task
router2#configure terminal
router2(config)#interface serial2/0 Enters the relevant interface.
router2(config-if-serial2/0)#ip address 10.1.1.2 Configures the IP address.
255.255.255.0
router2config-if-serial2/0)#physical-layer sync Configures it as the synchronous mode.
router2(config-if-serial2/0)#encapsulation PPP Encapsulates PPP protocol.
router2(config-if-serial2/0)#modem party answer Configures it as an answer.
router2config-if-serial2/0)#modem clock-rate 33600 Configures MODEM ratio.
router2(config-if-serial2/0)#modem enable Enables the MODEM.
router2(config-if-serial2/0)#exit
Note:
1. When using the leased line mode, MODEM keeps on calling (or answering) until it is connected.
2. If it is an outer modem, modem outer needs to be configured.
Editing script
router (config)#chat-script script-name script
script name script content
Configure the Modem script that is executed when a connection needs to be established:
router(config-if- XXX)# script connection script-name
Script-name is configured in the global configuration mode: chat-script script-name, which is the script-name in the script.
Its purpose is to connect the AT command with the corresponding interface.
When the router needs the modem to call out, it will send the script designated by script-name to the modem first, and then it
will initialize configuration of the modem. When all of the modem scripts have been executed successfully, the initialization
finishes. After this, the router sends the dialer string to the modem to call the opposing party.
Similarly, when the modem is configured as modem party answer, and when the opposite terminal sends call and the local-
end receives a bell-shaking signal, the router will also sends the modem initialization script to configure the modem. When
all configuration succeeds, the modem will negotiate with the opposite modem, and the router will enter the status
Answering incoming call to wait for the connection of modem. When the modem has succeeded in connecting, it will enter
the phase of the link layer negotiation.
Note:
1. If no script is configured for the modem, then the modem will start the default script set by the system. Because the
AT scripts supported by various companies have some differences, it is recommended that users configure the
script for a modem through referring to the modem usage manual of its company so that the modems of different
companies and types can work in better harmony with the router.
2. You can use the debug commands (for example, debug modem s2) to examine the default script.
THE AT
COMMANDS IN The relevant explanation
COMMON USE
&QnDn (the default is D2) &D0 : simple hangup of the modem;
Functions of all kinds of &D1 : changing from the data mode to the command mode;
compressions triggered &D2 : the modem hangs up and closes the auto-answer;
respectively when DTR hops from
&D3 : the modem reset
ON to OFF. Notice that D0 can be
only useful to the Q1 mode, while
D1, D2 and D3 are useful to all the
compression modes.
&Qn
(The default is &Q5) &Q0: Using the direct asynchronous mode
&Q1: Using the synchronous connection mode (the command mode
being of asynchronism)
&Q5: Using the error asynchronous mode
&Q0: Using the common asynchronous mode (with the function of rate
buffer)
Result codeæn=0-6ØOKç other valueØERROR
&QnCn &C0: DCD being ON all the time;
(controled by DCD) &C1: DCD indicating the status of the carrier wave;
(The default is &C1) Result code: n=0,1, OK; other values, ERROR.
&K0: no flow control mode
&Kn &K3: the RTS/CTS flow control mode (the default)
&K4: the XON/XOFF flow control mode
(the flow control modes between
DCE and DTE) &K5: transparent XON/XOFF flow control mode
&K6: the XON/XOFF and RTS/CTS simultaneous control mode
e default is &K3) The result code: n=0,3 to 6, OK; other values, ERROR
&Ln &L0: the command mode;
&L2: the auto leased line mode
Functions of the leased (special) &L3: the auto dialer line mode
line
&L5: the dialer backup working mode
1. When the command AT is configured, it should be done according to the instructions of the corresponding
company.
2. When different modulation protocols are chosen, the appropriate one should be done according to the different line
status. For example, both V.34 protocol and V.22bis support the speed 2400. But in fact, the same speed using
different modulation protocols will have different effect because of the line status.
Command Task
router(config-if- XXX)#backup delay Configures the time should elapsed before the
secondary line status changes after a primary
line status has changed
router(config-if-XXX)#backup interface Configures an interface as a secondary or dail
backup
For example:
router(config-if- XXX)# backup interface s3/0
Set the interaface s3/0 as the backup line
router(config-if- XXX)# backup delay 5 5
Set a 5-second delay on activating the secondary line and set a 5-second delay on deactivating the
secondary line
6
6
5RXW HU e o$
:$1
6 6
5RXW HU e o%
&DO O $QVZHU
0RGHP 3671
Explanation: The serial 2 of the router router-A connects to an outer modem, chooses the asynchronous mode, encapsulates
PPP protocol , is used as a backup line of serial 0 and a caller uses the manual configuration of modem script; The detailed
configuration is as follows:
Command Task
router-A(config)#int s0
router-A(config-if-serial0)# encapsulation ppp
router-A(config-if-serial0)# physical-layer sync
router-A(config-if-serial0)# backup interface serial2 Configures the S2 as a backup
interface.
router-A(config-if-serial0)#
backup delay 5 5 Set a 5-second delay on activating
the secondary line after the primary
line goes down and set a 5-second
delay on deactivating the secondary
line after the primary line comes up
router-A(config-if-serial0)#ip add 128.255.1.1 255.255.0.0
router-A(config-if-serial0)#exit
router-A(config)# Establishes a MODEM script:
chat-script modem-configure at&f%c3&k3&c1 The script name: modem-configure
The script contents:
at&f%c3&k3&c1
router-A(config)#int s2
router-A(config-if-serial2)# physical-layer async
router-A(config-if-serial2)# encapsulation ppp
router-A(config-if-serial2)#speed 38400
router-A(config-if-serial2)# modem outer Configures the outer MODEM.
router-A(config-if-serial2)# dialer string 5566030 Configures the called number as
5566030.
router-A(config-if-serial2)#modem party originate Configures MODEM as the caller.
router-A(config-if-serial2)#script connection modem-configure Specify the modem script that
should be executed
router-A(config-if-serial2)#ip address 192.255.255.1 255.255.255.0 Configures the IP address.
router-A(config-if-serial2)#exit Configuration has been finished.
Note:
Analyzing the above script: &f is to used to load the factory default configurationç%c3&k3&c is used to modify the
corresponding parameters of the script. Of course, if you want to configure the parameters by yourself, you need not use the
script of &f.
The serial 2 of the router router-B connects to an outer modem, chooses the asynchronous mode, encapsulates PPP protocol,
is used as a backup line of serial 0 and an answer uses the default script of the modem;
The detailed configuration is as follows:
router-B(config)#int s0
router-B(config-if-serial0)#
ip add 128.255.1.12 255.255.0.0
router-B(config-if-serial0)# encapsulation ppp
router-B(config-if-serial0)# physical-layer sync
router-B(config-if-serial0)#exit
router-B(config)# Configures the dialer script.
chat-script modem-configure at&f%c3&k3&c1
router-B(config)#int s2
router-B(config-if-serial2)# physical-layer async
router-B(config-if-serial2)# enc ppp
router-B(config-if-serial2)# flow-control software
router-B(config-if-serial2)#
ip address 192.255.255.2 255.255.255.0
router-B(config-if-serial2)# modem outer Starts the outer MODEM.
Backup load
Set a traffic load threthold for dial backup service
Backup load {enable-threshold|never} {disable-load|never}
no backup load
Syntax Description
Note:
1. You shoud configure backup interface first before configure load dialup.
2. The traffic statistics of the line is the traffic statistics every 5 minutes.
Illustration;
1) Two lines are employed between Router1 and router2: one is the primary line, connecting with the interface s2/0, and
the other is the backup line, connecting with. The phone number corresponding router1 is 601 and that corresponding to
router2 is 611.
2) The purpose of the example above is that when the traffic load reaches the value assigned to the line, the secondary
line is activated although the primary line is still enabled.
About the detailed DDR configuration, refer to Section 5.2 DDR Dialup Configuration.
3) Debug commands
z show interface
Display the 5-minute traffic load of an interface
z Debug backup
Display the debugging information in the course of load dialup.
To examine its dialer status and the relative information, use the debug modem command:
router#debug modem interface
This command displays the debugging information of a given interface
4. When the modem connects with Cisco products, users should notice whether the modem DTR lamp is normal. If it is
abnormal, users should clear the line through the command clear line ***.
The global configuring command is: dialer-list (also called dialer list). In order to control the condition for a DDR call to take
place, users can use the command dialer-list to configure the packet condition. Only those packets that meet the packets
prescribed by dialer-list can initiate DDR to dial up. The simple format of the command can prescribe a set of protocols that are
both permitted to trigger a call/prohibited from triggering a call. The complex format of the command can cite an access control
list so as to define interesting data in detail.
router(config)#dialer-list dialer group number protocol ip { permit | deny | list access-list-number }
Dialer group number is the sequence number <1_10> of dialer-list, corresponding with the dialer-group group-
number of DDR interface configuration.
Access-list-number is the sequence number of the access list access-list corresponding with dialer-list
Ip is a protocol name, and the protocol supported presently is ip protocol.
Permit indicates packets corresponding with the protocol are permitted.
Deny indicates packets corresponding with the protocol are denied.
Note:
1. When configuring the access list, you should do it orderly. In addition, the multicasting packet of the routers from
some companies can trigger the dialer. For example, for the multicasting packet of OSPF 224.0.0.5, it is best to
deny it; or else, the telephone company will give you the telephone bill. Or you can use debug dialer packer to
examine whether there is the multicasting packet, whether it is necessary to configure an access list for the triggered
dialer
router(config-if-serial1)#dialer ?
The relevant configuration is as follows:
Command Description
After defining a dialer-list, you need to associate it with the interface answering for originating/accepting call. The
corresponding command is as follows:
dialer-group: The command configures an interface as a member of a special dialer group. The group points to a dialer list.
group-number: It is the number of the dialer group the interface belongs to. The group is defined through the command
“dialer-list”, which defines the interesting traffic of DDR. The value that can be accepted is an integer from 1 to 10.
dialer-group
The command configures an interface to belong to a given dialer-group, which points to a dialer-list.
group-number
This is the number of the dialer access group to which the interface belongs. The dialer access group is defined by the
command “dialer-list”, which defines the trigger data stream originating DDR. The acceptable values are the integer within 1
to 10.
After defining the structure of the interesting traffic, you should provide the interface answering for originating call/answer
with all necessary parameters that arriving at the destination needs. Here, “dialer map” or “dialer string” indicates the routing
information, such as the telephone number to dial, etc.
The command dialer map:
router(config-if-serial1)#dialer map ip A.B.C.D name hostname dialer-string
ip representing protocol
A.B.C.D representing the name of the remote system
dial-string representing the dialed telephone number to arrive at the remote-end destination
Note:
1. When it is only used to send call, the command dialer map and the telephone number string dialer-string are
necessary; the keyword name is optional.
2. If the keyword name is employed, PPP authentication must be configured. The name should be the same as the
hostname sent from the remote end.
3. If the dynamic routing is configured, the option broadcast must be added behind name hostname.
4. The command dialer map and dialer string can’t be used simultaneously.
5. The command dialer map and the keyword name are needed in the dialer callback.
5RXW HU e o 0RGHP
3671
5RXW HU e
o
6
6
Illustration:
1. Router-1, Router-2 and Router-3 connects with each other through the outer MODEM and PSTN dialer.
The configuration of router1 s1 and the DDR relevant configuration are as follows:
Command Task
2.During the course, after the route1 dials on the outer modem of the route2 and constructs an access to the
route2, if there is no data sent through the s1 within 100 seconds (namely exceeding the value of idle-
timeout), the router1 will trigger modem1 to automatically disconnect the connection with the modem2 of the
route2. Within the idle time, if the route1 receives the data stream to trigger calling the route3, the timer fast-
idle will start. Within the 30 seconds the timer fast-idle times, if there is no data sent to the route2 through the
s1, the route1 will disconnect the connection with the route2 and call the route3.
3.For the answer, it should be configured as the authentication originator. At the moment of callback, two same
names can not be configured in dialer map on the side of callbacker. Besides the above, of course, the same user
name with that on a Cisco router can not also be configured at the time of authentication.
The serial 2 of the router router-A connects to an outer modem, chooses the asynchronous mode, encapsulates the
PPP protocol (using chap authentication), is used as a backup interface and a caller and start the script of the modem:
at&f&k3%c3&c1. The serial port 0 is used as the master interface, encapsulates the HDLC protocol. The dialer adopts
the dialer map mode.
The serial 2 of the router router-B connects to an outer modem, chooses the asynchronous mode, encapsulates PPP
protocol, is used as a backup line to the serial 0 and a answer uses the script of the modem: at&f&k3%c3&c1. And the
static routing is adopted between routers.
The detailed configuration is as follows:
6
6
5RXW HU e o$
:$1
6 6
5RXW HU e o%
&DO O $FNQRZO HGJH
0RGHP 3671
Illustration:
Router-A and Router-B connect with each other through their own s0, while their own s2 connects the outer modem,
which serves as a backup line to the interface s0.
Command Task
router-A#con t
router-A(config)# Configures the opposite terminal as a local
user answer pass 0 Maipu user and configure its password, which must
be the same as the user password configured
by the opposite terminal (namely the chap
authentication password sent by the opposite
terminal).
router-A(config)# Configures the packets triggering dialer.
dialer-list 1 protocol ip permit
router-A(config)# Establishes the MODEM dialer script.
chat-script m-con at&f&k3%c3&c1 The script name: m-con;
The script contents: at&f&k3%c3&c1
router-A(config)# int f0
router-A(config-if-fastethernet0)# ip address 195.168.1.3
255.255.255.0
router-A(config-if-fastethernet0)#exit
router-A(config)#int s0
router-A(config-if-serial0)#phy sync
router-A(config-if-serial0)# encapsulation hdlc
router-A(config-if-serial0)#
ip address 128.255.1.1 255.255.0.0
router-A(config-if-serial0)# Uses the serial S2 as the backup line to the
backup interface serial2 interface s0.
router-A(config-if-serial0)# Set a 5-second delay on activating the
backup delay 5 20 secondary line after the primary line goes
down and set a 20-second delay on
deactivating the secondary line after the
primary line comes up
router-A(config-if-serial0)#exit
router-A(config)#int s2
router-A(config-if-serial2)# physical-layer async
router-A(config-if-serial2)#
ppp authentication chap
router-A(config-if-serial2)#
ppp chap hostname caller
router-A(config-if-serial2)# ip address 192.255.255.1
255.255.255.0
Command Task
Noticeable points:
z If the modem does not dial up, users should examine whether cables are connected correctly, should make sure that
the modem has been turned on, it has been configured as the mode the modem can accept the AT commands and
that it has connected reliably with the correct interface.
z When users try to open the dialer connection but the modem has no response to the access request, users should
examine whether the remote modem is configured as auto-answer or the AT command mode. They should make
sure that the remote modem has been connected to the router or to other equipment. When necessary, they can also
examine whether there is a dialer sound on the telephone line.
z If a modem can not accept an answer or send call correctly, users can also examine whether the modem script is
configured correctly through the command debug modem interface.
z When the dialer backup interface does not dial up, then dcd is down, but its flag Flags is often in the status of up
(spoofing). However, at the moment, the interface is not up really. Only when the primary line goes down and
there is data to trigger, then the dialer backup interface can dial. When it is connected correctly, the flags will be in
the status of up.
6.2.2 Dialer Callback
PPP reverse callback provides a kind of client/server relation between the two ends connected in terms of the point-to-point
mode. The function of PPP reverse callback permits the router to ask the opposite terminal router connected by dialer to call
back. The feature can be used to control access and save the charge of the remote call between routers.
2. The reverse callback server determines the reverse callback request and examines the configuration of itself to validate
whether the reverse callback is employed.
3. The reverse callback client and server process the authentication through CHAP or PAP. A user name is used to
distinguish the dialer string used by the callback.
4. After the success of the first authentication, the router used as the reverse callback server will distinguish the dialer
string used by the reverse callback. The reverse callback server compares user names with the host names in the dialer-
mapping list.
5. If “dialer callback-secure” is not started, the reverse callback server will maintain the initial call when the reverse
callback isn’t configured for the authenticated user name; or else, the reverse callback server will hang up the initial call.
6. The reverse callback server uses a dialer string to originate a reverse callback. If it fails, it will not try to call again.
During the course of returning a call back, the reverse callback does not process LCP negotiation of PPP.
7. Process to call.
8. Keep on connecting.
Note:
If the caller requests to process reverse callback but the server is not be configured to accept a reverse callback, then the
answer router will maintain the initial call originated by the caller.
Command Description
Command Description
Illustration:
1. The routers Router-A and Router-B connect with each other through PSTN network. The Router-A is a dialer
requester the Router-B is a callbacker. The telephone number of the Router-A is 8001 and the number of the
Router-B is 8002.
2. The router Router-B is used as the dialer server in this example.
Note:
1. The callbacker must be configured as the chap originator.
2. Two same names can’t be configured in the dialer map of the callbacker because a callback decides its callback
object according to name and the same names will lead that the numbers needed to call back can’t be identified.
3. The function of broadcast in dialer map is to let the dynamic routing pass.
%5,
%5,
, 6'1 &DO O
17
17
, 6'1
5RXW HU e o$
5RXW HU e o%
The following is the configuration of the router-A, which adopts the dialer map and ppp chap authentication.
The configuration of router-A:
Command Task
Command Task
router(config)#hostname router-B
router-B(config)#user router-A password 0 Maipu
router-B(config)#dialer-list 1 protocol ip permit Configures a dialer-group.
router-B(config)#interface fastethernet0
router-B(config-if-fastethernet0)#
ip address 130.255.252.10 255.255.255.0
router-B(config)#exit
router-B(config)#interface bri0
router-B(config-if-bri0)#encapsulation ppp
router-B(config-if-bri0)#ppp authentication chap Configures CHAP authentication.
router-B(config-if-bri0)#ppp chap hostname router-B Configures the name of CHAP authentication.
router-B(config-if-bri0)#
ip address 192.168.1.2 255.255.255.252
router-B(config-if-bri0)#dialer idle-timeout 60 Configures idle time.
router-B(config-if-bri0)#dialer enable-timeout 5
router-B(config-if-bri0)# Configures the mapping of dialer.
dialer map ip 192.168.1.2 name router-A
router-B(config-if-bri0)#dialer-group 1 Configures the trigger dialer-group1.
router-B(config-if-bri0)#exit
router-B(config)#ip route 128.255.252.0 255.255.255.0
192.168.1.1
Note:
1. The static routing commands of the router-A defines the IP routing of the 130.255.252.0 network connecting to
the LAN interface inter f0 of the router router-2.
2. Interesting packet can be defined as any IP packet, and they can originate the calls to router-B.
3. Router-B is defined to accept calls through the command dialer map. There is the static routing to LAN of the
router router-A on it.
2) Debugging and monitoring
Monitoring an interface
· Display the information of the ISDN BRI interface. The used command is as follows:
router#sh int bri0
Displaying the information of the ISDN BRI interface
bri (unit number 0):
Flags: (0x8071) UP(spoofing) POINT-TO-POINT MULTICAST ARP RUNNING
Type: PPP
False up
status
Internet address: 192.168.1.1
Netmask 0xffffff00 Subnetmask 0xfffffffc
Destination Internet address: 0.0.0.0
Metric is 0
Maximum Transfer Unit size is 1500
0 packets received; 0 packets sent
0 multicast packets received
0 multicast packets sent
0 input errors; 0 output errors
0 collisions; 0 dropped
rxFrames: 0, rxChars 0
txFrames: 0, txChars 0
rxNoOctet 0, rxAbtErrs 0, rxCrcErrs 0
rxOverrun 0, rxLenErrs 0, txUnderrun 0
DCD=down DSR=down DTR=up RTS=up CTS=down Txc=up
Here, although it can be seen that the DCD signal and DSR signal of the physical layer are DOWN, the interface is still UP.
The reason is that the technique called false UP (namely spoofing) is adopted in DDR. This word indicates that the line need
not be UP but a dialer port still forces it to be false UP. In this way, the interface can dial on demand to route its packets. All
dialer interfaces have this feature.
Display the information about some channel status of ISDN, the second layer and the third layer. The command is as follows:
router#sh isdn status
Displays the information about ISDN status
ISDN BRI0 interface
Layer 1 Status:
F7
Layer 2 Status:
TEI = 67 Ces = 01 SAPI = 00 Status = ST_MULTIFR
I-Frame: 0/0 RR: 5/5 RNR: 0/0 REJ: 0/0
SABME: 1/0 DM: 0/0 DISC: 0/0 UA: 0/1
FRMR: 0/0 TEI: 59/1
B1 channel:
Tx Frames = 0 Tx Bytes = 0, Tx Errors = 0
Rx Frames = 0 Rx Bytes = 0
B2 channel:
Tx Frames = 0 Tx Bytes = 0, Tx Errors = 0
Rx Frames = 0 Rx Bytes = 0
In this common situation, as long as the ISDN module of the router connects with the ISDN switch correctly, the command
show isdn status can be used to see that the second layer is of ST_MULTIFR status, which indicates that the D channel is
active.
Noticeable points:
When ISDN can not achieve the connection with the opposite terminal, please check the following details:
1) Whether ISDN of the router is in ST_MULTIFR status.
2) Whether the B channel to be used by ISDN of the router is being used by other ISDN equipment.
3) Whether the called side is being used.
4) Besides these, the above debugging commands are used to examine whether the configuration is correct.
The dialer prototype separates logical interfaces from the ones answering for sending and accepting calls. In the dialer
prototype, a physical interface and a logical interface are bound together according to each call, so that the different
parameters of the physical interface can be chosen dynamically. The prototype separates the logical part of DDR, such as
network layers, encapsulation, and the parameters relative to dialer, from the physical interfaces answering for sending and
accepting calls.
The diagram below establishes a relation between the parameters of the dialer prototype. The necessary configuring
commands are listed below the diagram as well:
Dialer pool-member
Command Description
Command Description
Dialer idle-time seconds Prescribes the clock value of the idle timeout used
by dialer, and the default is 120s.
Dialer fast-idle seconds Prescribes all the clock value of the fast idle
timeout, and the default is 20s.
Dialer wait-for-carrier-time seconds Prescribes the time used to wait for carrier waver.
If no carrier waver is examined, the call will be
discard.
A physical interface can belong to several dialer pools, and priority (Optional) can be configured for the physical interfaces
included in the dialer pool to decide the sequence for choosing the interfaces.
Command Description
Dialer pool-member number The parameter “number” is the number of the dialer
pool and is a decimal number within the range from
1 to 255.
Prilrity priority Configures the priority of the physical interfaces in
the dialer pool. Choosing the interface with high
priority to dial.
ppp authentication chap Configures authentication.
Note:
1. Authentication needs to be configured on the physical interface;
2. The interface dialer of the dialer prototype supports PPP protocol presently.
0RGHP
0Se o MP2600 - 1
0Se o MP2600 - 3
3671 0RGHP
0RGHP
0Se o MP2600 - 2
Illustration:
1. In this figure, the router MP2600-1 connects with MP2600-2 and the MP2600-3 through a physical interface. You
can use two dialer map of DDR to configure it. Of course, you can also choose our flexible DDR (dialer prototype) to
achieve this function. In such a small network, you may not feel the flexibility of the dialer prototype. But you will feel it in a
large one because you can configure different parameters on different dialer interfaces so as to achieve different dialer aims
without dialing circularly.
Command Task
Note:
1. In a large dialer network, you can use the dialer prototype to configure many dialer interfaces (dialer interface).
2. The ISDN network also supports the dialer prototype, and it can employ PPP multilink to bind many ISDN
interfaces.
Chapter 7 Routing Configuration
This chapter introduces routing mechanisms and how to apply many kinds of mainstream routing protocols, such as Routing
Information Protocol (RIP), Internal Routing Message PrococolÄIRMPÅ,Open Shortest Path First (OSPF), to configure a
Maipu router to achieve a network interconnection.
A route further divided into another two kinds depending on whether a router is connected to a destination directly or not.
A route is also divided into two kinds according to how the routes are generated
Very often there are several routes to the same destination. A router uses a set of rules to select the optimal route. The rules
used by a router to select an optimal route to share the network accessibility and state with other routers is called a routing
protocol. A routing protocol contains at the following four parts:
Command Description
Note:
1. Using the command no ip route to delete a static route
router(config)#no ip route A.B.C.D mask a.b.c.d/interface
2. In practical applications, the configuration of the static route had better adopt the IP address of the next hop. In
a point-to-multipoint network (for example, X.25 and FR), the configuration must adopt the IP address of the next hop.
The network interface configured to transmit can be only fit for the point-to-point link (for example, HDLC).
B. The following methods can also be used to configure the administrative distance of the static route.
router(config)#
Command Description
distance number Configures the administrative distance, of which number is a number within the
range from 1 to 255. The form no distance can be used to delete the configured
administrative distance.
Command Task
Command Description
router(config)#ip route 0.0.0.0 0.0.0.0 A.B.C.D A.B.C.DæIndicating the default gateway IP address
Note:
1. The default route configuration of the router is to permit IP route transmission. But in some special
situations, users can prohibit the routing function, which can be achieved in the global configuration mode
through the following command to prohibit IP route transmission:
router(config)#no ip routing
In the global configuration mode, the following command can be used to permit IP route transmission:
router(config)#ip routing
The no form of this command is used to delete a default route
Command Description
Overview
Routing Information Protocol (RIP) exchanges routing updates through broadcasting UDP packets. A router sends out
routing updates every 30 seconds, which is called a notification. If a router does not receive any routing updates from
another router within 180 seconds or more, the routing signal related to that router is disabled. If the router does not receive
any routing updates within 240 seconds after this, the router will delete all routes related tho that route from its routing table.
RIP provides a metric, which is called a hop count, to scale different routing distances. Hop count is the number of routers
passing through a route. The hop count of a directed network is 0, while the hop count of an unreachable network is 16.
If a router has a default route, RIP will notify the route from the router to a virtual network 0.0.0.0 which does not exist.
RIP takes 0.0.0.0 as a network to deal with the default route.
RIP sends routing updates to the interface of the specified network interfaces. If the interfaces are not specified to a
network, no RIP updating information will be sent out.
RIP (Routing Information Protocol) is a kind of distance vector routing protocol serving as the routing of the mini, simple
network. This section mainly describes how to configure Maipu Router RIP to interconnect networks.
Command Description
Command Description
network network-number Associates the network with the RIP routing process.
Restrains route update of the interface, so that this interface can
passive-interface interface-name only accept the route update information sent from the other
routers but can’t send any route update information.
redistribute protocol-name [{as- Configures the route redistribution (you can choose: direct
num|process-id}] [metric metric] connection, IRMP, ospf, static route).
timers basic update invalid holddown
flush Adjusts the timer.
Note:
1. Similarly, the command no can be used to prohibit the usage of the above commands.
2. The default mode of the version 1 is auto-summary and belongs to the generic routing protocol.
3. The default mode of the version 2 is no auto-summary and supports subnet partition.
router(config-if-xxx)#
Command Description
Illustration:
See the figure above, the RIP authentication is configured only between RouterA and RouterB. And other configurations
are omitted.
Note:
1) The goal of configuring version transmitting/receiving is to realize the interaction of route information among
different versions of RIP.
2) As shown in figure above, there exists no change of the configuration of RouterA; RouterB and RouterC run RIP
(Version 1). And the other configuration except the following configuration is the same for RouterB and RouterC.
A) RouterB is configured as follows.æ
Syntax Descriptions
RouterB#configure terminal Enter the global configuration mode.
RouterB(config)#router rip Enter the RIP configuration mode.
RouterB(config-rip)#version 1 Configure the RIP version.
RouterB(config-rip)#interface s1/0 Enter the interface configuration mode.
RouterB(config-if-serial1/0)#ip rip send version 2 Transmit RIP V2 on the interface s1/0.
RouterB(config-if-serial1/0)#ip rip receive version 2 Receive RIP V2 on the interface s1/0.
RouterB(config-if-serial1/0)#exit Exit.
Command Description
Open Shortest Path First (OSPF) is an internal gateway protocol (IGP) used to determine a route in a single Autonomous
System (AS). It is more complex, powerful, widely used anmd efficient than RIP. This section describes how to configure
OSPF dynamic route protocol for a Maipu router to interconnect networks.
network A.B.C.D a.b.c.d area Configures the OSPF process and designate the OSPF interface.
area_num ÔA.B.C.D Use the network number of OSPF process.
a.b.c.d inverse-mask
area_num area numberÕ
Note:
1. After the OSPF process is created, the process does not know which interface or network it enters; however, it can
solve this problem through the command network. This command can designate an interface to a given area
simultaneously. The following command can be used to designate the match interface to the area 0:
router (config-ospf)#network 128.255.0.0 0.0.255.255 area 0
In the command network, all the interfaces capable of matching the pair of the addresses and the inverse mask will be
placed into a given area. 0 represents the placeholder, and 1 represents an arbitrary match.
2. The command network has the function of auto-route summary.
3. When the command network can match at least one interface address, the OSPF process runs. When the last
command network is canceled (by running the command no network…), the OSPF process will be deleted.
Command Description
cost reference-bandwidth Configures the bandwidth value to count charge (choosing in the
<1_4294967> parameter range from 1 to 4294967).
default Configures the default instruction.
Filters the route (the parameter is used to designate the number of
distribute-list <1_1000>
the standard access list to be filtered).
Configures the neighbor router (configuring neighbor at the time
neighbor ip-address
of NBMA).
passive-interface <interface number> Restrains a port from OSPF addressing.
redistribute<bgp connected irmp Configures the route redistribution (you can choose: direct
rip snsp static> connection, IRMP, RIP, static route).
router-id Configures OSPF router-id in IP address format
Note:
1. Similarly, the command NO can be used to prohibit the usage of the above command.
2. Configure the neighbor router:
In order that the OSPF router can be configured to interconnect to a no-broadcasting network, the command can be
used to configure a neighbor. In the neighboring address, ip-address is the IP address of the neighboring interface.
Command Description
Note:
1. On the protocol port of PPP and HDLC, the default type of OSPF network is point-to-point.
2. On the protocol port of frame relay and X25, the default type of OSPF network is non-broadcast.
Noteæ
Should reset OSPF proces with Clear command to make router-id command become effective.
7.4.2 STUB/NSSA/Route-Summary/Virtual-Link/Demand-Circuit Configuration Commands
area stub
Use the router configuration command area stub to configure the OSPF stub-area; otherwise, use the command no area
stub to disable the function.
area area_id stub
no area area_id stub
Syntax Descriptions
area_id The area-number of the stub-area. Its value range is from 0 to
4294967295 or an IP address is used to identify the stub-area.
£By default¤No area is configured as the stub area.
£Command mode¤the OSPF protocol configuration mode.
£Guide¤No category 5 LSA, namely the external LSA, can be received or transmitted in the stub area. The
neighborship among routers can not be established until the command is configured on all the routers in the stub area.
Note:
1) When a stub area is configured, the area number can not be the backbone area number. That is to say that the area
number can not be 0.
2) To cancel the stub area specified in the configuration, use the command no area area_id stub.
area nssa
An nssa area is similar to an OSPF stub area. Category 5 LSA can not be diffused from the backbone area to the nssa
area, but the external route of autonomous system can be introduced into the area by means of finite forms.
By means of redistributing category 7 AS route introduced into the nssa area, nssa can convert the category 7 external
LSA to category 5 external LSA, which will be flooded to other areas of the autonomous system through the border router in
the nssa area.
Use the command area nssa to configure an area as an nssa area (not-so-stubby area); otherwise, use the command no
area nssa to cancel the attribute nssa of the area.
area area_id nssa
no area area_id nssa
Syntax Descriptions
area_id The area-number of the nssa area. Its value range is from 0 to 4294967295
or an IP address is used to identify the nssa area.
£By default¤No area is configured as the nssa area.
£Command mode¤the OSPF protocol configuration mode.
£Guide¤An nssa area is similar to a stub area. Category 5 LSA can not be diffused from the backbone area to the nssa
area, but the external route of autonomous system can be introduced into the area by means of finite forms.
Note:
1) The backbone area can not be configured as the nssa area.
2) Any router in the same area must support nssa area, or else the neighborship among the routers can not be established.
3) If it is possible, try not to adopt the explicit redistribution on nssa abr because the packets converted by the router are
confused easily.
area range
Use the command area range to realize the route summary of areas; otherwise, use the command no area range to
disable it.
area area_id range address mask
no area area_id range address mask
Syntax Descriptions
area_id The OSPF area number. And its value range is from 0 to 4294967295.
address The network IP address.
mask The network IP address.mask
£By default¤No route summary area range is configured.
£Command mode¤the OSPF protocol configuration mode.
£Guide¤Route summary is a set of routes generated by the area border router and the AS border router and will be
announced to the neighbor routers. If network numbers in an area is successive, the area border router and the AS border
router can be configured to announce the route summary that specifies the range of network numbers. The route summary can
reduce the size of link-state database. The OSPF route summary can be classified into inter-area route summary and external
route summary. After configured with the command area range, the area border router summarizes the routes in the
configured network segment and generates a route profile summary net lsa, which is notified by the area border router to
other areas, and lsa in the network segment will not be notified any more.
Note:
1) The command area range can take effect on nothing but the area border router.
2) Use the command no area range to cancel the command route summary.
summary-address
Use the command summary-address to perform OSPF external route summary; otherwise, use the command no
summary-address to make the command out of work.
summary-address address mask [tag tag-value]
no summary-address address mask [tag tag-value]
Syntax Descriptions
address The network IP address.
mask The network IP address mask
tag-value The tag-value of the summarized ase lsa. And its value range is from 0 to
4294967295
£By default¤No the command summary-address is configured.
£Command mode¤the OSPF protocol configuration mode
£Guide¤When the route is redistributed from other protocols to OSPF, each route is singly announced in the external
link-status announcement. The command summary-address is used to summarize all redistributed routes covered by the
special network address and mask as one route. In this way, the size of OSPF link-state database can be reduced. Use the
command summary-address to summarize external routes. And the command is used to summarize all ase lsa in the
network segment and generate a summary ase lsa. Only the summary ase lsa is announced to other routers through ASBR.
Note:
1) The command can take effect on nothing but ASBR and summarize the external routes redistributed by OSPF.
2) Use the command no summary-address to cancel the summary command of the external route.
Note:
1) The router configured with the virtual-link should be an area border router.
2) The virtual-link is identified by router-id of the router on the other end.
3) The two end routers configured with the virtual-link must be located in the same public area that is called virtual-link
transit area.
4) The virtual-link can be regarded as one part of the backbone area or as unnumbered point-to-point network. Its cost is
the spending of the link and can not be configured.
5) Use the command no area virtual-link to cancel the link configuration command
6) The virtual-link can not be configured through the stub area. That is to say that the virtual-link transit area can not be
the stub area.
7.4.3 Examples of OSPF configuration
6
6
333 +'/&
6 6
6 )U DPH
6
U HO D\
U RXW HU U RXW HU
(W KHU QHW
(W KHU QHW
Illustration:
1. In the above figure of configuration example, a PPP link runs between router-1 and the interface serial1 of router-2,
Frame Relay runs between the interface serial0 of router1 and the interface serial1 of router3, and HDLC link runs between
the router2 and the interface serial0 of router3.
2. During the course of configuring OSPF dynamic routing protocol for a Maipu router to connect, the following tasks
should be completed:
router-3(config)#int s0
router-2(config-if-serial0)#ip ospf network point-to-point
router-2(config-if-serial0)#exit
router-2(config)#int s1
router-2(config-if-serial1)# ip ospf network point-to-point
router-2(config-if-serial1)#end
router-3(config)#int s1
router-3(config-if-serial1)# ip ospf network non-broadcast
router-3(config-if-serial1)#exit
router-3(config)#int s0
router-3(config-if-serial0)# ip ospf network point-to-point
router-3(config-if-serial0)#exit
router-3(config)#int f0
router-3(config-if-fastethernet0)# ip ospf network broadcast
router-3(config-if-fastethernet0)#end
B: An Example to configurate the area virtual-link
U RXW HU
V
V
+'/&
333 $5($
V V
9L U W XDO O L QN
U RXW HU U RXW HU
$5($ $5($
(W KHU QHW
(W KHU QHW
Illustration:
1. In the above figure of configuration example, a PPP link runs between router-1 and the interface serial1 of router-2 ,and
HDLC link runs between the router2 and the interface serial0 of router3.s1 of router-1 and router-2 and s0 of router-3 are
belong to area 3,ethernet 1 of router-1 and ethernet2 of router-3 belong to are belong to backbone,but without physical link
between them. So we configuire virtual link for combine backbone.
2. During the course of configuring OSPF dynamic routing protocol for a Maipu router to connect, the following tasks
should be completed:
router-2(config)#int s1
router-2(config-if-serial1)# ip ospf network point-to-
point
router-2(config-if-serial1)#end
router-2(config-ospf)#exit
router-3(config)#int s0
router-3(config-if-serial0)# ip ospf network point-to-
point
router-3(config-if-serial0)#exit
Command Description
router irmp autonomous-system Enters the IRMP route configuration mode (Autonomous
System number)
Runs IRMP on an interface within the designated network
network network-number [wild-mask] range. Network number, inverse-mask
Note:
IRMP routing protocol supports many ASes (Autonomous system) and they can run independently without disturbing
each other. The interface running IRMP can send/accept IRMP messages; however, if the interface has not been designated,
then it can not send/accept IRMP messages, and its route can not be sent from any other interface.
B. Entering the IRMP route configuration mode
router(config-irmp)#?
Command Description
Note:
1. Similarly, the command NO can be used to prohibit the usage of the above commands.
router(config-if-xxx)# ?
Command Description
Note:
1. When the IRMP MD5 authentication mode is configured, it must be authenticated, and the key_id of the two ends
must be congruous; 0 in the command indicates plaintext input while 7 indicates cryptograph input.
2. Configuring the interval between HELLO messages and the neighbor hold-time can be
described as follows:
The default IRMP sends HELLO messages at 5 second intervals on a broadcasting interface or a point-to-point
one, or at 60 second intervals on a NBMA interface. After accepting the HELLO messages, it will add the opposite
terminal router to the neighboring table of itself. If the neighbor already exists in the neighbor table, the neighboring
hold-timer will refresh. If the default IRMP , in the hold time, has not accepted any HELLO message sent by a
neighbor all along, it will think that the neighbor has be invalidated and it will be deleted from the neighbor table. The
default hold time will be 3 times the length of the hello time.
V
,3
1HW ZRU N
V
PDL SX
Mai
I
Illustration:
1. In the configuration above, the router cisco in the above figure is a Cisco router while Maipu is
a Maipu Router. During the course of configuring the IRMP dynamic routing protocol on a
Maipu router and CISCO router to connect each other, the following tasks should be finished.
A) Establishing IRMP process
B) Routing filtering /routing redistribution
cisco(config-router)#end
Command Description
Noticeable points:
o debug ip irmp packets terse displays the messages including the routing information except HELLO. debug
ip irmp packets terse detail displays the detailed information of each route.
SNSP (Stub Network Search Protocol) uses Neighbor Device Search Protocol (NDSP),a protocol used to discover other
devices on either broadcast or non-broadcast media, to propagate the connected IP prefix of a stub router. SNSP was
designed for customers who do not want to usr network bandwidth for routing protocol updates.Static routing is a good
choice,but there is too much overhead to manually maintain th static route.SNSP is not CPU-intensive and is used when IP
routes are propagated dynamically on Layer2. SNSP is a perfect solution for hub and spoke topology.
Commmand Description
5
I
I I I
5 5 5
Illustration:
1. The router R2 serves as a hub router. It is configured with SNSP and IRMP routing protocols, and executes
NDSP.
2. The low-end routers, R3, R4 and R5 run NDSP and are configured with the default route without the dynamic
route.
B. The configuration of the Maipu router R3 (the configuration of R4 or R5 is the same as that of R3)
Command Task
R3#configure terminal
R3(config)# ndsp run Runs NDSP.
R3(config)#ip route 0.0.0.0 0.0.0.0 fastethernet0 Configures the default route.
R3(config)#end
Noteö
ö
Note:
If no group_number is specified in the command, its default value is 0.
standby preempt
The command is used to specify whether the standby group enables VBRP preempt.
standby [group-number] preempt [delay time]
no standby [group-number] preempt
Syntax Description
group_number Specify a VBRP group_number whose
value range is from 0 to 255.
time Specify the preempt delay time (by
second), and its value range is from 0 to
3600.
£By default¤Non-preempt mode is enabled.
£Command mode¤the interface configuration mode
Note:
1) If no group_number is specified in the command, its default value is 0.
2) If no delay time is configured for preempt, the system will take preempt at once.
standby priority
The command is used to configure a priority for the standby group.
standby [group-number] priority priority
no standby [group-number] priority
Syntax Description
group_number Specify a VBRP group_number whose
value range is from 0 to 255.
priority Specify a priority whose value range is
from 0 to 254.
£By default¤priorityæ100.
£Command mode¤the interface configuration mode
Note:
1) If no group_number is specified in the command, its default value is 0.
standby timers
The command is used to specify Hello-time and Hold-time for the standby group.
standby [group-number] timers hello-time hold-time
no standby [group-number] timers
Syntax Description
group_number Specify a VBRP group_number whose
value range is from 0 to 255.
hello-time Specify the period of sending Hello
packet, and its value range is from 0 to
254.
hold-time Specify the hold-time of Hello packet (by
second), and its value range is from 4 to
255.
£By default¤hello-timeæ3 secondsØhold-time: 10 seconds
£Command mode¤the interface configuration mode
Note:
1) If no group_number is specified in the command, its default value is 0.
standby track
The command is used to specify a monitoring interface for the standby group.
standby [group-number] interface [decrement]
no standby [group-number] interface [decrement]
Syntax Description
group_number Specify a VBRP group_number whose
value range is from 0 to 255.
interface Specify an interface for monitoring.
decrement Specify the priority decrement, and its
value range is from 1 to 255.
£By default¤No interface is monitored.
£Command mode¤the interface configuration mode
Note:
1) If no group_number is specified in the command, its default value is 0.
no standby
The command is used to close the standby group.
no standby [group-number]
Syntax Description
group_number Specify a VBRP group_number whose
value range is from 0 to 255.
£By default¤The standby group is not enabled.
£Command mode¤the interface configuration mode
Note:
1) If no group_number is specified in the command, its default value is 0.
, QW HU QHW
U RXW HU U RXW U
3& 3&
Illustration:
As shown in figure above, pc1 and pc2 connect with Internet respectively through router1 and router2, and their default
gateways are respectively 129.255.123.100 and 129.255.123.16.
The basic VBRP configuration is listed as follows:
A) Router1 is configured as follows:
Command Task
router1#configure terminal Enter the global configuration
mode.
router1(config)#interface fastethernet0 Enter an Ethernet interface.
router1(config-if-fastethernet0)#ip address 129.255.123.21 255.255.0.0 Configure an IP address.
router1(config-if-fastethernet0)#standby 1 ip 129.255.123.100 Configure VBRP group-number
and virtual IP address.
router1(config-if-fastethernet0)#standby 1 priority 110 Set the VBRP priority.
router1(config-if-fastethernet0)#standby 1 preempt delay 10 Set the preempt mode and set the
delay time as 10 seconds.
B) Router2 is configured as follows:
Command Task
router2#configure terminal Enter the global configuration
mode.
route2(config)#interface fastethernet0 Enter an Ethernet interface.
router2(config-if-fastethernet0)#ip address 129.255.123.22 255.255.0.0 Configure an IP address.
router2(config-if-fastethernet0)#standby 1 ip 129.255.123.100 Configure VBRP group-number
and virtual IP address.
router2(config-if-fastethernet0)#standby 1 preempt delay 10 Set the preempt mode and set the
delay time as 10 seconds.
7.7.3 Monitoring and Debugging VBRP
show standby
The command is used to display all local VBRPs.
show standby [all]
£Command mode¤the privileged user mode
Noteö
ö
The command show standby can be only used to display the local configured VBRP groups. And the command show
standby all is used to display the local configured VBRP groups besides the groups learned from other routers.
debug standby errors
The command is used to display or close the information about VBRP operation error, such as unsuccessful
authentication and unauthorized version.
debug standby errors
no debug standby errors
£Command mode¤the privileged user mode
debug standby events
The command is used to open the information debugging switch of VBRP event. And the negation of the command is
used to close the debugging switch.
debug standby events [{api|protocol|track}]
no debug standby events
Syntax Description
api Debug API information.
protocol Debug protocol information.
track Debug interface track information.
£Command mode¤the privileged user mode
Noteö
ö
The command debug standby events is used to open all information debugging.
debug standby packets
The command is used to open the information debugging switch of VBRP packet. the negation of the command is used
to close the function of VBRP packet debugging.
debug standby packets [{coup|detail|hello|resign|terse}]
no debug standby packets
Syntax Description
coup Debug coup packet.
detail Display the detailed contents of a packet.
hello Debug Hello packet.
resign Debug Resign packet.
terse Debug coup/resign packet.
£Command mode¤the privileged user mode
Note:
The command debug standby packets is used to open information debugging of all packets.
Noteö
ö
A virtual IP address and a primary address of the interface must be in the same network segment.
Vrrp authentication
The command is used to enable/disable vrrp simple text authentication.
Ip vrrp vrid authentication text string
no ip vrrp vrid authentication
Syntax Description
vrid Specify a vird number whose value range
is from 1 to 255.
string The authentication password. The
maximal length is 16 (by character).
£By default¤The authentication is enabled.
£Command mode¤the interface configuration mode
Noteö
ö
The command can not be configured until VRRP is enabled.
Vrrp preempt
The command is used to enable/disable vrrp preempt.
Ip vrrp vrid preempt
no ip vrrp vrid preempt
Syntax Description
vrid Specify a vird number whose value range
is from 1 to 255.
£By default¤the vrrp preempt is disabled.
£Command mode¤the interface configuration mode
Noteö
ö
Noteö
ö
Noteö
ö
The command can not be configured until VRRP is enabled.
Vrrp interface monitoring
The command is used to configure the interface vrrp monitors.
Ip vrrp vrid track interface [decrement]
no ip vrrp vrid track interface
Syntax Description
vrid Specify a vird number whose value range
is from 1 to 255.
interface Specify an interface for monitoring.
decrement Specify the priority decrement.
£By default¤An interface is not be monitored.
£Command mode¤the interface configuration mode
Noteö
ö
, QW HU QHW
U RXW HU U RXW U
3& 3&
Illustration:
As shown in figure above, pc1 and pc2 connect with Internet respectively through router1 and router2, and their default
gateways are respectively 129.255.123.100 and 129.255.123.16.
The basic configuration of VRRP is described as follows:
A) Router1 is configured as follows:
Command Task
router1#configure terminal Enter the global configuration
mode.
router1(config)#interface fastethernet0 Enter an Ethernet interface.
router1(config-if-fastethernet0)#ip address 129.255.123.21 255.255.0.0 Configure an IP address.
router1(config-if-fastethernet0)#ip vrrp 1 ip-address 129.255.123.100 Configure VRRP group-number
and virtual IP address.
router1(config-if-fastethernet0)#ip vrrp 1 priority 110 Set the VRRP priority.
B) Router2 is configured as follows:
Command Task
router2#configure terminal Enter the global configuration
mode.
route2(config)#interface fastethernet0 Enter an Ethernet interface.
router2(config-if-fastethernet0)#ip address 129.255.123.22 255.255.0.0 Configure an IP address.
router2(config-if-fastethernet0)# ip vrrp 1 ip-address 129.255.123.100 Configure VRRP group-number
and virtual IP address.
5 6
3671
C ISCOS YSTEMS
0RGHP
/
6 5
CISCOS YSTEMS
0RGHP
/
As shown in figure above, the interface S1/0 of the router R1 connects with the interface of router R2 through PSTN. The
RIP routing protocol is enabled on the link, snapshot routing is used to realize that the route information can be exchanged
only in the active-time, and the RIP protocol is used to discover the route from the opposite end to the loopback interface L0.
R1 serves as the snapshot routing client, and R2 serves as the snapshot routing server. The related configuration is described
as follows:
R1 is configured as follows:
Command Task
In the global mode
R1(config)#router rip Configure the RIP protocol.
R1(config-rip)#network 1.0.0.0
R1(config-rip)#network 4.0.0.0
R1(config-rip)#exit
R1(config)#ip access-list extended 1001 Define DDR triggering data flow, shield
R1(config-ext-nacl)# deny ip any host 255.255.255.255 broadcast and multicast packets so that
R1(config-ext-nacl)# deny ip any 224.0.0.0 0.255.255.255 they have no way to trigger DDR dialup.
R1(config-ext-nacl)# permit ip any any
R1(config-ext-nacl)# exit
R1(config)#dialer-list 1 protocol ip list 1001
In the interface configuration mode.
R1(config-if-serial1/0)#ip add 1.1.1.1 255.255.255.0 Configure related DDR operations, and
R1(config-if-serial1/0)#dialer in-band set phone number and IP address.
R1(config-if-serial1/0)#dialer-group 1
R1(config-if-serial1/0)#dialer string 602
R1(config-if-serial1/0)#phy async Configure the modem (The ISDN dialup
R1(config-if-serial1/0)#speed 115200 mode can also be adopted. About related
R1(config-if-serial1/0)#modem outer configuration, refer to sections related
with interface configuration)
R1(config-if-serial1/0)#snapshot client 5 600 dialer Enable the Snapshot client, set active-
time and quiet-time respectively as 5
minutes and 8 minutes.
R2 is configured as follows:
Command Task
In the global configuration mode.
R2(config)#router rip Configure the RIP protocol.
R2(config-rip)#network 1.0.0.0
R2(config-rip)#network 5.0.0.0
R2(config-rip)#exit
R1(config)#ip access-list extended 1001 Define DDR triggering data flow, shield
R1(config-ext-nacl)# deny ip any host 255.255.255.255 broadcast and multicast packets so that
R1(config-ext-nacl)# deny ip any 224.0.0.0 0.255.255.255 they have no way to trigger DDR dialup.
R1(config-ext-nacl)# permit ip any any
R1(config-ext-nacl)# exit
R1(config)#dialer-list 1 protocol ip list 1001
In the interface configuration mode
R1(config-if-serial1/0)#ip add 1.1.1.2 255.255.255.0 Configure related DDR operations, and
R1(config-if-serial1/0)#dialer in-band set phone number and IP address.
R1(config-if-serial1/0)#dialer-group 1
R1(config-if-serial1/0)#phy async Configure the modem (The ISDN dialup
R1(config-if-serial1/0)#speed 115200 mode can also be adopted. About related
R1(config-if-serial1/0)#modem outer configuration, refer to sections related
with interface configuration)
R2(config-if-serial1/0)#snapshot server 5 Enable the Snapshot server, set active-
time as 5 minutes.
7. 9.3 Monitoring and Debugging Snapshot Routing
show snapshot
The command is used to display the configuration information and current status of Snapshot.
£Command mode¤the privileged user mode
The following information will be displayed through the command:
serial4/2 Snapshot client
Options: Stay asleep on carrier up Dialer support
Length of active period:5
Length of quiet period:200
Length of retry period:8
Current state: active, remaining time: 2 minutes
Explanations: The serial-interface s4/2 is the client and the snapshot status upgrade is denied when the interface is up. The
snapshot is permitted to trigger DDR dialup. The current status is the active time and remained time is 2 minutes.
debug snapshot
no debug snapshot
The command is used to enable/disable snapshot debugging information.
£Command mode¤the privileged user mode
debug dialer
no debug dialer
The command is used to enable/disable DDR event debugging information.
£Command mode¤the privileged user mode
ip route-cache policy
The rapid forwarding of the policy route can enhance the rate of forwarding a packet. To enable the function, execute
the command ip route-cache policy in the interface configuration mode. After the command is enabled, the forwarding packet
received on the local interface will first be controlled by rapid buffer memory the policy route. The negation of the command
is used to disable the rapid forwarding of the policy route.
ip route-cache policy
no ip route-cache policy
£By default¤Nothing
£Command mode¤the interface configuration mode.
ip local policy route-map
To enable the local policy route for the packets generated from the router, execute the command ip local policy route-
map in the global configuration mode so that which route mapping should be applied by the router. After the command is
enabled, the local policy route controls all packets from the router. If the policy route fails to do them, the packets will go on
finding a routing table.
Figure 6-10
Illustration:
1)RouterA connects with RouterB through two private lines.
2)RouterA connects with 3 PCs through the Ethernet.
3)Configure the loopback interface of RouterB as the testing point.
4) A static route is configured between RouterA and RouterB.
5)The goal of the example is to demonstrate the packet policy route based on the source IP address: RouterA sends all
data from 129.255.4.44 out of the interface S0/0 and sends all data from 129.255.4.33 out of the interface S1/0, and all other
data are routed according to the destination.
RouterA is configured as follows:
Command Task
routerA(config-if-fastethernet0)#ip address 129.255.4.11 Configure the Ethernet address.
255.255.0.0
routerA(config-if-fastethernet0)#ip policy route-map map1 Apply IP policy route map 1 to interface f0.
routerA(config-if-fastethernet0)#interface serial0/0
routerA(config-if-serial0/0)# physical-layer sync Configure the physical-layer as the
synchronism mode.
routerA(config-if-serial0/0)# encapsulation ppp Encapsulate PPP on the interface s0/0.
routerA(config-if-serial0/0)#ip address 150.1.1.1
255.255.255.0
routerA(config-if- serial0/0)#interface serial1/0
routerA(config-if-serial1/0)#physical-layer sync
routerA(config-if-serial1/0)# clock rate 64000
routerA(config-if-serial1/0)# encapsulation ppp Encapsulate PPP on the interface s1/0.
routerA(config-if-serial1/0)#ip address 151.1.1.1
255.255.255.0
routerA(config-if-serial1/0)#exit
routerA(config)# ip local policy route-map map1 Make the route use the policy map1 to route
the packets generated by itself.
routerA(config)# ip route 152.1.1.2 255.255.255.255 serial1/0 Configure the static route to the loopback
interface of RouterB.
routerA(config)#ip route 152.1.1.2 255.255.255.255 serial0/0 Configure the static route to the loopback
interface of RouterB.
routerA(config)# route-map map1 permit 10 Configure route map 1 and rule execution
number 10.
routerA(config-route-map)# match ip address 1 The match standard that adopts the policy
route for data packet to enter the Ethernet
port of the router accords with standard
access list 1.
routerA(config-route-map)#set interface serial0/0 Set the packet path: the packet is sent out of
the interface s0/0.
routerA(config-route-map)#exit
routerA(config)# route-map map1 permit 20 Configure route map 1 and rule execution
number 20.
routerA(config-route-map)# match ip address 2 The match standard that adopts the policy
route for data packet to enter the Ethernet
port of the router accords with standard
access list 2.
routerA(config-route-map)#set interface serial1/0 Set the packet path: the packet is sent out of
the interface s1/0.
routerA(config-route-map)#exit
routerA(config)#access-list 1 permit host 129.255.4.44 Set access list 1.
routerA(config)#access-list 2 permit host 129.255.4.33 Set access list 2.
Notice:
Once the RD is configured, it must be firstly deleted if it need be modified.
ip vrf forwarding
To related an interface with a valid vrf, use the command ip vrf forwarding. The negation of the command is used to
delete the relation between the interface and the vrf.
ip vrf forwarding vrf-name
no ip vrf forwarding vrf-name
Syntax Description
vrfÉname The vrf_name bound with the interface.
£By default¤Nothing
£Command mode¤the interface configuration mode.
Notice:
1) After there exists a relation between an interface and an effective vrf, all configured IP addresses will be deleted.
2) An interface can establish a relation with only one vrf.
description
To describe the related vrf information, use the command description. And the negation of the command is used to
delete the description information about the vrf.
description line
no description line
Syntax Description
line The description of the interface.
ip route
The command ip route is used to expand the static route and make it support vrf. The negation of the command is used
to delete the static route.
ip route vrf vrf_name xxxx xxxx
no ip route vrf vrf_name xxxx xxxx
Syntax Description
vrfÉname The vrf name of the static route.
£By default¤Nothing
£Command mode¤the global configuration mode
arp
The command arp is used to expand a static arp and make it support vrf. The negation of the command is used to delete
the static arp.
arp vrf vrf_name xxxx xxxx
no arp vrf vrf_name xxxx xxxx
Syntax Description
vrfÉname The vrf name of the static arp.
£By default¤Nothing.
£Command mode¤the global configuration mode
telnet
The command telnet is used to expand telnet and make it support vrf.
telnet vrf vrf_name xxxx
Syntax Description
vrfÉname Telnet the vrf_name of the server.
£By default¤Nothing
£Command mode¤the privileged user mode
ping
The command ping is used to expand ping and make it support vrf.
ping vrf vrf_name xxxx
Syntax Description
vrfÉname Ping the vrf_name of the opposite-end address.
£By default¤Nothing.
£Command mode¤the privileged user mode
quickping
The command quickping is used to expand quickping and make it support vrf.
quickping vrf vrf_name xxxx
Syntax Description
vrfÉname Quickping the vrf_name of the opposite-end address.
£By default¤Nothing
£Command mode¤the privileged user mode
clear ip route
The command clear ip route is used to expand clear ip route and make it support vrf.
clear ip route vrf vrf_name xxxx
Syntax Description
vrf_name The specified VRF_name.
£By default¤Nothing
£Command mode¤the privileged user mode
traceroute
The command traceroute is used to expand traceroute and make it support vrf.
traceroute vrf vrf_name
Syntax Description
vrf_name The specified VRF_name.
£By default¤Nothing
£Command mode¤the privileged user mode
7.11.2 An Example of M-VRF Configuration
Figure 6-11
Illustration:
1) As shown in figure above, the interface s2/0 of RouterA connects with the interface s1/0 of RouterB. Interfaces s2/0.1,
s2/0.2, s1/0.1 and s1/0.2 are configured respectively. For RouterA, s2/0.1ìl1 belongs to vrf A, and s2/0.2ìl2 belongs to vrf
Noteö
ö
Maipu routers now supports the routing load balancing, namely, if there exist many routes to a destination, the router will add
these routes into the routing table. When the data is transferred, the data load can be transmitted through this interface link in
a certain proportion.
When data is transferred, it needs to close two caches in order that the data load can pass through the interface link in a
certain proportion. The concrete configuring commands are as follows:
A.Router(config)#ë
Command Description
B.Router(config-if-xxx)#ë
Command Description
GRZQ
(
U RXW HU (
6 6
6 6
XS
Command Description
Use the command neighbor remote-as to specify the autonomous system number of BGP peer/peer group;
otherwise, use the negation of the command to delete the autonomous system number of BGP peer/peer group.
neighbor {neighbor-address | group-name } remote-as as-number
no neighbor { neighbor-address | group-name } remote-as as-number
Syntax Descriptions
neighbor peer-group(Creating)
Use the command neighbor peer-group(Creating) toe create a peer group; otherwise, use the negation of the command
to delete a peer group.
neighbor group-name peer-group
no neighbor group-name peer-group
Syntax Descriptions
Syntax Descriptions
Use the command neighbor advertisement-interval to configure the interval for the peer/peer group to send route
information; otherwise, use the negation of the command to restore the default interval for the peer/peer group
to send route information.
Syntax Descriptions
Syntax Descriptions
Syntax Descriptions
Use the command bgp dampening to configure BGP route dampening and other parameters; otherwise, use the
negation of the command to cancel the route dampening.
bgp dampening [half-life reuse suppress max-suppress-time]
no bgp dampening [half-life reuse suppress max-suppress-time]
Syntax Descriptions
Syntax Descriptions
Syntax Descriptions
Syntax Descriptions
Syntax Descriptions
Syntax Descriptions
Syntax Descriptions
Syntax Descriptions
* All peers.
address The IP address of the specified peer.
as-number Reset the BGP connection matching with the AS
number. The value range of AS number is from 1
to 65535.
£Command mode¤The privileged user configuration mode.
clear ip bgp dampening
Use the command clear ip bgp dampening to clear the information about route flap dampening and remove the
restraint of the restrained routes.
clear ip bgp dampening {address | mask }
Syntax Descriptions
Use the command clear ip bgp peer-group to reset all BGP connections of the specified peer group.
Figure 8-6
Illustration:
1) The port S1/0ä192.1.1.1åof RouterA connects to the port S1/0 (192.1.1.2) of RouterB; the port S2/0ä193.1.1.1å
of RouterB connects to the port S2/0 (193.1.1.2) of RouterC;
2) The loopback addresses of three routers are respectively 1.1.1.1(RouterA), 2.2.2.2(RouterB) and 3.3.3.3(RouterC).
3) RouterA is located in AS 100, while RouterB and RouterC are located in AS 200.
Noticeö
ö
The above mainly describes the dynamic routing protocol BGP. About the configuration mode of the physical layer and
link layer, refer to the related sections.
Figure 8-7
Illustration:
1) As shown in the figure above, the configuration of RouterA, RouterB and RouterC is the same as that of example 1.
RouterD is an additional router, belonging to AS 200, its interface s1/0 connects with the interface s1/0 of RouterC, and
their corresponding addresses are 194.1.1.1(RouterC) and 194.1.1.2(RouterD).
2) In the example above, RouterC acts as a reflector and supports two clients: RouterB and RouterC.
3) RouterA is located in AS 100, while RouterB, RouterC and RouterD is located in AS 200.
A) RouterA is configured as follows:
Syntax Descriptions
Noticeö
ö
The above mainly describes the dynamic routing protocol BGP. About the configuration mode of the physical layer and
link layer, refer to the related sections.
Example 3: Configuring BGP Routing
Figure 8-9
Illustration:
1) RouterA, RouterB, RouterC and RouterD are connected as shown in the figure above. Configure the command route-
map on RouterC and set the local-preference of the router so that the route information matching the access list (1.1.1.0/24)
can be transmitted over the path with higher local-preference.
2) RouterA is located in AS 100, while RouterB, RouterC and RouterD are located in AS 200.
Note:
The above mainly describes the dynamic routing protocol BGP. About the configuration mode of the physical layer and
link layer, refer to the related sections.
Note:
1) The route-map can be applied to route redistribution, policy route and BGP. One route-map is composed of several
sentences and each sentence is composed of some match sub-sentences and set sub-sentences. A match sub-sentence is used
to define the match rule of the sentence and a set sub-sentence is used to define the action that will be taken after the sentence
is matched successfully. The filtering relationship among the match sub-sentences of the sentence is “And”, that is to say that
all match sub-sentences of the sentence must be satisfied fully. The filtering relationship among the route-map sentences is
“Or”, that is to say that the route-map can be regarded as matched successfully as long as one sub-sentence of the sentence is
satisfied. If no sub-sentence of the sentence is satisfied, the route-map is matched unsuccessfully. í
2) If the command parameter includes nothing but the route-map name and the match mode or sentence number is
omitted, a sentence (the sentence number is 10 and the match mode is Permit) is added by default. If the negation of the
command is adopted, then all sentences of the route-map will be deleted.
match as-path
Use the command match as-path to specify the matched path list for the route-map; otherwise, use the negation of the
command to cancel the configuration.
match as-path path-list-number
no match as-path path-list-number
Syntax Descriptions
path-list-number The path-list number. Its value range is from 1 to 199 and
multiple numbers can be input simultaneously.
£Command mode¤the route-map configuration mode.
match community
Use the command match community to specify the matched BGP community; otherwise, use the negation of the
command to cancel the configuration.
match community community-list--number
no match community community-list--number
Syntax Descriptions
community-list--number The BGP community number. Its value range is from 1 to
199 and multiple numbers can be input simultaneously.
£Command mode¤the route-map configuration mode.
match extcommunity
Use the command match extcommunity to specify the matched BGP/VPN extended-community; otherwise, use the
negation of the command to cancel the configuration.
match extcommunity extcommunity-list--number
no match extcommunity extcommunity-list--number
Syntax Descriptions
extcommunity-list--number The BGP/VPN extended-community number. Its value range is
from 1 to 199 and multiple numbers can be input
simultaneously.
£Command mode¤the route-map configuration mode.
match interface
Use the command match interface to specify the matched interface; otherwise, use the negation of the command to
cancel the configuration.
match interface interface-names
no match interface interface-names
Syntax Descriptions
interface-names The name of the match interface.
£Command mode¤the route-map configuration mode.
match ip address
Use the command match ip address the IP address range for route-map match; otherwise, use the negation of the
command to cancel the configuration.
match ip address access-list
no match ip address access-list
Syntax Descriptions
Access-list The serial-number or name of the matched access-list.
Multiple ones can be input successively.
£Command mode¤the route-map configuration mode.
match ip next-hop
Use the command match ip next-hop to specify the matched IP address of the next hop for route-map; otherwise, use
the negation of the command to cancel the configuration.
match ip next-hop std-access-list
Syntax Descriptions
Std-access-list The standard-access-list or name that will be matched by the
next hop.
Multiple ones can be input successively.
£Command mode¤the route-map configuration mode.
match ip route-source
Use the command match ip route-source to specify the matched route-source address; otherwise, use the negation of
the command to cancel the configuration.
match ip route-source std-access-list
no match ip route-source std-access-list
Syntax Descriptions
Std-access-list The standard-access-list number or name that is matched by
the resource-route.
Multiple ones can be input successively.
£Command mode¤the route-map configuration mode.
match length
Use the command match length to specify the length range of the matched message; otherwise, use the negation of the
command to cancel the configuration.
match length min-pkt-length max-pkt-length
no match length min-pkt-length max-pkt-length
Syntax Descriptions
min-pkt-length The minimal packet length
max-pkt-length The maximal packet length
£Command mode¤the route-map configuration mode.
match metric
Use the command match metric to specify the matched metric value; otherwise, use the negation of the command to
cancel the configuration.
match metric metric-value
no match metric metric-value
Syntax Descriptions
Metric-value The matched metric values.
Multiple ones can be input.
£Command mode¤the route-map configuration mode.
match route-type
Use the command match route-type to specify the matched route type; otherwise, use the negation of the command to
cancel the configuration.
match route-type route-type
no match route-type route-type
Syntax Descriptions
route-type The matched route type: external, internal, level-1, level-2,
local or nssa-external
£Command mode¤the route-map configuration mode.
match tag
Use the command match tag to specify the matched tag-value of the route information; otherwise, use the negation of
the command to cancel the configuration.
match tag tag-value
no match tag [tag-value]
Syntax Descriptions
Tag-value The matched tag value.
Multiple ones can be input.
£Command mode¤the route-map configuration mode.
set as-path
Use the command set as-path to specify an AS number; otherwise, use the negation of the command to cancel the
configuration.
set as-path prepend as-path-number
no set as-path prepend as-path-number
Syntax Descriptions
as-path-number The AS number.
Multiple ones can be input.
£Command mode¤the route-map configuration mode.
set community
Use the command set community to set the BGP community of the source-route in the route-map; otherwise, use the
negation of the command to cancel the configuration.
set communtiy {additive | local-AS | no-advertise | no-export | none}
no set communtiy {additive | local-AS | no-advertise | no-export | none}
Syntax Descriptions
additive Add the community to the existing community.
local-AS Do not send the matched route out of the autonomous
system.
no-advertise Do not send the matched route to any peer/ any peer group.
no-export Announce the route with the attribute to the peer/peer group
of the autonomous system except the peer/peer group out of
the autonomous system.
None Delete the community of the route.
£Command mode¤the route-map configuration mode.
set ip next-hop
Use the command set ip next-hop to change the next hop of the source-route in the route-map; otherwise, use the
negation of the command to cancel the configuration.
set ip next-hop ip-address
no set ip next-hop ip-address
Syntax Descriptions
ip-address Set the IP address of the next hop.
£Command mode¤the route-map configuration mode.
set local-preference
Use the command set local-preference to change the local preference of the source-route in the route-map;
otherwise, use the negation of the command to cancel the local preference of the source-route.
Syntax Descriptions
value The local preference.
£Command mode¤the route-map configuration mode.
set metric
Use the command set metric to change the metric of the source-route in the route-map; otherwise, use the negation of
the command to cancel the configuration.
set metric metric
no set metric metric
Syntax Descriptions
metric Set the metric.
£Command mode¤the route-map configuration mode.
set origin
Use the command set origin to change the origin of the source-route in the route-map; otherwise, use the negation of
the command to cancel the configuration.
set origin {egp | igp | incomplete}
no set origin
Syntax Descriptions
egp, igp,incomplete Set the origin.
£Command mode¤the route-map configuration mode.
set automatic-tag
Use the command set automatic-tag to set the automatic-tag area; otherwise, use the negation of the command to
cancel the configuration.
set automatic-tag
no set automatic-tag
£Command mode¤the route-map configuration mode.
set comm-list
Use the command set comm-list to adopt the community list to set the community; otherwise, use the negation of the
command to cancel the configuration.
set comm-list std-comm-list | ext-comm-list
no set comm-list [ std-comm-list | ext-comm-list ]
Syntax Descriptions
std-comm-list The standard-community-list number (1-99).
ext-comm-list The extended-community-list number(100-199).
£Command mode¤the route-map configuration mode.
set dampening
Use the command set dampening to set BGP route dampening (attenuation) parameter; otherwise, use the negation of
the command to cancel the configuration.
set dampening time
no set dampening [time]
Syntax Descriptions
time The time.
£Command mode¤the route-map configuration mode.
set default
Use the command set default to specify the default interface for transmitting packets; otherwise, use the negation of the
command to cancel the configuration.
set default interface interface-names
no set default interface interface-name
Syntax Descriptions
interface-name The interface name.
Multiple interfaces can be supported simultaneously.
£Command mode¤the route-map configuration mode.
set interface
Use the command set interface to set the interface for transmitting packets; otherwise, use the negation of the command
to cancel the configuration.
set interface interface-names
no set interface interface-name
Syntax Descriptions
Interface-name The interface name.
Multiple interfaces can be supported simultaneously.
£Command mode¤the route-map configuration mode.
set ip default
Use the command set ip default to specify the next hop IP address to which the packet will be transmitted; otherwise,
use the negation of the command to cancel the configuration.
set ip default next-hop ip-address
no set ip default next-hop ip-address
Syntax Descriptions
Ip-address The next hop IP address (in the form of dotted decimal
notation)
£Command mode¤the route-map configuration mode.
set ip df
Use the command set ip df to set the slicing-flag of an IP message; otherwise, use the negation of the command to
cancel the configuration.
set ip df bit-value
no set ip df [ bit-value ]
Syntax Descriptions
bit-value The value of the slicing-bit.(0 or 1).
£Command mode¤the route-map configuration mode.
set ip precedence
Use the command set ip precedence to specify the priority level of an IP message; otherwise, use the negation of the
command to cancel the configuration.
set ip precedence number | critical | flash-override | immediate | internet | network | priority | routine
no set ip precedence [ number | critical | flash-override | immediate | internet | network | priority | routine ]
Syntax Descriptions
number Priority level(0-7).
routine 0
priority 1
immediate 2
flash 3
flash-override 4
critical 5
internet 6
network 7
£Command mode¤the route-map configuration mode.
set ip qos-group
Use the command set ip qos-group to set the QoS group of an IP packet; otherwise, use the negation of the command to
cancel the configuration.
set ip qos-group qos-group-number
no set ip qos-group [ qos-group-number ]
Syntax Descriptions
qos-group-number QOS group-number(0-99).
£Command mode¤the route-map configuration mode.
set ip tos
Use the command set ip tos to set the IP TOS; otherwise, use the negation of the command to cancel the configuration.
set ip tos tos-value | max-reliability | max-throughput | min-delay | min-monetary-cost | normal
no set ip tos [ tos-value | max-reliability | max-throughput | min-delay | min-monetary-cost | normal ]
Syntax Descriptions
tos-value The value of TOS field(0-15).
max-reliability The maximal reliability.
max-throughput The maximal throughput.
min-delay The minimal delay.
min-monetary-cost The minimal costs
£Command mode¤the route-map configuration mode.
set tag
Use the command set tag to configure the tag value of the OSPF route information; otherwise, use the negation of the
command to delete the configuration.
set tag tag-value
no set tag [tag-value]
Syntax Descriptions
Tag-value The configured tag-value
£Command mode¤the route-map configuration mode.
set weight
Use the command set weight to set the attribute weight; otherwise, use the negation of the command to cancel the
configuration.
set weight weight-value
no set weight [weight-value]
Syntax Descriptions
weight-value The weight value.
£Command mode¤the route-map configuration mode.
show route-map
Use the command show route-map to display the contents of the route-map.
show route-map [ routemap-name ]
Syntax Descriptions
routemap-name The name of the route-map whose contents will be
displayed.
£Command mode¤the privileged user configuration mode.
Exchanging capabilities
After a TCP connection is established, the routers will exchange capabilities which include DLSw version number, initial
receiving window size, the value of SAPs, number of sessions supported by TCP etc. It will also transmit MAC address
tables. You can configure MAC address tables to avoid broadcasting. After exchanging capabilities DLSw partner is
ready to establish a SNA circuit.
Establishing circuit
Establishing a circuit by a group of terminal systems comprises a search for destination resources (based on MAC address)
and configurations of data-link connections of the system. An SNA device sends a probe frame (a test frame and/or a XID
frame) with destination MAC address to look for other SNA devices on the LAN. When a DLSw router receives the probe
frame, it will send a “canreach” frame to each reachable partner. If a DLSw partner can reach the specified MAC address, it
will send an “icanreach” reply frame.
A circuit is composed of three kinds of connections. The data-link connection and the TCP connection between DLSw
partners are specified by routers and local SNA. The circuit is identified by the circuit ID of the source and the destination
circuit. Each circuit ID is defined the source and destination MAC address, the source and destination LSAPs and a data link
control number. Once the circuit is established information frames can be transmitted.
Router(config)#dlsw local-peer ?
Commmand Description
peer-id ip_address <promiscuous> Sets the IP address of the local router. The parameter
promiscuous is an optional command keyword, which is used
to designate that the local router can accept the DLSw TCP
connection request of the remote-end router without
configuration.
Note:
1. Having configured the local parameters (for example, ip-address and promiscuous etc.) of the router, if you need to
alter them, you must configure them afresh only after having canceled the latest parameters through the
corresponding no command. At the same time, this no command must be executed before the other parameters of
DLSw are configured, or else other commands will be ignored.
1. Here, the remote-end router designated by ip_address is regarded as the backup entity of the remote router-end
designated by ip_address1, namely that the router designated by ip_address1 is primary peer while the router
designated by ip_address is backup peer. In addition, before configuring backup peer, you must configure
primary peer; while before deleting backup peer, you must delete backup peer. The same primary peer
permits having one backup peer at most.
Dlsw bridge-group group-number Connects the DLSw link to the Ethernet bridge group.
The parameter group-number is used to designate the
number of the transparent bridge group that will be
connected with DLSw. The valid value ranges between 1
and 63.
Note:
The following command can be used to interrupt the link between the DLSw link and the designated Ethernet LAN
bridge group:
However, this command can interrupt the SNA link relevant to the bridge group simultaneously.
Dlsw icanreach saps Configures the resource reachable for the local router.
Dlsw icannotreach saps Configures the series of server access points unreachable
for the local router
Show dlsw capabilities local Displays all the capability information about DLSw
protocol relevant to the local router.
show dlsw capabilities <ip-address Displays the DLSw capability information about the
ip-address> opposite router. The IP address of the opposite can be
designated.
DLSw: Capabilities for peer 179.255.255.1(2065) The remote peer address is 179.255.255.1
vendor id (OUI) : '00c' The firm code is ‘00C’; The remote
router is from Cisco.
version number :2 Supporting DLSw V2.0 (the version
number is 2)
release number :0 The release number is 0.
init pacing window : 20 The size of the initial transmission window
connecting with TCP by DLSw is 20
unsupported saps : none
num of tcp sessions :1 The TCP session number is 1.
loop prevent support : no
icanreach mac-exclusive : no
icanreach netbios-excl. : no
reachable mac addresses : none
reachable netbios names : none priority configured : no
version string : The version
version string information corresponding
: to the DLSwThe version information of
protocol software of Cisco router the DLSw protocol software of Maipu Router
Cisco Internetwork Operating System Maipu
Software
InfoExpress Software
IOS (tm) C2600 Software (C2600-IS-M), Version 12.0(7)T, RELEASE SOFTWARE (fc2)
Copyright (c) 1986-1999 by cisco Systems, Inc. (c) 1999-2010 by Maipu Networks
Copyright
Compiled Tue 07-Dec-99 02:21 by phanguye
Compiled Mar 14 2002 18:43:56 by Maipuxz
The remote Router Accepted Message Sent Message The time establishing connectio
In the global configuration mode, the above command can be executed to display the DLSw capability information of the
opposite routers connecting with the local router, and the opposite routers can be all the ones or the partial ones designated by
IP addresses. This is shown as follows:
Command Description
show dlsw peers Displays all the status of all current DLSw TCP connections
of router.
In the global configuration mode, the above command can be executed to display all the current DLSw TCP connection
status information of the local router and observe the running information of the DLSw protocol. This is showed as follows:
The above information indicates that the current DLSw TCP connection exists as a SNA circuit.
Command Description
show dlsw circuits <detail> Displays all the current DLSw TCP connection status of
router; detail indicates displaying it in details.
In the global configuration mode, the above command can be executed to display all the current DLSw TCP connection
status information of the local router and to observe the running information of the DLSw protocol. This is showed as follows
Index Local vmac address Remote vmac address Connection status Time establishing
connection
(SAP address) (SAP address)
From the above status information, we can see that no more than 29 messages are permitted to be sent and no more than 28
messages are permitted to be received through the connection. Through this connection, 2788096 bytes have been sent while
2788352 have bytes received; 10891 information frames and 2 XID frames have been sent while 10892 information frames
and 1 XID frame received after the connection has been constructed. The low-end equipment connects with the interface
serial2 of the local router, and the remote IP address is 179.255.255.1 (the remote TCP port number is 2065).
Command Description
In the global configuration mode, the above command can be executed to observe the reachable information of DLSw. This
is showed as follows:
The command mac addr indicates the MAC address of the station being searched; Status indicates the result of the station
search; Loc indicates the station location; Peer/port indicates the entity/port number; rif displays the RIF in the buffer.
Command Description
Synchronous Data Link Control (SDLC) was developed by IBM for System Network Architecture (SNA) environments, and
it is the first bit-oriented synchronous protocol among all link-layer protocols. SDLC defines two types of network nodes:
master node and secondary node. The master node controls other workstations (called secondary nodes) and polls the
secondaries in a predetermined order. If a secondary node has data to send, it can transmit them only when it is polled by the
master node. In working procedure, the master node will establish, terminate and manage links.
address sdlc_address <xid-passthru | This command can be used to designate the physical
xid-poll> address of the equipment connected with the corresponding
interface of router. The router can, through this address,
establish a link layer connection with the lower-end
equipment.
Note:
1. The command sdlc xid sdlc_address xid is useful only when the type of the low-end equipment is PU2.0. In the
situation that the command words xid-passthru and xid-poll have be configured in the command sdlc address,
configuring XID value will not take effect. In addition, before XID value is configured, the physical address of the
corresponding low-end equipment must first be configured, or else the corresponding XID value can not be
configured. When configuring XID value, users must ensure it is consistent with the configuration of the up-end
equipment, or else the SNA connection can not be established.
2. When configuring the command sdlc partner partners_mac_address sdlc_address, users must configure the
physical address of the low-end equipment. At the same time users must ensure the opposite terminal MAC
address configured on the local router is consistent with the up-end VMAC address.
3. Specify that the data encode mode on the interface is NRZI (the default mode is NRZ)
router(config-if-serial1)#nrzi-encoding
Command Description
router(config-if-serial1)#sdlc dlsw c2
The local equipment address running on the SDLC link
8.2.3 The Debugging Information of SDLC
Command Description
0 collisions; 0 dropped
router link station role: PRIMARY (DCE)
slow-poll 10 seconds
poll-pause-timer 500 milliseconds
k (windowsize) 7
modulo 8
sdlc vmac: 2001.2654.00--
sdlc addr 20 state is CONNECTED
cls_state is IDLE
VS 0, VA 0, Remote VR 0, Current retransmit count 0
Hold queue: 0/1 IFRAMEs 5/7
TESTs 1/1 XIDs 1/2 DMs 0/0 FRMRs 0/0
RNRs 0/0 SNRMs 0/-- DISCs/RDs 0/0 REJs 0/0 UAs --/0
intf[][]:
32 00 00 00 00 00 00 00
Current serial1 index is: 0
12 packets input, 2314bytes
0 input errors, 0 CRC, 0 overrun, 0 noOctet, 0 abort, 0 lenErr
3 packets output, 3121 bytes, 0 underruns
DCD=up DSR=up DTR=up RTS=up CTS=up TxC=up
From the above information you can see that the terminal equipment hanged by router has connected with the mainframe, and
can transmit data.
ATM
S0 S1
SDLC S0/0 WAN
S2
Note: A Cisco router and a Maipu router can communicate through the serial interface by means of some link protocols,
such as PPP, HDLC, FR and X.25, or can communicate directly through the local Ethernet.
B. The synchronous/asynchronous serial port connects with ATM and the customer FEP through PSD, or connects with
IBM mainframe through Cisco router. It can be shown as follows:
PSD
S1
IP
Network
SDLC
IBM S2 ATM
mainframe
Frontmounted computer
Figure 8-2 the SNA typical network construction mode2
S1
WAN
SDLC S2
S3
IBM ATM
Mainframe Frontmounted
computer
Figure 8-3 the typical SNA configuration (A)
Illustration:
ATM and the customer FEP connect directly with the serial port of the Maipu router, and the Maipu router connects with the
Cisco router through PPP protocol running on the serial port.
The following tasks are finished mainly in the whole procedure:
A. Configure the relevant commands of DLSw in the global configuration mode.
B. Configure PPP protocol for the interface S0 to connect with the up-end router.
C. Configure the ATM machine with a SDLC address C1 for the interface S1
D. Configure the ATM machine with a SDLC address C2 for the interface S2
E. Configure the customer premise machine whose type is PU2.2 and whose address is C3 for the interface S3.
Configuring the relevant commands of DLSw in the global configuration mode:
Command Task
Configuring PPP protocol for the interface S0 to connect with the up-end router:
Command Task
Configures the ATM with a SDLC address C1 for the interface S1:
Command Task
Configures the ATM with a SDLC address C2 for the interface S2:
Command
router(config-if-serial2)#encap sdlc
router(config-if-serial2)#sdlc address c2
router(config-if-serial2)#sdlc dlsw c2
Configures the customer premise machine whose type is PU2.1 and whose address is C3 for the interface S3:
Command Task
router(config-if-serial3)#encap sdlc
router(config-if-serial3)#sdlc dlsw c3
Note:
1. For the low-end equipment of the SDLC interface, the two kinds of configurations, PU2.1 and PU2.0, are
different because they are obviously different in the initial phase of establishing link.
The way for PU2.1 to resolve the problem that the mainframe circuit whose up-end is token-ring can not be established:
Configure sdlc address <sdlc_address> xid-poll echo in the interface configuration mode.
2. For the APPN modes, in the interface configuration mode, it usually needs to be
configured:
sdlc sdlc-largest <sdlc_address> 265Ôor 521: maximum information frame length)
Example B:
S0/0:19.1.1.1 S0:19.1.1.2
WAN
S1
SDLC PSD
IBM mainframe
Command
router(config-if-serial0)#encap ppp
router(config-if-serial0)#ip address 199.1.1.2 255.255.255.0
Configure the interface S1 to connect with two ATM machines whose addresses are C1 and C2 respectively, and to connect
with a customer premise machine whose type is PU2.1 and whose address is C3.
Command
router(config-if-serial1)#encap sdlc
router(config-if-serial1)#sdlc vmac 1111.1111.1100
router(config-if-serial1)#sdlc address c1
router(config-if-serial1)#sdlc xid c1 05df0301
router(config-if-serial1)#sdlc partner 1111.2222.33c1 c1
router(config-if-serial1)#sdlc address c2
router(config-if-serial1)#sdlc xid c1 05df0302
router(config-if-serial1)#sdlc partner 1111.2222.33c2 c2
router(config-if-serial1)#sdlc address c3 xid-poll
router(config-if-serial1)#sdlc partner 1111.2222.33c3 c3
router(config-if-serial1)#sdlc dlsw c1 c2 c3
The above configuration indicates: the lower-end equipment of different types can connect with a same serial port through
PSD. At the same time, when PSD is used, the circuit clock is usually provided by PSD, and the router interface works in the
external clock mode.
Note:
8. 3 LLC2
The router connects to the bridge group in LAN through the local Ethernet interface. The bridge group is related with the
DLSw TCP connection, and the local LAN interface runs LLC2 protocol.
8.3.1 LLC2 Configuration Commands
z dlsw bridge-group
Use the command dlsw bridge-group to relate the DLSw TCP connection with the Ethernet bridge group in the global
configuration mode.
dlsw bridge-group group-number
Syntax Descriptions
group-number The bridge-group number that will be related with the DLSw TCP connection.
its value range is from 1 to 10.
£Command mode¤the global configuration mode.
z bridge group
Use the command bridge group to connect the local Ethernet interface to the bridge group in the local LAN.
bridge group group-number
Syntax Descriptions
group-number The bridge-group number configured for the Ethernet interface.
It must be consistent with group-number of the command dlsw bridge-group.
£Command mode¤the interface configuration mode.
8.3.2 Protocol Filtering
When there is too much data in the LAN and LLC2 is bridged through Bridge, SAP access list can be configured on Bridge
and nothing but SNA data is allowed to be bridged so that it can be avoided that the data broadcasted in the local LAN is
bridged to LLC2 and transmitted to the upper-end router through DLSw. That is to say that the upper-end network congestion
can be avoided.
z access-list
Use the command access-list to configure LSAP access list.
access-list list-number permit/deny lsap-addr [lsap-wildcard]
Syntax Descriptions
list-number The access list number.
Its value range is from 4001 to 5000.
permit/deny Permit/Deny access.
lsap-addr The permitted/denied <dsap,ssap>.
lsap-wildcard The wildcard
£Command mode¤the global configuration mode.
z bridge-group group-number input-lsap-list <list-number>
Use the command bridge-group group-number input-lsap-list <list-number> to filter the SAP frames received by
the bridge group.
z bridge-group group-number output-lsap-list <list-number>
Use the command bridge-group group-number output-lsap-list <list-number> to filter the SAP frames sent by the
bridge group.
z bridge-group group-number input-type-list <list-number>
Use the command bridge-group group-number input-type-list <list-number> to filter the Ethernet frames received by
the bridge group.
z bridge-group group-number output-type-list <list-number>
Use the command bridge-group group-number output-type-list <list-number> to filter the Ethernet frames sent by the
bridge group.
Note:
Generally, The SAP list is configured as follows:
access-list 4001 permit 0x0404 0x0000 or
access-list 4001 permit 0x0d0d 0x0000
Thereby, lsap(0x04è0x04)SNA needs is permitted to pass and other types of packets can be filtered out.
8.3.3 An example of typical LLC2 configuration
Server
Figure 22-1
Illustration:
Maipu router connects to the bridge group in LAN through the local Ethernet interface. And the bridge group is related
with the DLSw TCP connection.
A) Configure the related DLSw commands in the global configuration mode.
Syntax Descriptions
dlsw local-peer peer-id 19.1.1.2 The DLSW address of the local end.
dlsw remote-peer 0 tcp 19.1.1.1 The DLSW address of the remote end.
dlsw bridge-group 1 The DLSw bridge-group number in the local LAN.
B) The interface S0/0 adopt the PPP protocol to connect to the upper-end router.
Syntax Descriptions
encap ppp Encapsulate the PPP protocol.
ip address 19.1.1.2 255.255.255.0 Specify an IP address for the interface S0/0.
Note:
To relate the DLSw TCP connection with the bridge-group in the local LAN, configure the bridge-group number of DLSw in
the global configuration mode, and the same bridge-group number should simultaneously be configured on the Ethernet
interface so that the Ethernet bridge-group can be related with the DLSw bridge-group.
8.4 QLLC
Qualified Link Layer Control (QLLC) is a data link protocol defined by IBM and which allows SNA data to be transmitted in
the X.25 network. In the traditional SNA network, any equipment using the X.25 protocol on the SNA communication
channel, no matter which on terminal or intermediate system it resides in, needs to make use of the QLLC protocol.
The QLLC transform feature avoids the requisition for the local IBM equipment to install X.25 software. And QLLC only
demands that the low-end equipment can provide X.25 interface to connect with the lower-end equipment in the remote-end
X.25 network with the IBM mainframe through the router with QLLC transform feature. The router connects with the upper-
end equipment through DLSw TCP, so the intermediate equipment does not need the X.25 interface and the relevant
software.
A. PVC mode
Router(config-if-xxx)#
Command Description
B. SVC Mode
Router(config-if-xxx)#
Command Description
encapsulation x25 Executes the command to transform the
interface link layer protocol into X.25
protocol.
Maybe the relevant parameters of the X.25
protocol and the LAPB protocol also need to
be configured.
x25 map qllc virtual-mac-addr x121-addr Designates that X.25 SVC is adopted for the
router to communicate with the PU
equipment of the remote X.25 protocol.
virtual-mac-addr represents the virtual
MAC address, namely, the VMAC address
of the remote X.25 terminal connected by
router.
X121-addr represents the X.121 address of
the remote X.25 equipment connected with
this virtual MAC address.
Qllc dlsw vmacaddr virtual-mac-addr partner mac- Associates the QLLC protocol with DLSw
addr TCP.
virtual-mac-addr represents virtual MAC
address, namely, the VMAC address of the
remote X.25 terminal connected by the
router.
Mac-addr represents the address of the
upper-end mainframe designated to
communicate with the remote X.25
equipment.
Qllc dlsw partner mac-addr If all addresses of the mainframes
corresponding to all the X.25 equipment
connected by this interface are mac-addr,
the command can be simplified as this one.
Dlsw qllc local-window <10-100> Set the local X.25 window size to control
the traffic between DLSw and X.25.
When the speed of the X.25 interface is
slow, the window size can properly be taken
in and DLSw is notified to reduce the data
transmission speed so as to avoid the
overflow of the data-sending queue. The
default value is 50.
333
)
:RU NVW DW L RQ
Illustration:
Here the Maipu router connects with a X.25 network through a serial port, runs QLLC protocol, connects with the low-end
SNA equipment, and associates the DLSw TCP with the QLLC protocol.
The configuration of the down-end Maipu router is as follows:
The interface S0 connects with the upper-end router through PPP protocol:
Command Task
router(config-if-serial0)#exit
The interface S1 connects with X.25 network, runs QLLC protocol, and connects with the low-end SNA equipment:
Command Task
router(config)#int s1
router(config-if-serial1)#encap x25 Encapsulates the X.25
protocol.
router(config-if-serial1)#x25 dce Configures it as the DCE
mode.
router(config-if-serial1)#x25 ltc 10
router(config-if-serial1)#x25 pvc 1 qllc 1111.2222.3344 Associates VC of the X.25
interface with the QLLC
protocol;
1111.2222.3344 is the
VMAC address of the
low-end equipment.
router(config-if-serial1)#qllc dlsw pvc 1 partner 2233.4455.6677 Associates the QLLC
protocol with the DLSw
TCP connection.
router(config-if-serial1)#end
The QLLC protocol associates the low-end equipment with X.25 VC, and exclusively determines a low-end equipment
through the corresponding VMAC address and the partner address.
Command Description
6
6'/& 6 6
:$1
&, 6&2 03 6
, %0 5RXW HU 5RXW HU $70
0DL QI U DPH )U RQW (QG
3U RFHVVRU
Figure 22-3
Note:
The communication between the Cisco router and Maipu router can be realized by means of two modes: the serial
interface runs the link protocol (for example PPP, HDLC, FR or X.25) or the local Ethernet is adopted.
2) The synchronous/asynchronous serial-interface connects with ATM and the front end processor through PSD and
connects to the IBM mainframe through Cisco router.
IP network
IBM mainframe
MP router
Cisco router
Front end
processor
Figure 22-4
WAN
IBM mainframe MP router
Cisco router
Front
end
Figure 22-5
Illustration:
ATM and front end processor connect to the serial interface of Maipu router directly, and Maipu router connects to Cisco
router by means of running the PPP protocol on the serial interface.
1) The DLSw configuration commands in the global configuration mode are listed as follows:
Syntax Descriptions
2) The PPP is configured for the interface S0/0 to connect to the upper-end router:
Syntax Descriptions
3) Configure the ATM (the SDLC address is C1) on the interface S1/0:
Syntax Descriptions
4) Configure the ATM (the SDLC address is C2) on the interface S2/0:
Syntax Descriptions
5) Configure the ATM (the SDLC address is C3 and the type is PU2.1) on the interface S3/0:
Syntax Descriptions
Note:
For the downstream equipment of the SDLC interface, there exists some difference between PU2.1 and PU2.0.
8.8.2 Typical Configuration 2
MP router
WAN
Front end
processor
Figure 22-6
Illustration:
By means of PSD, one serial interface of Maipu router connects with multiple downstream equipments, and connects to
the upper-end Cisco router through WAN.
1) The DLSw configuration commands in the global configuration mode are listed as follows:
Syntax Descriptions
2) The configuration interface S0/0 connects to the upper-end router by means of PPP protocol.
Syntax Descriptions
encap ppp Encapsulate the PPP protocol.
ip address 19.1.1.2 255.255.255.0 Specify an IP address for the interface s0/0.
3) The configuration interface S1/0 connects with two ATMs (whose SDLC addresses are respectively C1 and C2) and
the front end processor (the address: C3, type: PU2.1) through PSD.
Syntax Descriptions
The configuration above indicates that: different types of downstream equipments can connect to one serial interface through
PSD. At the same time, when PSD is adopted, the line clock is provided by PSD, and the interface of the router operates in
the external clock mode.
Note:
The following points should be noticed in the SNA applications:
1) Whether Maipu router and Cisco router are consistent on DLSw/SDLC configuration.
2) The status of the interface connecting with ATM, front end processor or PSD is UP.(by means of the command show
int <interface name>)
3) Determine whether the static route is configured on Maipu router according to the factual requirements.
4) Determine whether the configuration of DLSw remote-peer is added on Cisco router according to the factual
requirements.
5) Check whether the IP address specified by Cisco local-peer can be reachable through Maipu router( by means of
Ping)÷
6) Check whether the XID frame need be configured.
7) Check whether some special options need be configured.
8) Check whether cables are in order and physical signals are adequate.
Chapter 9 IP Telephone Configuration
IP telephone configuration generally refers to the system that processes voice communication on an IP network. An IP
telephone system has been integrated into Maipu’s MP series routers. Users can use the IP telephone module provided by the
router to process voice communication. Presently, Maipu routers support the H.323 protocol family, the mainstream protocol
of the IP telephone system. H.323 protocol family includes H.225-Call Control Protocol, H.245-Multimedia Control
Protocol, and RTP/RTCP --Realtime Transmission Protocol/Realtime Transmission Control Protocol.
This chapter describes how to configure the Maipu voice card, including how the FXS card accesses the PSTN/PBX through
the FXO card, how the FXS cards intercommunicate between them, how to configure a Maipu router as the H.323 voice
gateway, and some optional extended configurations.
• Relevant commands
• A simple configuration example
RouterÔconfigÕÏvoice-port ë
Command Description
Note:
1. If there is an IP telephone module of an old version router, the voice card interface is a single number, for example,
0, 1 etc.
2. If there is an IP telephone module of new version router, the voice card interface is the format of x/y, of which x is
the WAN port number while y is the voice port number. For example, inserting the module in the WAN port s3 and using
channel 1, then the voice port number is 3/1.
3. The number of a concrete interfaces can be examined through the command show run.
RouterÔconfigÕÏvoice-port 0/0
RouterÔconfig-voice-portÕ#ë
Command Description
Codec <g723 / g729 / g711a> This command is used to configure voice-coding type. There are
G.723, G.729 and G.711a, to be selected, which correspond to
different codings and compression algorithms. The typical ones
are G.729 and G.723. If a kind of voice coding is selected, the
router will negotiate voice coding first.
Volume <Number> This number is the volume coefficient within the range 0-63.
The larger the coefficient, the higher the volume.
connection-plar <STRING> It is used only in the FXO card; string represents a telephone
number. After the configuration is finished, once a ringing is
detected on the FXO port, the telephone number is used as the
called number and a call is directly originated to the remote
terminal.
[no] shutdown Configures opening/shutting down the voice port.
Command Task
Note:
1. The default configuration of voice port is shutdown.
9. 2 Configuring VoIP
In the VoIP (Voice over IP) configuration, there is a conception dial-peer that is used to distinguish different types of session
segments. There are two kinds of dial-peers:
POTS — A traditional telephone network peer, such as commonly used telephone interfaces,
PSTN telephone line interface (Z interface), etc.
VoIP — IP network peers (passing through the IP network, corresponding with the remote
telephone segment.)
Relevant commands
Usage of the basic commands
Usage of the extended configuration
A configuration example
,3
&DO O HU 1HW ZRU N
3671
5HFHL YHU
,3
&DO O HU 1HW ZRU N
3671
'HVW L QDW L RQ
6RXU FH U RXW HU
U RXW HU
9R, 3 'L DO SHHU 3276 'L DO SHHU
Figure 9-2 Dial peers seen from the perspective of the called party
Router#conf t
Router(config)#ë
Command Description
dial-peer <1_255> <pots/voip> Configures the dialing map; 1-255 is the number of the session
segment number; make configurations to the pots end or the
voip end.
port <STRING> Configures the voice port corresponding to the pots end.
Command Description
Port 0/0 Configures the number 111 to be corresponding with the voice
port 0/0.
Router(config)#
Command Description
destination-pattern 111 Configures the number of the opposite terminal as 111 (the
number to be called).
Example:
,3
QHW ZRU N
5RXW HU
5RXW HU
Router2 uses the abbreviated number dialing:
Command Description
Note:
Router1 uses the extended number dialing:
Command Description
B. Dial-up terminator
When dialing, users can select whether they need to have the dialing terminator “#” or “*”. If needed, they must dial an “#”
or “*” key to indicate the end of the dialing, otherwise, the router recognizes the dialing terminator automatically. If users do
not use the wildcard “.”, there will be little difference to have a dialing terminator or not. When the wildcard is used, the
advantage with a dialing terminator is that the configuration will be simple for users, at that time, to dial an uncertain length
number. Without the dialing terminator, when dialing, users will feel as if they are dialing from a common telephone;
however, when the lengths of the numbers to be dialed are different, the configuration will be much longer, and it will add
some matching terms to match the number with different lengths.
Router(config)#
Command Description
C. Secondary dialing
Secondary dialing is the dialing mode that occurs on the general telephone network, after a common telephone dials on the
FX0 port (can be regarded as the telephone exchange), it dials another extension. This mode is similar to that of a common
telephone PBX.
The other mode, apart from second dialing mode, is the direct extension mode, namely that after a general telephone in
common telephone network dials to the FX0 port, it need not dial the extension number further, instead, it directly dials on
some extension number according to the configuration.
After the telephone exchange is connected successfully, dialing any additional extension that can be connected can be dialed
according to the record prompt (if there is record).
The unique recording function of the Maipu IP telephone provides the recording time of 15 seconds. When the telephone
exchange is connected successfully and you hear the prompt tone “di”, please input *123*# (if the configuration is not being
used, you need not dial the last key “#”). If there is the dialing terminator, please configures it as ending with a #, then you
can begin to record when hearing a prompt tone, and press any key to terminate recording after finishing. So, when the
telephone exchange is dialed up successfully next time, you can hear the recorded sound. During the course of hearing the
sound, you can interrupt it at any time to dial the needed extension number.
,3
1HW ZRU N
3671
Illustration:
1. Secondary dial: When the telephone “5148333” of the exterior PSTN network dials on “5148222”, the prompt tone
can be heard, and then you dial “111”or “111#” further, namely, dial the extension “111”.
2. Direct extension dialing: the following commands need be added to the router2:
Router(config)#voice-port 3/0
Command Task
connection-plar 111 Configures 5148222. Once the connection is ok, then the call
with the number “111” will be sent automatically to the remote
terminal
Note:
1. The default configuration of a Maipu IP telephone is the secondary dialing mode.
2. Only the FXO (connecting with the switch card exteriorly) has the option of choosing the
secondary dialing (mode) or the direct connection extension.
,3
1HW ZRU N
5RXW HU
5RXW HU
Illustration:
1. In the above configuration, both Router 1 and Router 2 each contain built-in FXS modules.
Supposing they are the new version of routers and two IP telephone modules are inserted
into the interface S2 respectively and the channel 0 is employed.
2. This example is about the interconnection between the two FXS modules, when they are
configured, the following tasks should be completed:
Router(config-dial-peer)#exit
Router(config-dial-peer)#exit
Illustration:
1. In the above figure of configuration, both router1 and router2 have the built-in FXS modules,
while router3 has a built-in FXO module. Supposing they are the new version of routers, and
all the IP telephone modules are inserted in the port s2 and they use the channel 1.
2. This is an example about the intercommunication between the FXS module and the FXO,
about the second dialing, and about the direct extension dial. When they are configured, the
following tasks should be finished:
A. Configuring the pots end and the voip end
B. Configuring the voice interface
Command Task
Router(config)#voice-port 2/1 Enters the corresponding voice port.
Router(config-voice-port)#codec g729 Configures the coding mode as g729.
Router(config-voice-port)#no shutdown Activates the voice port.
The configuration of router3 is different depending on the modes of secondary dialing and direct extension dialing.
Command Task
Router(config)#voice-port 2/1 Enters the corresponding voice port.
Router(config-voice-port)#codec g729 Configures the coding mode to be g729.
Router(config-voice-port)#no shutdown Activates the voice port.
5RXWHUFRQILJ-voice-port)#connectionÙplar 111 Once the exterior line dials up 5148333
successfully, the extension 111 will be
connected directly.
5RXWHUFRQILJ-voice-port)#connectionÙplar 222 Once the exterior line dials up 5148333
successfully, the extension 222 will be
connected directly.
Router(config-voice-port)#exit
Note:
1. If the command sentences are configured with “ ´ODEHOLWis in the direct connection mode.
The advantage of this mode is that it is easy for a user to operate, once the user successfully
dials 5148333, he can dial 111/222 directly. The disadvantage is that it is fixed to dial up only
one extension, namely that one voice interface only corresponds to only one
connection-plar.
2. If the command sentences are not configured with the “ ´ODEHOLWLVLQVHFRQGDU\GLDOLQJ
mode. After the exterior line successfully dials 5148333, he can choose the extension 111 or
the extension 222 according to the record prompt (if there is record)
3. All numbers configuration can use the wildcard.
A) If users dial the number “5148222”Øthey dial the extension “222” successfully.
B) If users dial the number “123”, they can dial the exterior line “5148123”
successfully.
Note:
1. When dialing “111”, users must end it with “#”, only so can the number really be dialed out.
2. When dialing 95148123 or 913912345678, users end it with “#”, then the number will be sent
out. This can achieve that all the numbers with different lengths can use the same one voip
(the number of the wildcard point should be more than/equal to the longest number to be
dialed, so does the pots wildcard of the router3)
3. If there is no dialing terminator, when users want to match both dialing of 5148123 and
139123456789, different voips need be configured. For example, the wildcard beginning
with 8 matches the 7 bits numbers, while the wildcard beginning with 9 matches the 11 bits
numbers.
A Maipu router can be used as the H.323 voice gateway, and can be used for the voice intercommunication between many IP
networks or between an IP network and a telecommunications network, such as PSTN network etc. Presently, Maipu routers
supports the RAS (Registration, Admission, Status) protocol, which is used to exchange information with the gatekeeper.
Other functions, such as security, charging and Supplementary Services, will be provided in the subsequent version.
• Basic Concepts
• Configuring H.323 voice gateway
• An example of configuration
RAS protocol:
RAS (Registration, Admission, Status) protocol is a protocol that runs between the H.323 gateway and the gatekeeper, and is
used for call control and management, which includes address resolution, address mapping, bandwidth management, call
control, route management and security management.
supported-prefix <string> Configures a prefix to identify the voice gateway at which the
destination telephone is. This prefix will be added to the front of
the telephone number dialed by users.
session-target ras Designates the use of the RAS protocol to get the IP address of
the destination telephone.
Router(config)#int s0
Command Description
h323-gateway voip interface Designates this interface as the RAS protocol interface of
the voice gateway.
h323-gateway voip h323-id <STRING> Configures the gateway interface identifier that is used for
the gatekeeper to identify the gateway interface.
h323-gateway voip id <STRING> <ipaddr/ The first string is the gatekeeper ID, while the second string
multicast> <STRING/CR> is the IP address that is configured after the ipaddr mode is
chose.
h323-gateway voip supported-prefix Configures the gateway ID-prefix that is used for the
<STRING> gateway to process the session route, namely that the
gatekeeper will route the telephone number beginning with
this prefix to the gateway.
Note:
1. The multicast mode is used to search the gatekeeper through the multicasting mode while
the ipaddr mode is used to designate the gatekeeper.
Router(config-dial-peer)#exit
Router(config-if-fastethernet0)#ip address
128.255.255.244 255.255.0.0
Router(config-if-fastethernet0)#h323- Configures the gateway interface identifier.
gateway voip h323-id mp
Router(config-if-fastethernet0)#h323- Designates that the multicasting mode is used to search the
gateway voip id gk multicast gatekeeper.
Notice:
• Turning on the IP telephone debugging switch
• Turning off the IP telephone debugging switch
• The wire order of the new version Voip module
Router(config)#
Command Description
o UNIX
o Ethernet
o T o T o T
Figure 10-1 Terminal protocol operation modeÔthe local modeÕ
IllustrationÖ
The figure above is the topology of the local terminal operation mode: the local router accesses the Ethernet through the
Ethernet port and connects with the Unix server; the synchronous/asynchronous interface or asynchronous interface
encapsulates the terminal protocol and connects with the terminals.
o UNIX
o E
o Local
o Remo
o T o T o T
Figure 10-2 Terminal protocol operation modeÄthe remote modeÅ
Illustration:
The figure above is the topology of the remote terminal operation mode: the remote router accesses the WAN through
the WAN interface and connects with the local router through which the remote router connects with the Unix server. On the
remote router, the synchronous/asynchronous interface or asynchronous interface encapsulates the terminal protocol and
connects with the terminals.
Compared with the previous terminal access mode of Maipu router, the terminal protocol has gotten much enhancement
at the aspects of function and flexibility and overcomes the limitation that nothing but the asynchronous interface module can
access the terminal. As long as the interface module supported by Maipu router can operate in the asynchronous mode (For
example: frequency-band MODEM interface, high-speed synchronous/asynchronous serial interface), the interface can
encapsulate the terminal protocol for terminal access.
Firstly, the terminal protocol can, according to the user configuration or terminal service, specify the service-port of the
upper-end service for the establishment of TCP connection. When the lower-end service data arrives, the router encapsulates
the terminal data into TCP/IP messages, and sends them to upper-end server through the TCP connection; at the same time,
the terminal protocol monitors the data the server send downwards, and the terminal protocol encapsulates the TCP/IP
message and sends the service data to the terminal when the router receives the data sent from the server. The terminal
protocol can establish multiple TCP connections simultaneously and realize the service switch of the terminal. Moreover, the
terminal protocol can assist Itest or other terminal-number fix program to realize the fix terminal-number access and data
encryption and compression transmission, which can enhance service security.
Note:
The terminal name is case sensitive.
In the terminal template configuration mode, the parameters related with terminal services can be configured, and the
following commands can be supported.
Terminal local local-ip-address
Configure the local IP address of the template as the IP address of some interface of the router (generally the local IP
address is the IP address of the loopback interface). The terminal protocol can regard the IP address as the source address and
establish the TCP connection with the server.
Terminal remote
terminal remote host-number host-name host-ip-address domain name{fix-terminal | telnet | rlogin}
Syntax Description
host-number The remote service number, and its value scope is from 0 to 9.
host-name The remote service name, displayed on the terminal selection interface.
host-ip-address The IP address of the remote service.
domain name The host domain name of the remote service.
fix-terminal The remote service works in the fix-terminal mode (By default).
telnet The remote service works in the telnet mode.
rlogin The remote service works in the rlogin mode.
When working in the fix-terminal mode, the remote service can support the following options:
terminal remote host-number host-name host-ip-address fix-terminal { tcp-port | authentication | compress | encrypt
<string> | start-chars | negotiate-port | server}
Syntax Description
tcp-port The TCP port number of the remote fix-terminal itest service.
Its value range is from 1 to 65535 and the default port-number is 3051.
authentication Router ID authentication (Namely the previous MAC address
authentication, and no authentication is configured by default.)
compress Compress the data
encrypt Encrypt the data in the fix-terminal mode. After that, the key is also
encrypted.
start-chars The Fix-terminal auto-screen-brush character.
It need be consistent with that the Itest configuration (nothing is
configured by default.)
negotiate-port Specify the negotiation port number for terminal connection in the fix-
terminal mode.
server The router serves as the server of the TCP connection and waits for client
connection.
NoteÖ
1) When the function of the auto-screen-brush is employed, the parameters -r –k a1:a2:a3 need be configured when Itest
starts. The parameter “-r” means enabling the screen memory. For ék a1:a2:a3, a1, a2 and a3 are hexadecimal numbers, and
“0xa1 0xa2 0xa3” is configured behind “start-chars”;
2) When the function of data compression is adopted, the option compress need be added into the Itest configuration file
(itest.conf), and its format is described as followsö
When working in the rlogin mode, the remote service supports the following options:
terminal remote host-no host-name host-ip-address rlogin remote-user-name
Syntax Description
Remote-user-name The remote username of rlogin logon.
In the terminal template configuration mode, the related configuration commands are described as follows:
terminal {auto-linking <0*9> | hesc-chars | host <0*9> hesc-chars | print { on | off } | redraw {<0*9> |
console } <STRING> | retry-times <1*65535> | rx-delay | rbufsize <128*16384> | tbufsize <2048*16384> }
Syntax Description
auto-linking Automatically establishing a link (Disabled by default)
hesc-chars The terminal service switch character ( the default character is
“Ctrl+G+D”)
host The hot key of terminal host switch.
print Print the information about prompts and helps on the terminal
(permitted by default)
redraw The terminal redraw (the field STRING is the terminal screen-
brush key, and different terminals define different terminal screen-
brush keys)
retry-times The retry times of establishing a link ( three times by default).
rx-delay The receiving delay, applied to the situation of using a card reader
(no delay is configured by default).
tbufsize The size of TCP transmitting bufferÄ 8192 by defaultÅ
rbufsize The size of TCP receiving bufferÄ2048 by defaultÅ
10.1.1.2 The Interface Encapsulation Terminal Link Protocol
In the interface configuration mode, configure the command encapsulation terminal.
terminal noise-filter
The command is used to enable/disable the noise-filter of the interface. After the noise-filter is enabled, the noise
interference, which is on the floating line and results from closing the RX/TX/GND terminal connection, can be
avoided. The noise-filter is enabled by default.
terminal noise-filter { ENABLE | DISABLE }
ÏCommand modeÐthe interface configuration mode.
NoteÖ
1) The terminal protocol must operate in the asynchronous mode. For the synchronous/asynchronous serial interface
mode, the configuration command physical async must be firstly used to convert the physical layer into the asynchronous
mode.
2) Neither IP address nor other IP property parameters can be configured;
3) After the terminal protocol is encapsulated, the default configuration tx-on dsr can be adjusted according to the
bottom-layer physical signals of the terminal interface, such as tx-on dcd-dsr or tx-on cts;
4) No flow-control is configured by default. Generally, a terminal can receive nothing but the receiving, transmitting and
GND signals, and support no hardware flow-control. The flow-control configuration can be modified according to the line
condition and terminal performance.
5) The command terminal noise-filter can be used to filter out the start-character 00 or ff. In some applications, the 00 or
ff character can be sent out in the beginning. Here, the noise-filter is disabled.
10.1.1.3 Applying the Terminal Module to a Terminal Protocol Interface
Adopt the command terminal apply template-name <interface1> <interface2> to apply the terminal template to the
Terminal protocol interface <interface1> and<interface2>.
NoteÖ
When a terminal template is applied to multiple interfaces, such as the two interfaces above, interface1 and interface2
must be two interfaces in the same slot.
10.1.2 An Example of Terminal Protocol Configuration
The local-end encapsulating the terminal protocol is configured as follows:ÔShown as figure 10-1Õ
A) Configuring the interface parameters:
Command Task
Router#config terminal
Router(config)#int f0 Enter the configuration mode of the
interface f0.
Router(config-if-fastethernet0)#ip add 129.255.24.100 Configure the Ethernet address of the
255.255.0.0 router/ terminal server.
Router(config-if-fastethernet0)#exit
Router#(config)interface serial0/0 The configuration mode of the serial-
interface s0/0.
Router(config-if-serial0/0)#physical-layer async The serial-interface s0/0 is configured
as the asynchronous mode.
Router(config-if-serial0/0)#tx-on dcd Configure the dcd signal to judge
physical signal up.
Router(config-if-serial0/0)#encapsulation terminal Encapsulate the terminal protocol.
Router(config-if-serial0/0)#exit
ÔThe above is the configuration of encapsulating a high-speed serial interface as the terminal protocol, and the
configuration of 8/16SA is the same as that of the high-speed serial interface.Õ
Command Task
Router#(config)interface serial1/0 The configuration mode of the serial-interface
s1/0.
Router(config-if-serial1/0)#physical-layer async
Router(config-if-serial1/0)#tx-on dcd Configure the dcd signal to judge physical
signal up.
Router(config-if-serial1/0)#encapsulation terminal Configure the interface s1/0 (built-in modem)
to encapsulate the terminal protocol.
Router(config-if-serial1/0)#modem party originate Configure the built-in modem as the
origination.
Router(config-if-serial1/0)#modem line leased Configure the built-in modem as the automatic
leased line mode.
Router(config-if-serial1/0)#modem async direct Configure the built-in modem as the direct
asynchronous mode.
Router(config-if-serial1/0)#modem enable
Router(config-if-serial1/0)#exit
Ô The above is the configuration of the automatic leased line mode in which the built-in modem encapsulates the
terminal protocol. The usage of this mode needs the cooperation with the mp56/336B external modem.Õ
Command Task
Router#(config)interface serial1/0
Router(config-if-serial1/0)#physical-layer async
Router(config-if-serial1/0)#tx-on dcd Configure the dcd signal to judge physical
signal up.
Router(config-if-serial1/0)#encapsulation terminal
Router(config-if-serial1/0)#modem party originate Set the built-in modem as call origination.
Router(config-if-serial1/0)#dialer string 123 Set the built-in modem as the dialup mode.
Router(config-if-serial1/0)#modem async error-correct Set the built-in modem as error asynchronism.
Router(config-if-serial1/0)#modem enable
Router(config-if-serial1/0)#exit
ÔThe above is the configuration of the dialup mode in which the built-in modem encapsulates the terminal protocol.
The usage of this mode needs the cooperation with the mp56/336B external modem.Õ
B) Configuring Template Parameters:
Command Task
Router(config)#terminal template maipu Establish a template whose name is maipu.
router(config-terminal-template)#terminal local Set the local IP address (the address of the
129.255.24.100 interface f0).
router(config-terminal-template)#terminal remote 0 fix Set service 0 as the fix-terminal mode, the IP
129.255.100.101 fix-terminal address as the IP of the Unix FEP (Front End
Processors).
router(config-terminal-template)#terminal remote 1 Set service 1 as the telnet mode.
telnet 129.255.100.101 telnet
router(config-terminal-template)#terminal remote 2 Set service 2 as the rlogin mode.
rlogin 129.255.100.101 rlogin
router(config-terminal-template)#terminal remote 3 Set service 3 as the echo mode. (Optional)
input 129.255.100.101 fix-terminal 7
router(config-terminal-template)#terminal remote 4 fix- Set service 4 as 2nd fix-terminal mode. In the
2 129.255.100.101 fix-terminal 3052 negotiate-port mode,
3652 Two itests are configured for Unix: data port—
3052, and negotiation port—3652.
router(config-terminal-template)#exit
C) Applying the template to an interface
Command Task
Router(config)# terminal apply maipu serial0/0 Apply the template to the interface s0/0.
Ethernet
Local
MP8100
multiplexer
IllustrationsÖ
The local router accesses the Ethernet through the Ethernet interface and connects with the Unix server. The
synchronous interface, synchronous/asynchronous interface or asynchronous interface encapsulates MPDLC protocol and
connects downwards with MP8100 multiplexer that connects with terminals through sub-interfaces (8 subinterfaces).
o UNIX FEP
Ethernet
Local router
Remote
MP8100
multiplexer
NoteÖ
In the MPDLC mode, the sub-interfaces of MP multiplexer can connect with terminals, prints and card-reader, and can
not support SDLC equipments (such as ATM).
10.2.1 Configuring MPDLC Protocol
To make the router adopt the MPDLC protocol to connect with MP multiplexer, the following steps are necessary:
Creating/configuring a terminal template;
Encapsulating an interface with MPDLC Link protocol
Applying the template to the MPDLC interface
10.2.1.1 Creating/Configuring Terminal Template
The terminal template used by MPDLC protocol is the same as that used by the terminal protocol. About how to create and
configure a terminal template, refer to section 10.1.1.
10.2.1.2 Encapsulating Interface with MPDLC Link Protocol
Configure the command encapsulation mpdlc in the interface configuration mode.
Configure the command mpdlc channel <start-chan> <end-chan> dtr-forced-on according to the physical
performance of the terminal connecting with the sub-interface of the multiplexer×
Partial terminal can not provide DTR signal for the sub-interface of MP8000 series equipments and notify the multiplexer of
whether to connect with the terminal equipment. In this situation, it is necessary to configure the command mpdlc channel
<start-chan> <end-chan> dtr-forced-on to specify some sub-interfaces to connect with the terminal equipments. Thereinto,
start-chan and end-chan represent the start-channel number and the end-channel number respectively. And their value scope
is from 1 to 8.
Note:
1) The router parameters, such as line synchronism/asynchronism, clock, rate and flow-control, must be configured
according to the serial-interface parameters of MP multiplexer;
2) Neither IP address nor other IP parameters is configured on the MPDLC interface.
10.2.1.3 Applying the Terminal Template to a MPDLC Interface
Use the command terminal apply template-name <interface1> <interface2> to apply the terminal template template-name
to all channels of MPDLC interfaces <interface1> ~ <interface2>ç
Similarly, Use the command terminal apply template-name <interface> channel <start-chan> <end-chan> to apply the
terminal template template-name to the specified channels of the interface <interface> ×
NoteÖ
When the terminal template is applied to multiple interfaces, both and must be the two interfaces in the same slot; the
command terminal apply template-name <interface1> <interface2> can be used many times to apply the terminal template
to the interfaces of different slots. An interface can adopt only one terminal template.
10.2.2 An Example of MPDLC Configuration
The local configuration of encapsulating MPDLC: (shown as figure 3)
A) Configuring interface parameters:
Command Task
Router(config) interface serial0/0
Router(config-if-serial0/0)#physical-layer async Configure the interface as the
asynchronous operation mode.
Router(config-if-serial0/0)#encapsulation mpdlc Encapsulate the MPDLC protocol.
Router(config-if-serial0/0)#mpdlc channel 1 8 dtr-force- Enable channel 1-8, and set dtr signal as
on up.
Router(config-if-serial0/0)#exit
ÔThe above is the configuration of encapsulating MPDLC on the high-speed interface. And the configuration of
8/16SA is the same as that of the high-speed interface.Õ
Command Task
Router(config) #interface serial1/0
Router(config-if-serial1/0) # physical-layer async Configure the interface as the
asynchronous operation mode.
Router(config-if-serial1/0)#tx-on dcd
Router(config-if-serial1/0)#encapsulation mpdlc Encapsulate the MPDLC protocol.
Router(config-if-serial1/0)#mpdlc channel 1 8 dtr-force- Enable channel 1-8, and set dtr signal as
on up.
Router(config-if-serial1/0)#modem party answer Set the built-in Modem as the answer
Router(config-if-serial1/0)#modem line leased Set the built-in Modem as the private
line mode.
Router(config-if-serial1/0)#modem async direct Set the built-in modem as the direct
asynchronism mode.
Router(config-if-serial1/0)#modem enable
Router(config-if-serial1/0)#exit
ÔThe above is the configuration of the automatic private line mode in which the built-in modem encapsulates the
terminal protocol. The usage of this mode needs the cooperation with the mp8100 multiplexer.Õ
Command Task
Router#(config)interface serial1/0
Router(config-if- serial1/0)#physical-layer async
Router(config-if-serial1/0)#mpdlc channel 1 8 dtr-force- Enable channel 1-8, and set dtr signal as
on up.
Router(config-if- serial1/0)#encapsulation mpdlc Encapsulate the MPDLC protocol.
Router(config-if- serial1/0)#modem party originate Set the built-in Modem as the call
origination.
Router(config-if- serial1/0)#dialer string 123 Set the phone number the built-in
modem dials.
Router(config-if-serial1/0)#modem async error-correct Set the built-in Modem as the error-
asynchronism.
Router(config-if- serial1/0)#modem enable
Router(config-if- serial1/0)#exit
ÔThe above is the configuration of the dialup mode in which the built-in modem encapsulates the MPDLC protocol.
And the usage of this mode needs the cooperation with the mp8100 multiplexer.Õ
B) Configuring Template Parameters:
The configuration of a template is the same as that of encapsulating the terminal protocol. Only one template can be
defined, and each interface can adopt nothing but one template.
C) Applying the template to an interfaceæ
Command Task
Router(config)# terminal apply maipu serial0/0 Apply the template to the interface s0/0.
10.2.3 Related MPDLC Debugging Commands
show mpdlc
debug mpdlc
10.3 X.3 PAD Terminal
Figure10-5 the X.3 PAD terminal network mode
UNIX FEP
Mp router
X.25 terminal
10.3.1 Configuring the X.3 PAD Terminal
To configure the X.3PAD terminal of the router, the following steps are necessary:
Creating/configuring a terminal template
Configuring X.25 link-layer protocol
Apply the terminal template to X.3 PAD.
10.3.1.1 Creating/Configuring a Terminal Template
The terminal template used by the X.3 PAD terminal is the same as the Terminal protocol. And about how to create and
configure a terminal template, refer to section 10.1.1.
10.3.1.2 Configuring X.25 Link-layer Protocol
Encapsulate X.25 link-layer protocol on the interface and configure the corresponding parameters.
10.3.1.3 Applying a Terminal Template to X.3 PAD
In the global configuration mode, configure the command terminal x.121-addr template-name COM TERM and apply the
terminal template template-name to X.PAD.
Syntax Description
x.121-addr The x.121 address of the remote PAD logon equipment.
template-name The name of the applied terminal template.
COM The COM number (user-defined) for using the function of fix-
terminal.
TERM The TERM number (user-defined) for using the function of fix-
terminal.
10.3.1.4 An Example of X.3 PAD Terminal Configuration
The configuration of the router and related explanation are described as follows:
1) Encapsulating related X.25 parameters (including X.25 address, DCE/DTE operation mode and internal/external
clock) of a WAN interface;
2) The configuration commands of a terminal template are listed as follows:
Command Description
terminal template <Temp-Name> Create/configure a terminal template (the global
mode command).
terminal local <ip-address> Configure the local IP address.
terminal remote <0-9> Host-Name <ip- Configure the remote services: ten different
address>[telnet][rlogin][fix-term] services (09), telnet/rlogin/fix-term mode can be
supported.
terminal hesc-chars Configure the switching character string. And the
default is “Ctrl+G+D”.
terminal rx-delay Set the receiving delay mode. The default mode is
no delay.
terminal rbufsize <32-8192> Set the size of the TCP receiving buffer. The
default size is 2048 bytes.
terminal tbufsize <32-8192> Set the size of the TCP receiving buffer. The
default size is 8192 bytes.
terminal print <on/off> Set terminal print as on: the prompts are printed on
the terminal. The default configuration is ON.
terminal retry-times <1-255> Set the maximal retry-times of establishing a link.
The default value is 3 (times).
3) The coincidence relations among the terminal X.25 source address, terminal template and port number are listed as
follows:
Command Description
terminal <x121-addr> <Temp-name> <com> <x121-addrs> : the X.121 address of the remote
<term> x25 equipment
<termplate-name>:the name of the template used
by the terminal
<com> and <term>: the parameters used by the fix-
terminal. It must be consistent with the
configuration of the application itest.
A configuration example:
Command: Task
Configure the Ethernet address of the
Router#(config)#interface fastethernet0
router.
Router(config-if-fastethernet0)#ip address 10.1.1.1
255.0.0.0
Router(config-if-fastethernet0)#exit
Router(config)#interface serial0/0
Router(config-if-serial0/0)#physical-layer sync Configure the synchronous mode.
Router(config-if-serial0/0)#clock rate 9600 Set the clock rate as 9600.
The interface is encapsulated with the
Router(config-if-serial0/0)#encapsulation x25
X.25 protocol.
Router(config-if-serial0/0)#x25 dte Configure the X.25 dte mode.
Configure the X.121 address as
Router(config-if-serial0/0)#x25 address 1234567
1234567.
Router(config-if-serial0/0)#exit
Router (config) #terminal template maipu Configure the template maipu.
The local address of the template is
Router (config-terminal-template) #terminal local 10.1.1.1
10.1.1.1.
The remote address of the terminal
Router (config-terminal-template) #terminal remote 1 fix-
adopting the fix-terminal service is
terminal 10.1.2.1 fix-terminal
10.1.2.1.
Router (config-terminal-template) #terminal remote 2 The remote address of the terminal
Telnet 10.1.3.1 telnet adopting the telnet service is 10.1. 3.1.
Router (config-terminal-template) #terminal remote 3 The remote address of the terminal
Rlogin 10.1.4.1 rlogin adopting the rlogin service is 10.1.4.1.
-c confile Set the configuration file of itest, and the default is /ect/itest.conf.
Set the maximum number of the login terminals that itest can accept, and the
-n max_term
default is 256.
-p port Set the port number of the itest program service, and the default is 3051.
Set the port number of the itest program management port, and the default is
-m mng_port
3055. Enter the itest managing interface through the access to the port.
-g neg_port Designate the itest log file, the default is /tmp/itest.log.
Define the exit_key for the terminal. For example, use “itest –x 1:1:1” when
-l log_file starting itest, then after pressing CTRL-A-A-A on the terminal, the terminal will
exit.
The timeout the data read from the network is written towards the application
-x exit_key
program (the default is 1 second). Discard it when the time expires.
Shut down the terminal regularly, and make the terminal become invalid within
-w discard_time
the given time.
Configure the identification authentication for the user to enter the management
interface, and there exists no identification authentication by default. The user
-T time_file
name and password used for the identification authentication is that of the
system.
Establish a new session after each time of connection. If the configuration in
-s /ect/inittab is respawn, this option should be selected; if the configuration is off,
then this option should not be selected.
-N Set the configuration file of itest, and the default is /ect/itest.conf.
NoteÖ
1) It is recommended that the two parameters –N and –K be used simultaneously in the execution mode itest –NK. Its
function is to clean the previous process when the terminal logs in again. These two parameters have a certain relation with
the application. And Industrial and Commercial Bank transaction system had better not employ the parameters.
2) The parameterér is used to enable the function of screen redraw. When the terminal switches among the different
services, the function can save the contents of the current screen before switching. To realize the function, the shared memory
of the Unix server should be at least 1.5M. If there appears "...shmget error:Invalid argument” when itest-r is executed, the
following configuration is necessary: to execute “admin--Hardware/Kernel manager—Kernel | Tune Parameters-- 16.Shared
data” to modify the parameter SHMMAXäthe shared memoryå and the value of 2000000(bytes) is recommended. After
configuring the parameter –r, you can adopt “ctrl + R” to manually refresh the screen on the terminal.
3) Parameter –TöIn the view of system security, Itest can provide a function of regularly closing a terminal. In this way,
the terminal can be invalid in the specified time. The user need define a configuration file time.conf, whose format is
described as follows:
all 12:00 13:00 18:00 20:00
All terminals are invalid in 12:00-13:00 and 18:00-20:0. (Up to five time segments can be specified.)
ttyp11:ttyp12 12:00 13:00 The tow terminals ( ttyp11 and ttyp12) are invalid in 12:00-13:00.
When starting Itest, the parameter –T need be specify the file time.conf.
itest –T time.conf
4) Parameter –M: Transform the characters sent by the terminal to other characters according to the corresponding
configuration. And you need define a configuration file keymap.conf , whose format is described as follows:
File format Meanings
4f:50 1b:4f:50 Transform the character 4f:50 to 1b:4f:50.
4f:51 1b:4f:51 Transform the character 4f:51 to 1b:4f:51.
When starting Itest, the parameter –M need be used to specify the file keymap.conf.
itest –M keymap.conf
5) Parameters éc ép ém ég: These parameters are respectively used to specify the configuration files and
program ports for starting itest. Different configuration files and program ports can be used to start multiple Itests.
Command Times
Itest The first time
Itest –c /ect/itest.conf2 –p 3052 –m 3056 –g 3652 –l /tmp/itest.log2 The second time
Thereinto, when starting Itest for the first time, no parameter is specified and the default mode is employed:
Configuration file: /ect/itest.conf
Service port: 3051
Management port: 3055
Negotiation port: 3651
Log port: /tmp/itest.log
When starting Itest for the second time, the following mode is specified:
Configuration file:/ect/itest.conf2
Service port: 3052
Management port: 3056
Negotiation port: 3652
Log port: /tmp/itest.log2
The corresponding configuration files are listed as follows:
Configuration File name
/dev/ttyp11 1.1.1.1 com1 term1 /ect/itest.conf
/dev/ttyp21 1.1.1.1 com1 term1 /ect/itest.conf2
The terminal configuration template of the terminal server are configured as follows:
terminal remote 0 fix1 129.255.24.100 fix-erminal
terminal remote 1 fix2 129.255.24.100 fix-terminal 3052 negotiate-port 3652
6) The usage of Itest timing.
In view of system security, Itest can also provide the powerful ability of time-control that can be used to limit the
working hours and non-working hours. To use the function, you firstly add the configuration of time-access list into the
configuration file itest.conf. And the basic format of the time-access list is listed as follows:
Keyword ID Actio Starting/Ending Starting/Ending Starting/Ending
Number n day/month/year day of week minute/hour
access-list 1 permit 2004.xx.xx-2004.xx.xx 1-5 08:00-12:00
The meaning of each field is described as follows:
Field name Meanings
Keyword It indicates that this row is the configuration of the time-control access.
ID Number The ID number of the time-control access list. The number must be more than 0. And
multiple access lists can use the same ID number. In this way, these access lists can
compose a access list-group and work together.
Action The action can be either Permit or Deny, indicating that the terminal that uses the time-
control list is permitted to go on working or disconnected in the time meeting the
configuration.
Starting/Ending The starting/ending day/month/year is divided by “.”. “X” means any day/month/year.
day/month/year For example, xxxx.5.1 represents 1st may of any year, and 2004.xx.1 represents the first
day of any month in 2004.
Starting/Ending day of The starting day of week and the ending day of week is divided by “-”. “X” means any
week day from Monday to Sunday. For example, “1-5” represents the days from Monday to
Friday.
Starting/Ending The starting time and the ending time is divided by “-”. For example 08:00-12:00
minute/hour represents the time from 8:00am to 12:00am, and 13:30-17:30 represents the time from
13:30pm to 17:30pm.
After the time access-control list is added into the configuration itest.conf, the time control of the terminal can be performed
as long as “acl=xxx” is added behind the configuration corresponding to the terminal to be controlled.
For a group ACL with the same ID, its configuration order is from up to down. The first item of the group takes the leading
effect. It the item matches unsuccessfully, the default action is “Deny”. So the item of stricter time control should be placed
at the front of the group. The terminal to which no ACL is specified can work any time.
The following example represents that the working time of the terminal ttyp5 is 8:00am~18:00pm of Monday ~ Friday,
9:00am~16:00pm of Saturday ~ Sunday, 9:00am~16:00pm in the 7-day holiday of Labor/National Day.
/dev/ttyp5 16.54.1.22 com1 term acl=7
The configuration of other terminals are listed as follows:
access-list 7 deny xxxx.05.01-xxxx.05.07 x-x 00:00-09:00
access-list 7 deny xxxx.05.01-xxxx.05.07 x-x 17:00-23:59
access-list 7 deny xxxx.xx.xx -xxxx.xx.xx 6-7 00:00-09:00
access-list 7 deny xxxx.xx.xx -xxxx.xx.xx 6-7 17:00-23:59
acccess-list 7 permit xxxx.xx.xx-xxxx.xx.xx 1-5 08:00-18:00
Syntax Description
The value is the maximum number of the UNIX system virtual
Pseudo ttys: 256 terminals, and it must be more than the number of the really
existing terminals.
Copy the fix-terminal service program itest.sco and place the copy into the directory “/ect”. If the copy is sent out
through ftp, it must adopt the binary mode.
Syntax Description
chmod 744 itest.sco Add the right to execute it to the user root.
Add the following sentences to the file /ect/rc.d/8/userdef. In this way, when starting, the system will start
itest.sco automatically.
Syntax Description
echo MP-Router Itest starting … The prompt information at
the time of startup
/ect/itest.sco Execute itest.sco.
route add –net 128.255.130.0 –netmask 255.255.255.0 16.28.3.4 The route added into the
router.
Note:
The italic sections of the command route add –net are the addresses of the network segment, at which the router is
located, and the IP address of the up-end router connecting with the network fragment, and its aim is to add a route to the
router to the UNIX server. The factual configuration depends on your concrete network address and IP address.
Create and configure the table itest.conf, then place it at the directory /ect for itest to distribute the terminal
numbers. And its format is listed as follows:
/dev/ttyp11 128.255.130.254 com1 term1
…… …… …… ……
/dev/ttyp18 128.255.130.254 com8 term1
/dev/ttyp21 128.255.130.254 com9 term1
…… …… …… ……
/dev/ttyp28 128.255.130.254 com16 term1
NoteÖ
The meaning of each field in the table above is described as follows:
Fields Meaning
/dev/ttyp11 It is the terminal equipment number distributed for the corresponding
physical port, and the number must exist in the directory “/dev”.
128.255.130.254 The IP address of the router connecting with the terminal (namely the local
address configured on the terminal server)
The serial-interface number (consistent with the value of COM that is
com1
displayed by means of the command show terminal)
The terminal number (consistent with the value of TERM that is displayed
term1
by means of the command show terminal)
Configure the table “/ect/inittab” so as to determine whether to send the login interface to the terminal.
p11:234:respawn:/ect/getty /dev/ttyp11 m
p12:234:off:/ect/getty /dev/ttyp12 m
……
Note:
The meaning of each field in the table above is described as follows:
Field Meaning
p11 The ID domain. It can be defined by users and serve as the parameter
following enable/disable. The manager can use the enable ID to
activate this terminal and send the login interface.
234 The operation level. It specifies that when running in system running
levels 2,3,4, the sentence is valid.
respawn/off The action domain. When users adopt the login mode to log in, the
domain need be configured as respawn, and when users want to send
an application interface to the terminal, the domain need be
configured as off.
/ect/getty /dev/ttyp11 m The command domain. It specifies some action executed for some
port-number. In this example, the login interface is sent to the
terminal ttyp11, and m indicates that the terminal speed is 9600.
Configure the table /ect/ttytype so as to provide the terminal type configuration for application programs. The
format is listed as follows:
Terminal type Terminal number
Vt100 ttyp11
Ansi ttyp21
10.3.2.3 Configuring AIX UNIX
Increase the number of the BSD-style pseudo terminals:
MeansæUse the command smit—Devices—Pty—Change/show Characteristies …— to modify the number of the
BSD-style pseudo terminals more than the number of the really used terminals.
Copy the fix-terminal service program itest.aix and place the copy into the directory “/ect”. If the copy is sent out
through ftp, it must adopt the binary mode.
Command Description
Add the right to execute it to the user
chmod 744 itest. aix
root.
Add the following sentences to the file /ect/rc.tcpip. In this way, when starting, the system will start itest.aix
automatically.
Command Description
The prompt information at the time of
echo MP-Router Itest starting …
startup
/ect/itest.aix Execute itest.aix.
route add –net 128.255.130.0 –netmask 255.255.255.0
The route added to the router.
16.28.3.4
Note:
The italic sections of the command route add –net are the address of the network fragment at which the router is
located and the IP address of the up-end router connecting with the network segment, and the aim of this section is to add a
route to the router to the UNIX server. And the factual configuration depends on your concrete network address and IP
address.
Create and configure the table itest.conf, then place it into the directory /ect for itest to distribute the terminal
numbers. Its format is as follows:
/dev/ttyq0 128.255.130.254 com1 term1
…… …… …… ……
/dev/ttyq7 128.255.130.254 com8 term1
/dev/ttyq8 128.255.130.254 com9 term1
…… …… …… ……
/dev/ttyqf 128.255.130.254 com16 term1
NoteÖ
The meaning of each field in the table above is described as follows:
Field Meaning
It is the terminal equipment number distributed to the corresponding
/dev/ttyq0
physical port, and it must exist in the directory /dev.
The IP address of the router connecting with the terminal (namely the local
128.255.130.254
address configured on the router)
The serial-interface number (consistent with the value of COM that is
com1
displayed by means of the command show terminal)
The terminal number (consistent with the value of TERM that is displayed
term1
by means of the command show terminal)
Configure the table /ect/inittab so as to determine whether to send the login interface to the terminal:
Q1:234:respawn:/usr/sbin/getty /dev/ttyq1
Q2:234:off:/usr/sbin/getty /dev/ttyq2
……
NoteÖ
The meaning of each field in the table above is described as follows:
Field Meaning
The ID domain. It can be defined by users and serve as the parameter
Q1 following penable/pdisable×The manager can use the penable ID to
activate this terminal and send the login interface.
The operation level. It specifies that when running in system running levels
234
2,3,4, the sentence is valid.
The action domain. When users adopt the login mode to log in, the domain
respawn/off need be configured as respawn, and when users want to send an application
interface to the terminal, the domain need be configured as off.
/usr/sbin/getty The command domain. It specifies some action executed for some port-
/dev/ttypq1 number. In this example, the login interface is sent to the terminal ttyp11.
Configure the table /ect/ttytype so as to provide the terminal type configuration for applications. The format is
described as follows:
Terminal type Terminal number
Vt100 ttyq1
Ansi ttyq2
……
10.3.2.4 Configuring SUN UNIX
Increase the number of the SUN system pseudo terminals. The default number of the SUN system pseudo
terminals is 48. To increase the number, you can do according to the following steps (in this example, increasing
the pseudo terminal number to 128):
A. Adding this line set npty=128 at the place of the file /ect/system where the core variable is
changed.
B. Edit the file /ect/iu.ap, and modify ptsl 0 47 ldterm ttcompat as ptsl 0 127 ldterm ttcompat.
C. Execute the command boot –r to restart the system.
Copy the fix-terminal service program itest.sun and place the copy into the directory /ect. If the copy is sent out
through ftp, it must adopt the binary mode.
Command Description
chmod 744 itest.sun Add the right to execute it to the user root.
Add a startup execution file Sitest (Noticing the capital letter S) into the directory of /ect/rc3.d, and add the right to
execute it so that the fix-terminal service program itest.sun can start when the system starts. The contents of the
file are described as follows:
Command Description
echo MP-Router Itest starting … The prompt information at the time of startup
/ect/itest.sun Execute itest.sun.
route add –net 128.255.130.0 – Add the route to the router/terminal server.
netmask 255.255.255.0 16.28.3.4
NoteÖ
1) The italic sections of the command route add –net are the address of the network fragment at which the router is
located and the IP address of the up-end router connecting with the network segment, and the aim of this section is to add a
route to the router to the UNIX server. And the factual configuration depends on your concrete network address and IP
address.
2) In the SUN system, when the types of machines are different, some files may well run abnormally. The corresponding
execution file need be regenerated according to its type. To do it, please communicate with the technical staff of our company.
Create and configure the table itest.conf, then place it into the directory /ect for itest to distribute the terminal
numbers. Its format is listed as follows:Ö
/dev/ttyq0 128.255.130.254 com1 term1
…… …… …… ……
/dev/ttyq7 128.255.130.254 com8 term1
/dev/ttyq8 128.255.130.254 com9 term1
…… …… …… ……
/dev/ttyqf 128.255.130.254 com16 term1
NoteÖ
The meaning of each field in the table above is described as follows:
Field Meaning
It is the terminal equipment number distributed for the corresponding
/dev/ttyq0
physical port, and it must exist in the directory /dev.
The IP address of the router connecting with the terminal (namely the
128.255.130.254
local address configured on the terminal server)
The serial-interface number (consistent with the value of COM that is
com1
displayed by means of the command show terminal)
The terminal number (consistent with the value of TERM that is
term1
displayed by means of the command show terminal)
Configure the table /ect/inittab so as to determine whether to send the login interface to the terminal.
Q1:234:respawn:/usr/lib/saf/ttymon –g –h –p “`uname –n`login: ” -T ansi –d /dev/ttyq1
Q2:234:off:/usr/lib/saf/ttymon –g –h –p “`uname –n`login: ” -T ansi –d /dev/ttyq2
……
NoteÖ
The meaning of each field in the table above is described as follows:
Field Meaning
Q1 The ID domain. It can be defined by users and serve as the parameter
following penable/pdisable×The manager can use the penable ID to
activate this terminal and send the login interface.
234 The operation level. It specifies that when running in system running
levels 2,3,4, the sentence is valid.
respawn/off The action domain. When users adopt the login mode to log in, the
domain need be configured as respawn, and when users want to send
an application interface to the terminal, the domain need be configured
as off.
/usr/lib/saf/ttymon –g –h –p The command domain. It specifies some action executed for some
“`uname –n`login: ” -T ansi port-number. In this example, the login interface is sent to the terminal
–d /dev/ttyq1 ttyp11. (“`” of “`uname –n`” is not a single quotation marks but an
inverse single quotation marks)
Configure the table /ect/ttytype so as to provide the terminal type configuration for applications. The format is
described as follows:
Terminal type Terminal number
Vt100 ttyq1
Ansi ttyq2
10.3.2.5 Configuring HP UNIX
Increase the number of the HP system pseudo terminals. To increase the number of the system pseudo terminals,
you can do according to the following steps (in this example, increasing the pseudo terminal number to 128):
Use the command smitty and select “Devices Æ PtyÆChange/Show Characteristies”, modify the number of the
BSD-style pseudo terminals as 128.
Copy the fix-terminal service program itest.hp and place the copy into the directory /ect. If the copy is sent out
through ftp, it must adopt the binary mode.
Command Description
chmod 744 itest.sun Add the right to execute it to the user root.
NoteÖ
In the HP system, when the types of machines are different, some files may well run abnormally. The corresponding
execution file need be regenerated according to its type. To do it, please communicate with the technical staff of our company.
Add a sentence into startup execution file /sbin/rc so that the fix-terminal service program itest.hp can start when
the system starts. The added contents are described as follows:
Command Description
echo MP-Router Itest starting … The prompt information at the time of startup
/ect/itest.hp Execute itest.hp.
Create and configure the table itest.conf, then place it into the directory /ect for itest to distribute the terminal
numbers. Its format is listed as follows:Ö
/dev/ttyq0 128.255.130.254 com1 term1
…… …… …… ……
/dev/ttyq7 128.255.130.254 com8 term1
/dev/ttyq8 128.255.130.254 com9 term1
…… …… …… ……
/dev/ttyqf 128.255.130.254 com16 term1
NoteÖ
The meaning of each field in the table above is described as follows:
Field Meaning
It is the terminal equipment number distributed for the corresponding
/dev/ttyq0
physical port, and it must exist in the directory /dev.
The IP address of the router connecting with the terminal (namely the
128.255.130.254
local address configured on the terminal server)
The serial-interface number (consistent with the value of COM that is
com1
displayed by means of the command show terminal)
The terminal number (consistent with the value of TERM that is
term1
displayed by means of the command show terminal)
Configure the table /ect/inittab so as to determine whether to send the login interface to the terminal.
Q1:234:respawn:/usr/lib/saf/ttymon –g –h –p “`uname –n`login: ” -T ansi –d /dev/ttyq1
Q2:234:off:/usr/lib/saf/ttymon –g –h –p “`uname –n`login: ” -T ansi –d /dev/ttyq2
……
NoteÖ
The meaning of each field in the table above is described as follows:
Field Meaning
Q1 The ID domain. It can be defined by users and serve as the parameter
following penable/pdisable×The manager can use the penable ID to
activate this terminal and send the login interface.
234 The operation level. It specifies that when running in system running
levels 2,3,4, the sentence is valid.
respawn/off The action domain. When users adopt the login mode to log in, the
domain need be configured as respawn, and when users want to send
an application interface to the terminal, the domain need be configured
as off.
/usr/lib/saf/ttymon –g –h –p The command domain. It specifies some action executed for some
“`uname –n`login: ” -T ansi port-number. In this example, the login interface is sent to the terminal
–d /dev/ttyq1 ttyp11. (“`” of “`uname –n`” is not a single quotation marks but an
inverse single quotation marks)
Notice:
After some kernel parameters are changed in some Unix systems (such as the SCO system), the kernel parameters need
to be reconnected. Because each time the kernel is reconnected, the system will use “/ect/conf/cf.d/init.base” to conver
init.base automatically, and and the manual configuration of the table will be lost. Thereby, after finishing the configuration,
you should backup the table inittab. As long as you copy the table inittab to cover init.base, then the inittab configuration
will not be lost when the system reconnects
In the course t, after itest started up, the modification made in the table itest.conf can not take effect immediately unless
using the command refresh in the managing mode
Whenever the configuration of the table inittab has been modified, to make the modification take effect in the situation
UNIX doesn’t restart, you must use the command init q to make the system scan the table again.
Once some Unix systems start up, they will occupy the pseudo terminals. So when the table itest.conf is configured, the
pseudo terminal number should start behind the pseudo terminal number occupied by the system. And it is recommended that
some numbers should be reserved.
10.3.2.6 Adjusting UNIX Kernel Parameters
When many terminals are connected with the UNIX server and there exist many services, it may occur that the default kernel
resource of the server isn’t enough, which will result in various kinds of bugs. To ensure the system to run securely and
reliably, each kernel parameter of the UNIX server need be reconfigured and the distributed quantity of the relevant resource
should be increased.
Take how to adjust default kernel resource of the SCO UNIX 5 as an example:
Run netconfig and modify the two SCO parameters included by TCP/IP
Parameter Meaning
The maximum connection number. In the version itest v3, each Itest
TCP connections :
terminal occupies a TCP connection after login. Because other system
1024 applications can also occupy TCP connections, so it is recommended that
the parameter value is configured as more than 1024.
The number of the system virtual terminals. It is recommended that the
Pseudo ttys Ö256
number is more than 256.
Run the command scoadmin-Hardware/Kernel Manager-Kernel|Tune Parameters… to enter the menu of the core
parameters setting:
Select 7. Use the command User and group configuration to modify the following parameters:
Parameter Meaning
The maximum number of the files each process can open. For every
terminal in the version itest v3, after the terminal logs in, the number of
NOFILES
the files opened by the process itest increases 2. It is recommended that
the parameter should be 3 times of the number of terminals.
The maximum number of the processes. Because the system itself
MAXUP occupies some processes, it is recommended that the parameter value
should be more than 800.
Select 12. Use the command Streams to modify the following parameters:
Parameter Meaning
The number of the stream header structures. If there are more than 150
NSTREAM terminals to be configured, it is recommend that the parameter should be
configured as 6000.
The number of the pages. 4k per page. If there are more than 150
NSTRPAGES terminals to be configured, it is recommend that the parameter should be
configured as 3000.
If this value is too little, the stream buffer of the system will become
STRSPLITFRAC scraps soon. So it is recommend that the parameter should be configured
as 80.
Select 3. Use the command TTYs to modify the following parameters:
Parameter Meaning
The number of the character table buffers. it is recommend that the
NCLIST
parameter should be configured as 2048.
Notice:
The command netstat –m can be executed to examine the usage of the system stream resource. When some item occurs
FAIL, the values of the parameters NSTREAM and NSTRPAGES need be increased.
When there exists the prompt “Too many open files” in /tmp/itest.log, the value of the parameter NOFILES need be
increased.
10.3.2.7 TELNET Fix-terminal
To realize the fixation of terminal equipment-number for TELNET, use the function of TELNET fix-terminal. For example,
to fix the connection that adopts the telnet mode between 128.255.2.2 and the service port of Itest as “ttyp21”, add the
following row of configuration to the configuration file itest.conf:
/dev/ttyp21 128.255.2.2 comx termx
Notice that what following com and term must be “x”. and the other configuration (such as the configuration of the table
inittab) is the same as that in the fix-terminal mode.
To telnet the fix-terminal from the rotuer, add the option telnet into the template configuration of the router. And Itest service
port 3051 need also be added. For example:
terminal remote 5 tel 129.255.11.110 telnet 3051
To telnet the fix-terminal from a PC, execute the following command:
telnet 129.255.11.110 3051
multiple terminals can be distributed to one IP address. For example, use the following the command to distribute
ttyp21Øttyp22 and ttyp30 to 128.255.8.8:
/dev/ttyp21 128.255.8.8 comx termx
/dev/ttyp22 128.255.8.8 comx termx
/dev/ttyp30 128.255.8.8 comx termx
NoteÖ
When multiple telnet terminals are distributed to one IP address, it can be realized that only network terminal
equipments can be fixed.
10.3.2.8 Itest Terminal Management
Itest is a multi-process service program that brings some difficulties for process management, so the management control is
enhanced in the program. The management process of itest runs on the TCP interface 3055(Use the parameter -m to specify
other port) and enters the management mode.
Execute on the Unix:
telnet localhost 3055
telnet 127.0.0.1 3055
Execute on the remote terminal:
telnet ip-address 3055 Ip_addr is the IP address of the UNIX server.
By default, no username or password need be input for logging in the management port. To limit login,
In the default situation, a user can log in the managing port without inputting the user name and password. The command
itest –s can be used to limit users logging in when itest starts. In this way, when a user wants to log in the management port,
he will be asked to input his user name and password. Different users have different management rights, while the user root
have all rights.
After the user enters the management mode, the prompt itest> is displayed; and the command help can be used to examine
the command format:
Command Description
help Display the command and the simple prompt.
task Display the status of each task.
kill Kill the terminal process (This command can be executed only
by the root user).
disable Disable a certain terminal.
enable Enable a certain terminal.
term Display all the effective configuration read from the file
itest.conf.
pid Display the process number corresponding to each terminal.
time Display the configuration of shutting down a terminal
regularly.
refresh Refresh the file itest.conf. The command of itest4.5 or higher
version can support adding/deleting/modifying the contents of
itest.conf. And the command of previous version can only
support adding the contents of itest.conf.
debug Monitor the terminal information.
undebug Stop monitoring the terminal information.
stop Stop the itest service, namely killing all the itest processes
(This command can be executed only by the root user).
exit Exit from the management mode, but the service itest still
goes on operating.
NoteÖ
Data compression: Add compress behind comx termx of the file itest.conf. For example:
/dev/ttyp18 128.255.130.254 com8 term1 compress
Data encryption and compression: Add both “keyéx” and compress behind comx termx of the file itest.conf.(There
exists no requirement to the order of the added items) For example:
/dev/ttyp18 128.255.130.254 com8 term1 compress
Encryption compression and address authentication: Add both “keyéx”, compress and mac behind comx termx
of the file itest.conf.(There exists no requirement to the order of the added items) For example:
/dev/ttyp11 128.255.130.254 com1 term1 compress keyÙa mac 3601000004d9
An integrated example:
/dev/ttyp11 128.255.130.254 com1 term1 compress keyÙa mac 00017a00a792
…… …… …… ……
/dev/ttyp18 128.255.130.254 com8 term1 compress key=a
/dev/ttyp21 128.255.130.254 com9 term1 keyÙa
…… …… …… ……
/dev/ttyp28 128.255.130.254 com16 term1 compress
10.4.4 Examples of New/Old Configuration of Maipu Router
A configuration file in the old configuration mode:
mp2600# show running-config
….
line 0 15 mode terminal
….
line 0 15 flowctl soft 180
terminal 0 15 local 129.255.8.43
terminal 0 15 remote 0 unix-1 129.255.24.100 fix-terminal authentication
terminal 0 15 host 0 hesc-chars 8
terminal 0 15 hesc-chars 1
terminal 0 15 redraw console \E!9Q
terminal 0 15 redraw 0 \E!10Q
terminal 0 15 rbufsize 1024
terminal 0 15 tbufsize 2048
terminal 0 15 rx-delay on
terminal 0 15 print off
terminal 0 15 auto-linking 0
terminal 0 15 enable
A configuration file in the new configuration mode:
The interface is configured as follows:
mp2600#sho run int a4/0
Building Configuration...
Current configuration:
interface async4/0
speed 9600
databits 8
stopbits 1
parity none
flow-control software 180
tx-on dsr
encapsulation terminal
exit
The terminal template is configured as follows:
terminal template itest43
terminal local 129.255.8.43
terminal remote 0 unix-1 129.255.24.100 fix-terminal authentication compress encrypt a
terminal remote 1 telnet-unix 129.255.24.100 telnet
terminal remote 2 rlogin-unix 129.255.24.100 rlogin
terminal hesc-chars 1
terminal host 0 hesc-char C
terminal host 1 hesc-char P
terminal host 2 hesc-char V
terminal redraw console \E!8Q
terminal redraw 0 \E!9Q
terminal redraw 1 \E!11Q
terminal rbufsize 4096
terminal tbufsize 10000
terminal retry-times 6
terminal rx-delay on
exit
Apply the template to the interface:
terminal apply itest43 async4/0 async4/15
Chapter 11 Security Configuration
This chapter will describe how to operate the security configuration of your MP2600 Router.
1. PPP protocol supports (PAP and CHAP), which effectively prevents unauthorized connections.
2. Callback technology.
3. An IP protocol layer providing firewall protection, which filters unauthorized data packets.
4. Network Address Translation (NAT), which can hide your interior network and prevent exterior network attacks.
5. Access Control Lists (ACL), which can sort end users into up to 15 different classes depending on your needs. These
lists register a different series of commands available to individual users. They ensure that users with different rights will
only be able to access certain commands.
6. Encryption and key exchange technologies
A standard access list can filter your network communications based on packet header source addresses. You can define a
standard access list with within the access-list command, and delete it at any time by placing the no command in front of the
command in global configuration mode.
router(config)#access-list ?
Command Description
<1001_2000> The number range used in an extended access list.
<1_1000> The number range used in a standard access list.
router(config)#access-list 1 ?
Command Description
Deny Denies access.
Permit Permits access.
router(config)#access-list 1 deny ?
Command Description
A.B.C.D The format of the source address
Any The short form of the source address 0.0.0.0 and
the source address wildcard 255.255.255.255
Host The short form of the source address 0.0.0.0.
router(config)#access-list 1 deny A.B.C.D ?
Command Description
A.B.C.D Wildcards applied to source address are
expressed with dotted decimal notation. This
masks rebel code. If a bit is marked 1, that
means that the bit is indifferent.
router(config)#access-list 1 deny A.B.C.D a.b.c.d ?
Command Description
Log Logs output to the console about the access list.
This is an optional function.
To define a standard access list:
router(config)#access-list access-list-number list number, number<1_1000> for a standard access list
Command Description
{deny | permit} source [source-wildcard] [log] Source: the source address.
Source-wildcard: the source address’s wildcard.
Deleting an access list:
Command Description
router(config)#no access-list list-number This deletes an access list.
List-number: the deleted access list’s number.
You can define a standard access list named after a title or serial number with the following codes:
(You can delete this list by placing no in front of the command code part that’s in bold type.)
router(config)#ip access-list ?
Command Description
Extended Designates an extended access list definition.
Standard Designating a standard access list definition.
router(config)#ip access-list standard ?
Command Description
<1_1000> List number
WORD List name
Command Description
router(config-std-nacl)#?
Command Description
Deny Denies access, if the conditions in the access list
aren’t successfully met.
End
Exit
Help
No
Permit Permits access, if conditions in the access list are
successfully met.
router(config-std-nacl)#deny ?
Command Description
A.B.C.D Source address.
Any Source address 0.0.0.0 255.255.255.255
Host Source address 0.0.0.0
router(config-std-nacl)#deny A.B.C.D ?
Command Description
A.B.C.D The wildcard applied to the source address.
Command Description
router(config)#ip access-list standard {name | Defines a standard access list in global
access-list-number} configuration mode.
router(config-std-nacl)#{deny | permit} source Defines a rule in the list in access list
[source-wildcard] [log] configuration mode.
router(config-std-nacl)#no {deny | permit} source Deletes a rule from the list
[source-wildcard] [log]
Example: Construct an access list named number 2 (see following table), then define three rule items and apply this list 2 to
Ethernet interface 0. Among the packets from Ethernet interface 0, those packets that come from the host 92.49.0.3 in the
subnet 92.49.0.0 will be allowed. All the packets from any host within the subnet 92.48.00 will be permitted, too. All
others will be denied.
Command Task
router(config)# access-list 2 permit host 92.49.0.3 Permits the packets from the host IP 92.49.0.3
log in the subnet 92.49.0.0.
router(config)# access-list 2 permit 92.48.0.0 Permits all packets from any host in the subnet
0.0.255.255 92.48.0.0.
router(config)# access-list 2 deny any Denies other packets.
router(config)# interface ethernet 0
router(config-if-ethernet)# ip access-group 2 in Applies list 2 to Ethernet interface 0.
Use the following series of commands when only one rule is to be deleted:
Command Task
router(config)# ip access-list standard 2
router(config-std-nacl)# no permit host 92.49.0.3 log
router(config-std-nacl)# exit
An extended access list can be used to filter IP communications not only according to the source address and the destination
address of the packet header, but also according to the fields included into the IP, UDP, TCP, ICMP and IGMP packet
headers.
The command router71(config)#access-list 1001 ? 1001-2000 indicates an extended access list.
Command Description
Deny Denies access.
Permit Permits access.
You can define an extended access list on a number in extended access-list format.
You can delete the list with the no command in global configuration mode.
access-list access-list-number {deny | permit} protocol source source-wildcard [operator port [port]] ] destination
destination-wildcard [ICMP-type] [igMP-type] [operator port [port]] [ack / fin / established / psh / rst / syn / urg] [precedence
precedence] [tos tos] [log]
Syntax Description
Access list number List number
Protocol Protocol
Source Packet source address
Source-wildcard Source address wildcard
Destination Packet destination address
Destination-wildcard Destination address wildcard
Precedence Priority
TOS Type of service
Log Record permit or deny packets in the logging at
several minutes interval
ICMP-type Message type of ICMP
IGMP-type Message type of IGMP
Operator Port Comparison
Port Port
Port Number Port number
Ack / fin / established / psh / rst / syn / urg TCP flag bit
You can define an extended access list based on a name or a number according to the following steps. (You can delete the
whole list with the no command in global configuration mode.)
ip access-list extended {access-list-number/name}
Syntax Description
access-list-number An access list number, always a decimal number
between 1001 to 2000
[no] {deny | permit} protocol source source-wildcard destination destination-wildcard [precedence precedence] [tos tos] [log]
Syntax Description
Deny Denies access.
Permit Permits access.
Protocol The protocol’s name or number. It may be one
of the following keys: ICMP, IGMP, IP, TCP or
UDP. Or it is expressed with a decimal number
between 0 and 255. The IP keyword can match
any protocol.
Source The host or network that the packet is coming
from, namely the source address of the packet.
It can be expressed three ways: the first is through
dotted decimal notation. The second is through
the any keyword, which is the short form of the
source address 0.0.0.0 and the source address
wildcard 255.255.255. Thirdly, this can be
expressed as the host source, or the source address
with the 0.0.0.0 wildcard.
Source-wildcard The wildcard applied to the source address. It
can be expressed three ways. The first is
through dotted decimal notation, or the network
mask rebel code. (The bit marked 1 means that
that bit is indifferent.) The second way this can be
expressed is through the any command, which is
the short form of noting the source address 0.0.0.0
and source address wildcard 255.255.255.255.
Thirdly, this can also refer to the host source,
which stands for the source address and the
source address with the 0.0.0.0 wildcard.
Destination The destination network or a host, namely the
destination’s address. It can be expressed three
different ways, like the source address above.
Please refer that definition.
Destination-wildcard The wildcard applied to the destination address. It
can be expressed three different ways, like the
source address wildcard above. Please refer to
that definition.
Precedence The packet priority. It can be ranked by in
number from 1 to 7, or the name of a priority.
(The titles within can include: critical, flash,
flash-override, immediate, internet, network,
priority and routine.). Optional function.
TOS The packet service type. It can contain a number
from 0 to 15 or the name of a service type (The
titles within it can include: max-reliability, max-
throughput, min-delay, min-monetary-cost and
normal). Optional function.
LCMP-type The message type of an ICMP packet. It can be
expressed through a number from 0 and 255 or
the name of a message type. Optional function.
LCMP-code The code type of an ICMP packet message type,
which can be expressed with a number from 0 and
255. Optional function.
IGMP-type An IGMP packet message type that can be
expressed with a number from 0 and 255.
Optional function.
Operator Used to compare a source port and a destination
port. There are five kinds of values that can be
compared between the two ports: less than, more
than, equal to, unequal to, and range. If the
operational character comes after the source
address and the source address wildcard, it is
applied to the source port. If the operational
character comes after the destination address and
the destination address wildcard, it is applied to
the destination port. Optional function.
Range Used to define when the operator demands two
port-numbers, and other operators demand one
port number.
ack, fin, psh, rst, syn, ur Used to match the TCP flag bit, including:
Acknowledgement flag, finishing flag, promptly
sending flag, restoration flag, synchronization
flag, and urgency flag. Optional function.
Established Indicates successful connection. If the TCP packet
contains ACK or RST, the packet will be
matched. Only the packet for initial connection
isn’t matched. Optional function.
Name Refers to the name of an access list. The name is
used to distinguish it from other lists. It can’t
include any blank characters and the first
character must be a letter.
When the access list log switch is open, the number of items displayed by each rule in the global configuration mode by
default is, at best, 0. This means the number of displayed items isn’t limited.
Command Description
router(config)# firewall verbose-limit number A number from 0 to 4,294,967,295.
router(config)# firewall default-deny Denies all packets. In the global configuration mode,
the default setting will automatically be set to deny
all packets.
Command Description
router(config)# ip record-route Permits packets with a route recording option.
In the global configuration mode, the default
will permit the packet with an IP recording
route option (ie. recording routing or time
label).
router(config)# no ip record-route Denies all packets with a recording route
option.
To filter all source routing packets:
Command Description
router(config)# ip source-route Permits all packets with source routing.
In the global configuration mode, the default setting
will permit a packet that has an IP source route
option (ie. lose source routing or strict source
routing).
router(config)# no ip source-route Denies packets with a source route option.
To filter a directional broadcast packet:
Command Description
router(config-if-xxx)# ip directed-broadcast Permits the interface to send a directional
broadcasting packet.
router(config-if-xxx)# no ip directed-broadcast Denies the sending of a directional
broadcasting packet. In the interface
configuration mode, the default setting will
deny a directional broadcasting packet.
To permit an interface or a sub-interface to send a mask-reply ICMP packet:
Command Description
Router(config-if-xxx)# ip mask-reply Permits an interface to send an ICMP mask-
reply packet.
Router(config-if-xxx)# no ip mask-reply Denies the sending of an ICMP mask-reply
packet.
In the interface or sub-interface
configuration mode, the default setting will
refuse to send an ICMP mask-reply packet.
To permit an interface or a sub-interface to send an ICMP redirecting packet:
Command Description
router(config-if-xxx)# ip redirects Permits the interface to send an ICMP
redirecting packet.
In the interface or sub-interface configuration
mode, the default setting permits the
interface to send an ICMP redirecting packet.
router(config-if-xxx)# no ip redirects Doesn’t allow the interface to send an ICMP
redirecting packet.
To permit an interface to send an ICMP unreachable packet:
Command Description
router(config-if-xxx)# ip unreachables Permits the interface to send an ICMP
unreachable-packet. In the interface or sub-
interface configuration mode, the default
setting will permit the interface to send an
ICMP unreachable-packet.
router(config-if-xxx)# no ip unreachables Doesn’t allow the interface to send an ICMP
unreachable-packet.
After a packet is received to the inward standard access list, the packet source address will be checked against the access list.
On an extended access list, the firewall will check fields such as the destination address and protocol other than the source
address. If the packet is permitted by the access list, the routing software will process it successively. If the packet isn’t
permitted, the software will lose the packet and will send an ICMP unreachable-packet to the source address.
After the packet is received and routed to an interface, to the outward standard access list, the firewall software checks the
packet source address against the access list. To an extended access list, the firewall checks fields like destination address
and protocol (and so on) along with the source address. If the packet is permitted by the access list, the routing software
will transmit it. Otherwise, the software will discard the packet and will send an ICMP unreachable-packet to the source
address. Note: If you haven’t built an access list, all packets coming through the interface will be permitted.
For example, you can apply the extended access list 1,001 to the inward Ethernet interface 0 and the standard access list to
the Ethernet outward interface 0. Then exit the interface configuration mode.
Command Task
router(config)# interface ethernet 0
router(config-if-ethernet0)# ip access-group 1001 in Applies the extended access list 1,001 to the
inward Ethernet interface 0.
router(config-if-ethernet0)# ip access-group 10 out Applies the standard access list to the outward
Ethernet interface 0.
router(config-if-ethernet0)# exit
11.1.4 Monitoring And Maintaining Your Firewall
To display the contents of an access list in the privileged user mode:
router# show access-lists [access-list-number / name]
Syntax Description
access-list-number / name The access list number or name.
If you don’t input a name or number, all of your access lists will be displayed.
To show certain access lists, input:
router# show access-lists
Output result:
Extended ip access list: 1001
permit ICMP any any 8 0 log 4 matches
permit tcp any any syn log 1 matches
Extended ip access list: 1002
permit ICMP any any echo-reply log 4 matches
permit tcp any any established log 4 matches
Here, the matching times correspond to the filtered packet-matching rule.
To display the an access list application to the interfaces:
router#sh ip int list
Output result:
Interface fastethernet 0
Outgoing access list is 2
Inbound access list is 1
Interface serial 2
Outgoing access list is not set
Inbound access list is 1001
To clear the access list counter in the privileged user mode
router# clear access-list counters [access-list-number | name]
Without a name or number, all access list counters will be cleared. You can use the following command to clear access-list
counters:
router# clear access-list counters
To show access lists, input:
router# show access-lists
Output result:
Extended ip access list: 1001
permit ICMP any any 8 0 log 0 matches
permit tcp any any syn log 0 matches
Extended ip access list: 1002
permit ICMP any any echo-reply log 0 matches
permit tcp any any established log 0 matches
Note: Because the counter was set with a value of 0, the matching time is 0.
You can also monitor and maintain the firewall by examining an access list log. Log records include information such as
the source address, the destination address, the protocol type, the port number, and the sending and receiving interfaces, et
cetera. To access this function, input:
1) Many interface channel rules should be configured in a certain order based on priority.
2) Try to avoid simultaneously configuring a series of interfaces with channel rules. If a data packet passes through
two interfaces with channel rule configurations, the data won’t be permitted through the system until it passes
examination by both sets of rules.
3) Please do not configure a firewall and an access channel on the router at the same time. This will cause a major
malfunction.
4) An access channel can only adapt to a simple set of conditions. For more complex rules, please configure a
firewall based on an access list. (Please refer to Section 1.1).
router
f0 s0
Outer network A network
Subnet1
e0
123.56.7.0/24
Subnet2
Host 1 Host 2
123.45.6.7 123.45.8.9
Example 1:
Please examine Figure 2. If you want all the machines in the interior subnet1 and subnet2 to have permission to access the
exterior host1 and host2, you would input the following configuration code:
Command Task
router# config terminal
router(config)# interface serial 0 Configures the interface s0.
router(config-if-serial0)# access-tunnel 123.45.6.7 Accesses host1’s access channel.
255.255.255.255 directly
router(config-if-serial0)# access-tunnel 123.45.8.9 Accesses host2’s access channel.
255.255.255.255 directly
router(config-if-serial0)# exit
router(config)# exit
Because the direct orientation access channel is configured on the interface s0, that interface will check whether or not the
source address matches the channel address when s0 receives a data packet. When such a message is sent to the system, the
destination address will be checked and the unmatched address packet will be denied.
Example 2:
Please examine the following Figure 2. If you want subnet1 to access host 1, host 2 and the exterior network subnet
123.56.7.0/24 without restricting subnet 2’s access, you would input the commands below. Note: In this example, the
access channel can’t be set on the exterior interface s0 – it should be set on the interface f0, which is connected to the subnet1.
Command Task
router# config terminal
router(config)# interface f0 Configures the interface f0.
router(config-if-fastethernet0)# acce 123.45.6.7 Accesses host1’s access channel.
255.255.255.255
router(config-if-fastethernet0)# acce 123.45.8.9 Accesses host2’s access channel.
255.255.255.255
router(config-if-fastethernet0)# acce 123.56.7.0 Accesses network 123.56.7.0’s access code.
255.255.255.0
router(config-if-fastethernet0)# exit
router(config)# exit
All the time-based demands you might have can be met through defining a time range in the router and activating security
mechanisms to bind that time range to the packet filtering process.
Time Range
A time range is, simply, a set of time segments of your choosing that allows users to access the network. There are
two kinds of time segments: a relative time segment and an absolute time segment. The former refers to a weekly
segment. The latter refers to a segment covering a certain date (ie. x month, x day, x year).
Displaying a time range’s status: Whether the time range works or not depends on its current status (ON or OFF),
regardless of the filtering rule or access list the time range might be bound to. That current status will also
correspond to its respective time segment status
Clearing or changing a time range status: A time range will be cleared within a minute in default mode. You may
have to wait up to 60 seconds before any of your changes are applied to the system.
A Cisco router permits an absolute time segment rule within a time range, while a Maipu router can allow many
absolute time segment rules within the system. The absolute time in Cisco systems is a genuine form of absolute time
and the date must be set according to a rigorous format: day, month and year. But Maipu router products tells time
in a kind of relative way, so the month and year in a date can be omitted.
Packet filtering will work only when the time range status is ON. The command format is consistent with Cisco’s
setup. For example:
Command Task
Permit any log time-range t_r_name1
Access-list 1001 deny TCP any any time-range
t_r_name2
Add the time range name at the bottom of your filtering rules. Its position comes after the log file, just like in Cisco’s
router systems. Note: There isn’t a special command that you can use to cancel the binding relationship. If you
want to cancel the command, you first have to delete the filtering rule and then resubmit the same rule without
imputing a time limit.
When the router compares a data packet against the filtering rules, the trange term will not participate in this
matching process. In fact, when a time range is bound to two filtering rules, the rules are considered to be the same
by the router. If there were two different filtering rules for the same task in an access list, then the time limit rule
would not work at all.
Filtering:
Whether a filtering rule that’s bound to a time range will work or not is dependant on the time range’s current status.
When a data packet is filtered, each filtering rule in the access list you’ve applied will be matched against it one by
one. If a filtering rule is bound to the time range, and the time range status is OFF, then the rule will be skipped in
the system and the next filtering rule will be matched against it.
Note: If the current time-range status is set to OFF, all of the bound time ranges will not work. (Please refer to
Chapter 5, Environment Parameters.) All of the filtering rules, no matter whether they are bound to time ranges or
not, will participate in the filtering procedure.
Your can remove the binding by using the command no. Note: When this type of access list filters a packet, the status of
the time range should be the first thing to be examined by the system. If the status of the bound time range is set to OFF, all
of the filtering rules will be ignored and this access list will be considered the equivalent of an empty list by the system.
The timelive time inverse accumulated counter default frequency is set at one minute.
The counter and system time difference is, by default, 100 seconds.
When the default switch value is ON, every bound entity will have a time limit. If the status of the switch is set to
OFF, every bound time range will not work, and all clauses with the name “time-range” to will be ignored by the filter.
(To the access list, the binding relationship won’t even exist.) The switch’s status value is stored at the global
variable named trange_enable.
Command:
Command Description
Set time-range disable [OFF]: Once the switch is set to OFF, the time
range refreshing process that’s running in the
background will be aborted.
Set time-range enable [ON]
11.1.7 Media Access Control (MAC) Address Packet Filtering
The MAC address can filter the source address of a data packet at the interface level.
The main contents of this section are:
Setting An Access List
Adding Filter Rules
Binding An Interface.
Command Description
permit|deny any | host macaddress | macaddress This command can be executed in the access
macmask list configuration mode. You can delete a
rule with the using the no command.
Note: The second mode listed in the preceeding table [Access-list number permit deny] can also be used to add a filtering
rule. (When using this command with a Cisco system, you can add an access list and a filtering rule. However, Cisco
only provides a command to delete an access list. It doesn’t provide a corresponding command to delete a filtering rule.)
Command Task
router(config)#mac access-list standard 2002
router(config-std-mac-nacl)#permit host 1.1.1
router(config-std-mac-nacl)#permit 2.2.2 0.0.ffff
router(config-std-mac-nacl)#deny any
C. Binding An Interface:
A binding can be configured in the interface mode. You can use the no command to remove it.
Command Description
mac access-group number|name in|out
The following case of simple configuration is used to describe the configuration and usage of the reflect access list.
)
)
3&B$ 3&B%
To realize that PC_A can access PC_B and PC_B has no way to access PC_A, MP router should be configured as follows:
Syntax Descriptions
router# config terminal
router(config)# ip access-list extended 1001 Define the extended
access list 1001.
router(config-ext-nacl)# permit host 129.255.43.2 host 128.255.43.2 reflect Define the reflect access
AtoB list AtoB.
router(config-ext-nacl)# exit
router(config)# ip access-list extended 1002
router(config-ext-nacl)# evaluate AtoB
router(config-ext-nacl)# exit
router(config)# interface fastethernet1
router(config-if- fastethernet1)# ip access-group 1001 in
router(config-if-ethernet)# exit
router(config)# interface fastethernet0
router(config-if- fastethernet0)# ip access-group 1002 in
router(config-if- fastethernet0)# exit
Related configuration:
1) Configure a direct-connection server:
If the user can not pass the user authentication successfully, all packets of the user are denied. But some connection
with some servers, such as DHCP server, DNS server and authentication server must be permitted. A system manager
can, through the router, perform the direct-connection configuration of those servers and packets communicating with the
servers are permitted to pass:
Use the following command to configure a server.
flux-control server [addr1 addr2…….]
Use the following command to delete some direct-connection server:
no flux-control server [addr1 addr2….]
, QW HU L RU
L QW HU I DFH Dummy packet coming from
source address
If the packet was filtered when it was sent out through a router, some information will be lost. This means that the interior
network can easily be attacked by a user with a fake (or dummy) address, as shown in the preceding figure.
In that figure, the network 135.12.0.0 is connected to the Internet through a router. That interior network has two subnets.
The network subnet masks to both subnet 10 and 11 have the following address: 255.255.255.0. A packet from the fake IP
address 135.12.10.201 is shown coming from an exterior TCP/IP host. It is then received by the router’s exterior interface.
If the router is set to filter incoming data packets, the dummy packet will be quickly noticed and it will be prevented from
entering the network. Since the router knows that the network 135.12.10.0 is connected to a different (ie. interior) interface,
it knows the packet can’t be coming from an exterior interface. But if the packet filter is only set to examine the outgoing
data packets, the router won’t be able to check the exterior interface and the message from the dummy address will enter the
network.
In order to add more security to your network, you can add some ‘anti-cheat’ rules to your incoming access list to bind the
filter to an exterior interface. The aim of this is to tell the router to refuse both interior network source addresses and invalid
source addresses. Invalid source addresses can include a non-registered address, a loop-back address and a broadcasting
address. Hackers often use these types of source addresses to prevent them from being tracked and discovered by a network
manager.
The following commands can be added to the inward access list that is applied to your exterior interfaces. They will prevent
some dummy IP addresses.
access-list 1001 deny ip 135.12.10.0 0.255.255.255 any (an interior network)
access-list 1001 deny ip 135.12.11.0 0.255.255.255 any (an interior network)
access-list 1001 deny ip 10.0.0.0 0.255.255.255 any (a reserved IP address)
access-list 1001 deny ip 172.16.0.0 0.31.255.255 any (a reserved IP address)
access-list 1001 deny ip 192.168.0.0 0.0.255.255 any (a reserved IP address)
access-list 1001 deny ip 127.0.0.0 0.255.255.255 any (a reserved IP address)
access-list 1001 deny ip 224.0.0.0 31.255.255.255 any (a reserved IP address)
These anti-cheat rules should be stored in your system before any other rules on the inward access list. This will ensure that
only packets containing a valid IP address will be checked against the remaining rules.
11.1.11 Examples
Example 1:
, QW HU L RU Router
H V , QW HU QH
QHW ZRU N
([W HU L RU W
131.44.0.0 131.44.1.1
QHW ZRU N
Note: The above example shows a network with the following security policies in place:
All interior network hosts (131.44.0.0) can access any TCP Internet service.
Exterior hosts can access the SMTP service in the mail gateway 131.44.1.1, but can’t access the interior network
itself.
All ICMP messages will be blocked.
These policies can be configured on the router by imputing the following series of commands:
Command Task
router# config terminal
router(config)# ip access-list extended 1001 Defines an extended access list as 1,001.
router(config-ext-nacl)# permit TCP 131.44.0.0
0.0.255.255 any
router(config-ext-nacl)# permit ICMP any
131.44.0.0 0.0.255.255
router(config-ext-nacl)# exit
router(config)# access-list 1002 permit TCP any
131.44.0.0 0.0.255.255 established
router(config)# access-list 1002 permit TCP any
host 131.44.1.1 eq 25
router(config)# interface ethernet 0
router(config-if-ethernet0)# ip access-group 1001 in
router(config-if-ethernet)# exit
router(config)# interface serial 0
router(config-if-serial0)# ip access-group 1002 in
router(config-if-serial0)# exit
router(config)#
Example 2
1. You can’t overlap a global IP address with a local one, and only three kinds of local addresses are recommended:
Kind Task
To define an IP address pool, use the global configuring command ip nat pool.
router(config)#ip nat pool name start-ip end-ip {netmask netmask | prefix-length prefix-length}
[type rotary]
Syntax Description
Name The Address Pool Name
start-ip The Start Address
End-ip The End Address
Netmask Network Mask
prefix-length The network mask digits signify which mask all
addresses in the pool belong to.
type rotary Indicates that the address pool scope has true
hosts addresses. A TCP load will be assigned
based to these hosts. (Optional function.) This
pool type is only applied to incoming address
NAT configuration.
Command Description
router(config)#no ip nat pool name Deletes the address pool.
Note: The same address pool can’t be referred to by two different NAT configurations. If two NAT definitions must be
incorporated together, make sure you alter the corresponding access list rules. Also, the same IP address cannot be defined
in two different pools. You may cause the system to malfunction if you do.
To build an interior source address NAT, use the global configuring command ip nat inside source.
To delete a static or dynamic translation, use the command format no ip nat inside source.
Construct a basic static translation with the static key.
router(config)#ip nat inside source list {access-list-number | name} pool name [overload]
Syntax Description
access-list-number The access list name or number
Name The address pool name
Overload Enables the router to use a global address in the
place of many local addresses. When the
overload parameter is configured, the TCP or
UDP port number of each interior host is used to
distinguish different sessions where the same
local IP address was used. (Optional function).
router(config)#ip nat inside source static {tcp | udp} local-ip local-port global-ip global-port
Syntax Description
local-ip Interior local address
global-ip Interior global address
tcp | udp Protocol
local-port Interior local port number
global-port Interior global port number
To start using the incoming NAT, type in the global configuring command ip nat inside destination.
To delete a dynamic translation, input no ip nat inside destination.
When the incoming NAT is used to share the TCP load use:
router(config)#ip nat inside destination list {access-list-number | name} pool name
Syntax Description
Pool name The pool name. The pool contains a local address
assigned in dynamic translation. The pool type is
ROTARY, and the pool address is a true interior
local host address.
To designate an interior or exterior NAT interface, use the interface configuring command ip nat.
To remove this function, enter no ip nat.
Note: You can’t use an interior and exterior interface at the same time.
router(config-if)#[no] ip nat {inside | outside}
Syntax Description
Inside Designates the interface to connect with the
interior network.
First, construct a static translation from 192.168.8.1 to 203.25.25.1. Configure the Ethernet interface 0 to an interior
interface. Configure the serial 0 to an exterior interface.
Command Task
router(config)#ip nat inside source static Constructs a static translation from 192.168.8.1 to
192.168.8.1 203.25.25.1 203.25.25.1.
router(config)#interface e0 Designates the interface e0.
router(config-if-ethernet0)#ip nat inside Connects the marked interface to an interior
network
router(config)#exit
router(config)#interface s0 Designates the interface s0
router(config-if-serial0)#ip nat outside Connects the marked interface to an exterior
network
NAT configuration:
, QW HU L RU ([W HU L RU
6$
6$
'$
H V
, QW HU QHW
'$
+RVW %
je e
k 1$7 7DEO H
, QW HU L RU O RFDO , QW HU L RU JO REDO
, 3 DGGU HVV , 3 DGGU HVV
Command Task
router(config)#ip nat pool pl-1 203.25.25.1 203.25.25.20 Constructs a global address pool with the name
netmask 255.255.255.0 pl-l. The pool includes 20 global addresses from
203.25.25.1 to 203.25.25.20.
router(config)#access-list 1 permit 192.168.8.0 Constructs an access list 1 and allows the
0.0.0.255 network segment addresses 192.168.8.0 and
0.0.0.255 to be translated.
router(config)#ip nat inside source list 1 pool pl-1 Performs the address translation between list 1
and pool –1.
router(config)#interface e0 Designates the interface e0.
router(config-if-ethernet0)#ip nat inside Connects the marked interface with the interior
network
router(config-if-ethernet0)#exit
router(config)#interface s0 Designates the interface s0.
router(config-if-serial0)#ip nat outside Connects the marked interface with the exterior
network
router(config-if-serial0)#exit
router(config)#
In the preceding case, a global address pool pi-1 is first constructed. The pool includes 20 global addresses between
203.25.25.1 to 203.25.25.20. The access list 1 permits all hosts in the interior network to perform address translation. The
Ethernet port 0 is configured as an interior interface and the serial is configured as an exterior interface.
Note: The access list must permit these addresses to be translated. An access list that permits too many addresses
translations could allow a security breach or other type of malfunction.
, QW HU L RU '$
([W HU L RU
6$
6$
+RVW %
H V
'$
, QW HU QHW
j e
e k 1$7 7DEO H
3U RW , QW HU L RU O RFDO , QW HU L RU JO REDO ([W HU L RU JO REDO +RVW &
RFRO , 3 DGGU HVV 3RU W , 3 DGGU HVV 3RU W , 3 $GGU HVV 3RU W
7&3
7&3
In order to overload global addresses on the router, as shown in the preceding figure, the router must be configured as
follows:
Command Task
router(config)# ip nat pool pl-2 203.25.25.1 203.25.25.5 Builds a global address pool called pl-2. The
netmask 255.255.255.0 pool includes five global addresses between
203.25.25.1 and 203.25.25.5.
router(config)# access-list 1 permit 192.168.8.0 Permits access list 1 to perform the address
0.0.0.255 translation to all hosts in the interior network.
router(config)# ip nat inside source list 1 pool pl-2 Allows the access list 1 and the address pool
overload pl-2 to build a dynamic source translation.
router(config-if-ethernet0)# exit
router(config)# interface s0 Designates the interface s0
router(config-if-serial0)# ip nat outside Marks the above interface as exterior.
router(config-if-serial0)# exit
router(config)#
In this example, the global address pool pl-2 is built first. The pool includes five global addresses between 203.25.25.1 and
203.25.25.5. The access list 1 permits all hosts in the interior network to perform an address translation. The Ethernet
port 0 is configured as an interior interface, while serial 0 becomes an exterior interface. The router then allows many local
addresses to use a global address.
Note: If there is only one interior host being used, it isn’t necessary to perform dynamic NAT configuration. If you want to
use NAT to hide the host IP address, then configure your router using static NAT. Because dynamic NAT only works for
TCP data packets, you’d be better off using static NAT configuration – especially if your host provides other protocol
services.
You can alter NAT timeout with the global configuring command ip nat translation.
You can return to the default setting with the command no ip nat translation.
router(config)#ip nat translation ?
Command Description
Dns-timeout
finrst-timeout Ends and resets the TCP packet translation
timeout. The default setting is 60 seconds.
iMPs-error The ICMP error packet translation timeout.
The default setting is 60 seconds.
ICMP-timeout The ICMP packet translation timeout. The
default setting is 300 seconds.
port-timeout
syn-timeout The initiative TCP packet’s translation timeout.
The default setting is 90 seconds.
tcp-timeout The TCP port translation timeout. The default
setting is 1,800 seconds (30 minutes).
Timeout The simple dynamic translation timeout. The
default is 1,800 seconds (30 minutes).
udp-timeout The UPD port translation timeout. The default
is 600 seconds (10 minutes).
router(config)#ip nat translation timeout ?
Command Description
<1_2147483647> Timeout
Never Never timesout
Example:
Command Task
router(config)#ip nat translation timeout 120 Sets the timeout function to 120 seconds.
2) You can display the active translation list item with the privileged user command show ip nat translations.
Command Task
router#show ip nat translations
The following are output examples of the preceding command:
You can use the global addresses 128.255.251.84 and 128.255.251.85 to communicate with some exterior hosts
without overloading.
router# show ip nat translations
Dir Pro Hv0 Hv1 Inside global Inside local Outside global Age
out --- 426 982 128.255.251.85 192.168.0.2 128.255.251.90 1783
out --- 425 981 128.255.251.84 192.168.0.2 128.255.251.89 1761
Dir Pro Inside global:Port Inside local:Port Outside global:Port Flags
in ---- 201.10.10.1 10 .0 .0 .90 228.255.255.99
in ---- 201.10.10.2 10 .0 .0 .97 129.55.9.3
You can use one global address to perform an address translation by overloading.
router# show ip nat translations
Dir Pro Hv0 Hv1 Inside global Inside local Outside global Age
out ICMP 850 16 128.255.251.86:1027 192.168.0.2:44080 128.255.251.90:44080 295
out ICMP 849 15 128.255.251.86:1026 192.168.0.2:44080 128.255.251.89:44080 288
Note: Translate 192.168.0.2 into 128.255.251.86 to access the exterior address 128.255.251.90/89.
Dir Pro Inside global:Port Inside local:Port Outside global:Port Flags
in ---- 201.10.10.1æ1026 10 .0 .0 .90æ2347 228.255.255.99æ23
in ---- 201.10.10.1æ1027 10 .0 .0 .97æ3455 129.55.9.3æ21
Field Description
Dir Creates the translation’s packet direction.
Pro Recognizes the overload translation protocol.
Hv0 Hv1 The NAT record location.
Inside global The interior global IP and its port
Inside local The interior local IP and its port
Outside global The exterior global IP and its port
Age The remaining lifetime of the NAT record, told in
seconds.
3) You can display the NAT statistics with the privileged user command show ip nat statistics. Clear them by
typing clear ip nat statistics.
router# show ip nat statistics
Information Description
NAT version: 5.6
Total translations: 0 static, 2 dynamic
No memory: 0, Execcess drop: 0, Age1: 0, Age2:
0, Age3: 0
Translation mode: NATNAPT
NAT redirect enable
Outside interfaces: fastethernet0 Exterior interface f0
Inside interfaces: serial2 Interior interface s2
Hits: 73 Misses: 7
Expired translations: 3
Dynamic mappings:
-- Inside Source
access-list 1 pool p1 refcount 2
pool p1: netmask 255.255.255.248 The address pool uses the defined rules from
access list 1.
start 128.255.251.83 end 128.255.251.86
type GENERIC, total addresses 4, allocated 1 ,
misses 0
flags: ipN_MAP ipN_OVERLOAD
Fragment statistics: Totals: 0 Had-existeds: 0 No-
memorys: 0
Hits: 0 Expireds: 0 News: 0
Ftp proxy session: Totals: 0 Hits: 0 No-
memorys: 0
4) You can display all NAT address pools with the privileged user command show ip nat pool.
router# show ip nat pool
Information Description
Address pool : p1
start : 128.255.251.83
end : 128.255.251.86
netmask : 255.255.255.248
type : GENERIC
Note: The redirect switch is specially set by the NAT for OICQ applications, and users between the interior and exterior
network won’t be able to communicate with each other directly. The router’s NAT provides the special switch function to
establish direct communication between users, based on its application. The problem can be overcome, though, by
transferring the OICQ server.
The default switch configuration will be set to ON. If you don’t need this function, you can turn the switch off. You can
open the switch again with the following command:
Command Task
router(config)# ip nat redirect
2. Debug Commands
command Task
router#debug ip nat To see all the informations of NAT
router#no debug ip nat Close debug ip nat command
router#debug ip nat packets Display the information in detail of IP packets before and after
translation
router#no debug ip nat packets Close debug ip nat packet command
The following configuration command can make a number of interior network hosts use just one negotiated IP address to
access the Internet.
Command Task
router(config)# access-list 1 permit 192.168.12.0 Defines access list 1 and enables it to
0.0.0.255 permit the addresses in the network
segment to be translated.
router(config)# ip nat inside source list 1 Builds the dynamic source address
interface serial0 overload translation between list 1 and port s0.
router(config)# interface e0 Designated a LAN interface e0.
router(config-if-ethernet0)# ip address
192.168.12.1 255.255.255.0
router(config-if-ethernet0)# ip nat inside Defines the NAT for a LAN interface.
router(config-if-ethernet)# exit
router(config)# interface s0 Designates the WAN interface s0.
router(config-if-serial0)# physical-layer async
router(config-if-serial0)# speed 38400
router(config-if-serial0)# flow-control hardware
router(config-if-serial0)# encapsulation ppp Encapsulates PPP.
router(config-if-serial0)# ip address negotiated Starts PPP/IPCP address negotiation.
router(config-if-serial0)# ppp pap sent-username Starts PAP authentication.
xxx password xxx
router(config-if-serial0)# no keepalive
router(config-if-serial0)# ip nat outside Defines NAT for WAN interface.
router(config-if-serial0)# exit
router(config)#
B. Configuration Commands
Command Description
router (config)#acl-group number Number <1 to 100>
interface interface number Binds a service area by defining the access group and
the interface it can have access to.
router (config)#acl-group number user Binds a user and a local area by defining an access
user names group user.
routerA(config)#user root password 0 Sets the super user.
password
router (config)#user usernames password Sets the common user.
0 password
Note: The super user account is the root account.
Note: After the command has been configured, the user will be forbidden from logging into a router.
Note: Common users are prohibited from using the system until the above commands are used. Once you’ve added these
commands to the system, users will be able to read/write information to/from it (or just read or write information
individually).
C. Examples of Subnet Isolation
The following figure illustrates a network with subnet isolation security policies in place:
Server A Server B
Area A Area B
routerB S1 S1 routerC
X.25
pc pc
net net
A B
Subnet isolation
After the X25 firewall is configured between router B and router C, as shown in the preceding figure, we can accomplish the
following tasks:
1. User MaipuA can’t access any interface and other equipment in access area B, such as server B.
2. User MaipuB can’t access any interface and other equipment in access area A, such as the interface S1 in router C.
3. If user MaipuA tries to log in to a router from netB, he or she will be denied access.
4. Users, except the super user, cannot telnet again after they have already accessed a router by that method. This is
an optional function and it can prevent a second login.
The dataflow based on the port number or MAC address of a PC NIC (Network Interface Card) can be prohibited. For
example, if you first use arp to bind the MAC address of a PC network card to an IP address, you can then define the
dataflow of the IP address through an access list. This way, only one fixed PC can access the network segment, even if their
IP address has been modified.
Configuring routerA:
Command Task
routerA#
routerA#con t
routerA(config)#interface serial3
routerA(config-if-serial3)#physical-layer sync
routerA(config-if-serial3)#encapsulation x25
routerA(config-if-serial3)#x25 dce
routerA(config-if-serial3)#x25 address 18
routerA(config-if-serial3)#x25 map ip 1.1.1.2 16
routerA(config-if-serial3)#clock rate 19200
routerA(config-if-serial3)#lapb dce
routerA(config-if-serial3)#ip address 1.1.1.1
255.255.255.0
routerA(config-if-serial3)#exit
routerA(config)#interface serial3.1
routerA(config-if-serial3.1)#x25 map ip 5.5.5.2 13
routerA(config-if-serial3.1)#ip address 5.5.5.1 Sets a sub-interface
255.255.255.0
routerA(config-if-serial3.1)#exit
routerA(config)#acl-group 1 interface fastethernet0 Binds Server A to an area.
serial3
routerA(config)#acl-group 2 interface ethernet0 Binds Server B to an area.
serial3.1
routerA(config)#acl-group 1 user MaipuA Binds the local area to MaipuA.
routerA(config)#acl-group 2 user MaipuB Binds the local area to MaipuB.
D. Other Applications
Example 1: In the following figure, MP2600 connects to the other two routers through firewall X25. S1 is connected to
Router A and S2 is connected to Router B. Here, we want to separate the network into two isolated areas.
F0 E0
MP2600
S1 S2
Area 1 Area 2
X.25
Router A Router B
After the X.25 firewall on each router is correctly configured, the subnet isolation function on the MP2600 router will be
successfully completed.
Command Task
MP2600(config)# acl-group 1 interface Binds Area 1 and Access Group1.
fastethernet0 serial1
MP2600(config)# acl-group 2 interface Binds Area 2 and Access Group 2.
ethernet0 serial2
Example 2: As shown in the following figure, the network is to be separated into four unattached areas. Users in each
department include:
Access area 2
Market Dept Developing Dept
F0 E0
INTERNET
Access area 1 MP2600
S3
Technology support Dept Finance Dept
Access area 3
Case One: The Marketing Department and Technical Department can access each other. No other department can access
each other.
Case Two: After a period of time, the business depicted here gets an Internet connection, and its managers wants all
departments except Finance to get Internet access. This requirement can be met when interface S3, which connects directly
to the Internet, is added to the corresponding configured access area.
Command Task
MP2600(config)# acl-group 1 interface Binds interface serial 3 with access group 1.
serial3
MP2600(config)# acl-group 2 interface Binds interface serial 3 to access group 2.
serial3
Access Area 1 and Access Area 2 can now formally connect to the Internet. However, the data packet from Access Area 3
is denied at the router because Interface S2 and S3 aren’t in the same access area. The Internet data packet, similarly, can’t
get to Access Area 3 through Interface S2. Thus, simple isolation technology can ensure the information security of some
important departments.
Example 3: As shown in the following figure, an enterprise network is distributed throughout a series of different access
areas. But Areas 1 and 2 are separated from each other and they can’t access each other. (The broken line in the following
figure shows that the access areas on the two routers are configured separately from each another.)
MP2600A(config)#int s2.2
MP2600A(config-if-serial2.2)#ip address
192.168.2.1 255.255.255.0
MP2600A(config-if-serial2.2)#x25 map ip
192.168.2.2 2220
Sets up the IP address on the S2.2 interface and
MP2600A(config-if-serial2.2)#exit
designates the address at the opposite end.
MP2600B(config)#int s2.1
MP2600B(config-if-serial2.1)#ip address
192.168.1.2 255.255.255.0
MP2600B(config-if-serial2.1)#x25 map ip
192.168.1.1 1110
Sets up the IP address on interface S2.1 and
MP2600B(config-if-serial2.1)#exit
designates the IP address at the opposite end.
MP2600B(config)#int s2.2
MP2600B(config-if-serial2.2)#ip address
192.168.2.2 255.255.255.0
MP2600B(config-if-serial2.2)#x25 map ip
192.168.2.1 1110
Sets up the IP address on Interface S2.1 and
MP2600B(config-if-serial2.2)#exit
designates an IP address at the opposite end.
Step Three: Add a user to the user group in the corresponding access area.
As shown in the preceeding Example Two, you can add a user to the corresponding group. The users in Area 1 should be
added to Group 1 and Group 3, and users in Area 2 should be added to Group 2 and Group 4. Please refer to Case Two for
details on how to set up these users.
If the root user doesn’t perform any operation, he or she can only examine the router configuration and perform other
operations that don’t have an effect on the router’s operation.
router(config)# acl Maipu:
Command Description
acl_ifgrp Assigns acl set up rights.
acl_usergrp Assigns acl set up rights.
address_set Assigns interface configuration rights.
del_startup Assigns file configuration deletion rights.
reload Assigns system file reloading rights.
sif_maker Assigns sub-interface set-up rights.
st_route Assigns static routing adding rights.
sysupdate Assigns system upgrade rights.
telnet_twice Assigns second login rights.
Example:
Command Task
router(config)#acl Maipu reload This command grants the user Maipu the
right to reset a router.
Note: Only root users can perform the acl operation and alter the configuration freely on the router. So please be sure to
change the root password from ‘Maipu’ to something new as soon as possible.
router(config)#crypto IPsec ?
Command Description
Enable Opens the security association and enables it to
work.
Df-bit Define means of processing df bit in an encapsulated
packet.
security-association Sets security association attributes.
spd Defines a security policy database.
Transform-set Defines a set of encryption algorithms.
Notes:
1. The IPsec fuction won’t work until the IPsec switch is open. The default setting leaves the switch open.
2. When IPsec is closed, all operations related to IPsec are invalid until the command open is used.
3. If the IPsec function running on one terminal is closed, then IPsec functions running on other terminals must be
closed in order to the network to formally communicate.
Note: The following commands become effective simultaneously to both IPsec and IKE.
Command Task
router(config)#crypto config-bynet permit Permits remote configuration. (Default setting.)
router(config)#no crpto config-bynet permit Forbid remote configuration.
An Encryption Access List is used to define which IP package should be encrypted, and which one shouldn’t.
In global configuration mode, the following commands are used to create an Encryption Access List:
router(config)#access-list access-list-number { deny | permit } protocol source source-wildcard destination destination-
wildcard [precedence precedence] [tos tos] [log]
Syntax Description
access-list-number Access list number
Protocol Protocol
Source Source address
source-wildcard Source address wildcard
destination Destination address
destination-wildcard Destination address wildcard
Precedence Priority
tos Service type
log Log
router(config)#ip access-list extended name
Syntax Description
Name The access list name
Note: Users facing a complex configuration stuation can refer to the following points:
1. We recommend configuring the mirror-map encryption access list to the IPsec function specified by each static
encryption map defined on the local peer. You should also define a new mirror-mapping encryption access list on
the remote-end peer at the same time.
2. The encryption access list isn’t used to decide whether a message is permitted or not allowed to pass through your
interface. It only decides which communications coming through the interface should be examined for security
reasons and which ones shouldn’t. Not until you apply the access list straight to the interface and construct the
corresponding security association will your decisions go into effect.
3. Avoid using the any command. For instance, using it with the permit command will cause all data entering the
router to be encapsulated by IPsec, and so some information unencapsulated, e.g. routing update information and
control information, may be discarded silently.
4. Use an IP access list specified by number or name. Remember: IPsec runs only on extended access lists.
5. The encryption access list that has had a permit function performed on it will allow all IP communication that
meets specified conditions to be protected by the corresponding encryption map’s rules. On the other hand, the
deny command may prevent the communication from being encrypted.
6. Presently, the access list’s port configuration number doesn’t support scope configuration, so the port number must
be specified or be the default number.
7. After the corresponding encryption map is defined and applied to an interface, the specified encryption access list
will be applied to the interface. Different access lists must be applied to the different entry in the same encryption
map. These tasks will be discussed in the following section (Section 6). But the information coming in and out
of the system will be judged by the corresponding IPsec access list, so the access list perameters can be applied to
messages leaving or entering the router.
8. There should be at least one permit sentence in the IPsec access list. When the access list is used in translation
mode, there must be one permit sentence in the access list. The source address and destination address must be
consistent with the security peer’s corresponding addresses. The host address can’t be a network address or
wildcard.
A translation set is a combination of different special security protocols and algorithms. You can configure one of these sets
with the following commands:
Use the following commands in global configuration mode: (Note: executing these command will let you enter you into
encryption transform configuration mode.)
Note: Illegal combinations should be avoided when transformation sets are created.
1. Two or more transformation sets of the same class, such as esp-des and esp-blf, are illegal combinations. Two
transformations in the same column of the Table 11-5-1 aren’t permitted to be present.
2. The ESP authentication algorithm can’t be applied alone. It must be applied with the ESP encryption algorithm
complied to rfc2406.
3. The ESP encryption algorithm complied to rfc2406 can be applied not only with the ESP authentication algorithm,
but also on its own. If the encryption algorithm esp-null command is chosen, then just one kind of ESP
authentication algorithm must be configured. The following are feasible translation combinations:
ah-sha-hmac
esp-des
esp-des and esp-md5-hmac
ah-sha-hmac and esp-des and esp-sha-hmac
Command Task
router(config)#cry ips tr mytrans1 ah-sha-hmac Defines the transformation set mytrans1.
esp-des esp-md5-hmac
router(cfg-crypto-trans)#exit
router(config)#cry ips tr mytrans2 esp-des esp-sha- Defines the transformation set mytrans2.
hmac
router(cfg-crypto-trans)#exit
router(config)# no cry ips tr mytrans2 Deletes the transformation set mytrans2.
Two transformation sets have been configured: the transform set mytrans1 has three functions – namely ah-sha-hmac, esp-
des and esp-md5-hmac – and when that set is applied, both AH authentication and des encryption&MD5 hash of ESP can
be performed. The transformation set mytrans2 has two functions, namely esp-des and esp-sha-hma, and when the
transformation set is applied, ESP des encryption with sha hash can be performed. The last command deletes the transform
set mytrans2.
In the encryption transformation configuration mode, you can apply a transformation set mode:
Command Description
router(cfg-crypto-trans)#mode [tunnel][transport] [tunnel][transport] (Optional function). Designates
ÔOptionalÕ either a transform set mode, a tunnel mode or a
transport mode. The default setting is in tunnel
mode. Change the mode relative to the translation
set. The mode configuration is useful only when a
message’s source addresses and destination
addresses have been set to an IPsec peer address, and
it is invalid to all other communication. (All other
messages can be performed in the tunnel mode.)
Command Description
router(cfg-crypto-trans)#mode tran Sets the transport mode.
The global lifetime is applied when a new IPsec security association is negotiated. It can be used to build the IKE security
association.
Notes:
1. The default settings of the IPsec SA global lifetime are 3,600 seconds and 4,608,000KB. (This will transmit data
at 10Kbs for an hour.)
3. Changing the global lifetime won’t effect existing security associations. It will, however, be applied to the
successive security association negotiation. (That is, the lifetime set in the security encryption map that is in use.)
You can create an encryption map based on the following rules and operations:
Which communication do you want IPsec to protect? (Consider creating an Encryption Access List, as explained
in Section B.)
Where will the messages protected by IPsec be sent? Who will the remote-end IPsec peer? (Please see Section B
for more details.)
Which IPsec security policies should be applied to messages? Select one from a list of transformation sets.
There are two kinds of encryption map entry. They are either used to manually building an IPsec security association or by
IKE negotiation. Both types can exist in the same map set.
You can apply the encryption map to the interface so that they can judge all IP communication through the interface. In
order to make IPsec between its two peers a success operation, their encryption maps must contain configuring code that’s
compatible between each other. When two peers try to build a security association, one peer must have an encryption map
that’s compatible with the other. In order to be compatible, these maps should at least meet the following conditions:
They must contain compatible Encryption Access Lists, such as a mirror mapping access list.
They must preform the same transformation functions.
1. Manually Create An SA Encryption Map
You can plan a manual seurity association between the local router and IPsec peer manager, so both will be able build the
security association manually whenever they want. The encryption map must be created in order to build the SA manually.
Use the following commands in global configuration mode:
To designate the encryption map that will be created or altered, use this command to enter the encryption-map configuration
in global configuration mode:
Command Description
router(config)#crypto map map-name Map-name: the encryption map set name
seq-num IPsec-manual seq-num: the map entry number
To have the encryption map build a message’s security association manually, use this command:
Command Description
Router(config)#cry map mymap 1 IPsec-m This command creates an encryption map entry whose
number is 1. Add the item to the encryption map set
mymap. If the encryption map set doesn’t exist, then
create a new one named mymap. Finish the
command and enter encryption mapping configuration
mode.
Note: An encryption map can only be appointed to one encryption access list, and vice-versa.
Example: If the security access list 1234 is configured in advance (see the following table), then the first command applied
to the access list 1234 will result in the encryption map’s configuration. The second command cancels this operation.
Command Task
router(cfg-crypto-map)#match addr 1234 Designates an extended access list.
router(cif-crypto-map)#no matc addr Removes a chosen extended access list.
The preceding command will designate a remote-end IPsec peer, too. The message protected by the IPsec will be sent to the
peer. (Only one peer must be specified in manual configuration mode.)
Note: Designate the proper transformation set in completing the preceeding task. The set must be the same as the one
appointed by the remote-end peer. (A transform set must be specified when it is configured manually.)
Example:
Command Task
router(cfg-crypto-map)# set tran mytrans1 Designates the encryption map to use the translation
set mytrans1.
Note: If the specified transformation set includes an AH protocol, then the command is used to set the AH security
parameter index (SPIs) and password for the protected in/outbound message. (This command specifies that the AH security
association will be used to protect the message.) The appropiate in or outbound configuration must be performed.
The following length of key data string MUST be at least double of the least key length needed, for example, when the least
length of key is 16 bytes, the length of key string you input must be at least 32 and even.
router(cfg-crypto-map)#set sess in ah 300 1 The data key must be an even number of characters.
The key length must be even.
router(cfg-crypto-map)#set sess in ah 300 12 The data key bit length is too short. It needs to be
at least 16 bytes, when the AH hash algorithm is
AH-MD5-HMAC.
router(cfg-crypto-map)#set sess in ah 300 12 The data key bit length is too short. It needs to be
at least 20 bytes, when the AH hash algorithm is
AH-SHA-HMAC.
router(cfg-crypto-map)#set sess in ah 300 12 Warning: no translation set needs this key. It will
appear when the encryption transformation set
doesn’t use the AH hash method.
Note: If the specified transformation set includes an ESP protocol, then the preceeding command is used in encryption
mapping configuration mode to set AH security parameter indexes (SPIs) and password for the protected in or outbound
message. If the transformation set includes ESP encryption algorithm, then the encryption key should also be provided.
If the transformation set includes an ESP authentication algorithm, then the authentication key should be provided. (The
command specifies that an ESP security association will be used to protect the message.)
Examples:
Command Task
router(cfg-crypto-map)#set sess inb esp 2222 cipher When the ESP hash algorithm is ESP-
1234567890abcdef auth MD5-HMAC.
12345678901234567890123456789012
router(cfg-crypto-map)#set sess out esp 2223 cipher When the ESP hash algorithm is ESP-
1234567890abcdef12 auth MD5-HMAC.
1234567890123456789012345678901234
router(cfg-crypto-map)#set sess inb esp 2222 cipher When the ESP hash algorithm is ESP-
1234567890abcdef auth SHA-HMAC.
1234567890123456789012345678901234567890
router(cfg-crypto-map)#set sess out esp 2223 cipher When the ESP hash algorithm is ESP-
1234567890abcdef12 auth SHA-HMAC
1234567890123456789012345678901234567890
router(cfg-crypto-map)#set sess in esp The data key is too short by at least 20 bytes. When the
300 cipher 1234567890123456 au 12 ESP hash method is ESP-SHA-HMAC, the length must
be at least 20 bytes.
When IKE is used as a security association, new security association parameters (or uses) can be negotiated among IPsec
peers. Namely, the encryption map can be specified.
Step One: Use the following command in global configuration mode to enter the security encryption map configuration:
Command Description
router(config)#crypto map map-name map-name: name of the encryption map set
seq-num IPsec-isakmp seq-num: the entry number
IPsec-isakMP: IPsec-isakmp indicates this is a
security encryption map used by IKE.
Step Two: Designate an extended access list for the encryption map.
Command Description
router(cfg-crypto-map)#match address access- access-list-id: the specified access list number.
list-id
This command performs the same function that
manually configuring the encryption map does.
1. IPsec uses shared keys. These keys and their corresponding security association will expire at the same time.
2. Time or traffic lifetimes will expire at the same time as their security association.
3. If the router follows a new security association – and if its encryption map has been reconfigured with the new
lifetime – its peer will follow the same encryption map lifetime, too. When the router begins negotiation, the new
lifetime will be applied to the router and its peer.
4. Changing lifetime data will have no effect on the existing security association. But, during the next negotiation, it
will bind a new security association to the data permitted by the encryption map. If you want the new setup to go
into effect as soon as possible, the command clear crypto sa can be used to clear part or whole parts of the security
association database.
5. When the encryption map’s security association lifetime is canceled or isn’t set, the global lifetime will be regarded
as the correct lifetime during negoiation.
Step Six: Designate whether the ideal transformation security mechanism or the IPsec peer should contain the PFS
requirement when IPsec applies the encryption map’s SA.
Command Description
router(cfg-crypto-map)#set group1: Designates that IPsec will use 758-bit Diffie-
pfs[group1|group2|group3] Hellman groupware during a new Diffie-Hellman
exchange.
group2: Designates that IPsec will use 1024-bit
Diffie-Hellman groupware during a new Diffie-
Hellman exchange.
group3: Designate that IPsec will use 1536-bit
Diffie-Hellman groupware during a new Diffie-
Hellman exchange.
To be sure IPsec cannot perform the PFS application, please use this command:
Command Description
router(cfg-crypto-map)#no set pfs
Step Seven: configure DPD (Detect Dead Peer) function for encryption item. In this way, the local end can detect whether
the peer has the function of fault-auto-restore. The command is described as follows:
Command Description
router(cfg-crypto-map)# set dpd delay-time retry- delay-time: the maximal interval of sending
number [hold|clear] dbd detect message (by second). and the default value
is 10.
retry-number: the retry-timestimes of retransmitting
dpd detect packet. and the default value is 2.
hold: the action for pdd timeout, representing that the
connection will be reset and the negotiation will be
triggered again for the next time. The option is enabled
by default.
Clear: the action for DPD timeout, representing that
the connection is not reset and a new IKE negotiation
will be triggered for the next time.
Use the following command in global configuration mode to delete, in whole or in part, map items:
Command Description
router(config)#no crypto map map-name Map-name: The name of encryption map
[seq-num] Seq-num: The number of encryption map
When the encryption map is deleted, the existing security association will stay in effect until the command clear crypto sa
unrebuild is used to delete the corresponding security association.
The other configuration is similar to that of the normal ISAKMP encryption map set (see section 2).
Notes:
1. Multiple peers can be set in a dynamic encryption map, but only one can be set in normal encryption map.
2. At least one transformation set must be set in a dynamic encryption map and the configuration of other attributes
is optional.
3. Only one dynamic encryption item can be set for one dynamic encryption map set currently. Different from the
common ISAKMP encryption map set, the dynamic encryption map set can not be directly applied to an interface, and it
can not take effect until it is mapped to an ISAKMP encryption map item.
4. The IPsec peer configured as the dynamic map set can not initiate IKE negotiation to build IPsec tunnel for
communication, it must wait and accept the IKE negotiation request from the peer (it must be configured as the
common ISAKMP encryption map set).
Use the following command in global configuration mode to generate a normal encryption map entry referring to a dynamic
map set beforehand defined.
Command Description
router(config)#crypto map map-name seq- map-name: the name of the dynamic encryption
num ipsec-isakmp dynamic dynamic-map- map set
name seq-num: the serial-number of dynamic encryption
map item
dynamic-map-name: the name of dynamic
encryption map set
Use the following command in global configuration mode to delete the specified dynamic encryption map item or the whole
dynamic encrytion map set
Command Description
router(config)#no crypto dynamic-map map- map-name: the name of dynamic encryption map
name [seq-num] set
seq-num: the serial-number of dynamic map item.
Notes:
To delete a dynamic encrytion map set or entry, be sure that it has not been used, that is to say that it has not been
mapped to a common ISAKMP encryption map item.
F. Apply The Encryption Mapping Item To An Interface
An encryption map should be configured for each interface that the IPsec communication will pass through. The encryption
map will be used to judge all communication through the interface and apply special rules to different messages that need
protection through a security association.
Use the following command in interface configuration mode to apply the encryption map to an interface:
Command Description
router(config-if-xxx)#crypto map map- map-name name of encryption map
name [address ip-address] ip-address ip address of the interface
Notes:
1. Before the interface provides IPsec service, an encryption map must be assigned to the interface. If many
encryption maps have the same map-name but different seq-num, they will still be located in the same set and
applied to the same interface.
2. If Seq-num has a low number on the encryption map, it will carry a higher priority. An encryption map may
contain a combination of IPsec-ISAkMP and IPsec-manual.
To remove an encryption map from an interface:
Command Description
router(config-if)#no crypto map map-name. Removes the encryption map
Examples:
Command Task
router(config-if-xxx)#cry map mymap Applies the encryption mapping list mymap to
the current interface.
router(config-if-xxx)#cry map mymap addr Applies mymap to the current interface and
128.255.125.12 designates to use the address 128.255.125.12 of
the interface for the map set mymap
Use the following command to designate an identified interface in global configuration mode:
Command Description
router(config)#crypto map map-name local- map-name: the name of the encryption map
address {interface-id } interface-id the identity of the interface
Notes:
When designate an identified interface to an encryption map set, the IP address of the interface will be used as the local
address for IPsec tunnel.
To delete all IPsec associations and (if the parameter unrebuild hasn’t been chosen) rebuild all security associations on the
current encryption map:
Command Description
router#clear crypto sa peer ip-address ip-address: The remote-end peer IP address that uses
[unrebuild] the peer command to delete the IPsec assocation from
the specified peer.
router#clear crypto sa map map-name map-name: The name of the encryption map set.
[unrebuild] Use the map command to delete all security
associations created by the specified encryption map
set.
router#clear crypto sa entry destination- destination-address: The local or remote-end peer IP
address protocol spi address
[unrebuild] protocol: The security protocol esp/ah
spi: spi number
Note:
1. When you finish clearing data, the IPsec association will be rebuilt, if allowed.
2. If a configuration changes that has litte effect on the security association, then the change doesn’t have an effect on
the current security association and will have an effect on the coming security association. All security association
can be rebuilt through the command clear crypto sa. This way, these security associations can use this new
configuration. When the security association is built manually, if the configuration changes – which usually has
little effect on security association – then the command clear crypto sa must be used before the change becomes in
effect
3. When any security association is deleted, anything related to it will also be deleted. The inbound security
association and the outbound one are always built or deleted together.
4. In order to ensure the router processing the IPsec communication isn’t affected, only clear the part security
association’s contents.
Example:
Command Task
router#clear cry sa Clears all security associations and rebuilds the
security association according to condition.
router#clear cry sa map mymap Clears all security associations created by the
encryption mapping mymap and rebuilds them.
When allocating an IP address to a host, the NAT equipment can ensure the useful-life (keepalive) of the new address, that is
to say that the address can still keep alive in the useful-life when there exists no flow. For example, the NAT equipment can
make an IP address, which is generated by the NAT equipment and has been unused for 20 seconds, invalid. So, IPSec
participator need send UDP packets periodically so that the NAT map can not be altered until the SA of phase 1 and phase 2
expires.
Note:
NAT equipment can provide corresponding session timeout interval according to different manufacturers and models. It is
very important to determine the timeout interval of the NAT equipment and set the activation frequency in the interval.
The following commands are used in EXE mode to examine the IPsec configuration information:
Command Description
router#show crypto pfkeyv2 pfkeystate Displays statistic information about the pfkey socket.
router#clear crypto pfkeyv2 pfkeytate Clears statistic information about the pfkey socket.
router#show crypto IPSecout Displays the statistic value processed by the IPsec
input module.
router#clear crypto IPSecout Clears the statistic value processed by the IPsec input
module.
router#show crypto IPsec state/version State: Displays IPsec state information.
Version: Displays IPsec version information.
router#show crypto spd Displays the dataflow information in the security
database of IPsec policies.
router#show crypto explist Displays the SA’s overtime chain list.
To debug IPsec:
Command Description
router#debug IPsec addr {tx|rx|double} tx|rx|double: Input/output/bidirection
Observes the IP address and the data packet direction
entering the IPsec module.
router#no debug IPsec Closes debugging.
router#debug esp {addr|all|tail|head} addr|all|tail|head Address/datagram/the last 20
{tx|rx|double} bytes20 / the start 20 bytes
tx|rx|double
Input/output/bidirection
Router A Router B
Tunn
IPSec el s
121.255.255.162 f0 s2 2 f0 128.255.255.161
1.1.1.2 1.1.1.1
Router A Configuration:
Command Task
router>en
router#conf n
router(config)#int f0
router(config-if-fastethernet)#ip addr 121.255.255.162
255.255.0.0
router(config-if-fastethernet)#exit
router(config)#int s2 Configures the IP address of the interface
and the link layer protocol. The link
layer protocol can be specified freely
when IPsec is used.
router(config-if-serial2)#phy asyn
router(config-if-serial2)#encap ppp
router(config-if-serial2)#ip addr 1.1.1.2
255.255.255.255
router(config-if-serial2)#exit
router(config)#acc 1001 per ip 121.255.255.162 Configures an access list used to
0.0.255.255 128.255.255.161 0.0.255.255 designate what dataflow the user wants
IPsec to process. The following
examples are all protocols. TCP/UDP
can be specified alone.
router(config)#cry ip tr test esp-des esp-md5-hmac Configures how to protect the dataflow
securely. The encryption method is used
to encrypt data and protect the data can’t
be recognized on the network. The
authentications (md5, sha1…) are used to
assure data integrity and to guarantee the
data cannot be changed in
transportation.
router(cfg-crypto-trans)#mo tu Designates the tunnel mode to be used.
When the end address of the security
tunnel isn’t equal to the end address of
the dataflow, the tunnel mode must be
applied. For users, the transport mode
isn’t commonly used. The command is
optional and the default is the tunnel
mode.
router(cfg-crypto-trans)#exit
router(config)#cry map map1 1 IPsec-m Configures the encryption map 1.
router(cfg-crypto-map)#set peer 1.1.1.1 Designates the other end’s peer address.
router(cfg-crypto-map)#set tr test Designates the transformation set.
router(cfg-crypto-map)#match addr 1001 Designates the encryption access list.
router(cfg-crypto-map)#set ses i esp 1001 c
1234567812345678 a
1234567890123456789012345678901234
router(cfg-crypto-map)#set ses o esp 1001 c Sets the key and Security Parameter
1234567812345678 a Index (SPI) and it should respond to the
12345678901234567890123456789012 configuration of the end-to-end router.
The details refer to the corresponding
manual specifications.
router(cfg-crypto-map)#exit
router(config)#int s2
router(config-if-serial2)#cry map map1 Applies the configuration to the S2
interface.
router(config-if-serial2)#end
router#cle cry sa(no global configuration mode) Makes configuration effective.
router(config)#ip route 0.0.0.0 0.0.0.0 s2 Configures default routing.
router(config)#exit
router(config)#sh cr map
router#sh cr ips sa id
router#show cr spd
===================
flow :< src: 121.255.0.0 sport:any >
< dst: 128.255.0.0 dport:any proto:any >
mask :< src: 255.255.0.0 sport: 0 >
< dst: 255.255.0.0 dport: 0 proto: 0>
SA :< dst: 1.1.1.1 spi: 1001 sproto: 50 >
state:<UP refcount= 0>
router#show ip ip
router#sh ip esp
Statistics for the ESP protocol:
0 total packets
0 packet in esp_input() drop by no buf
0 packet drop for no SA
0 packet drop for no equal to SA
0 packet attempted to use an invalid SA
0 packet drop for no XFORM in SA
0 packet drop ip queue full
The hosts of Network Segment 121 will ping the hosts of Network Segment 128. After this command is finished, the router
statistics will indicate that packets been been encrypted. When the router senses the presence of a WAN line, the next IP
header protocol field is the esp protocol. The IP data packets passing through the system will be protected from outside
intrusion.
router#show ip ip
router#sh ip esp
Router B Configuration:
Command Task
router>en
router#conf n
router(config)#int f0
router(config-if-fastethernet0)#ip addr 128.255.255.161
255.255.0.0
router(config-if-fastethernet0)#exit
router(config)#int s2
router(config-if-serial2)#ip addr 1.1.1.1 255.255.255.255
router(config-if-serial2)#phy asyn
router(config-if-serial2)#encap ppp
router(config-if-serial2)#clo rate 64000
router(config-if-serial2)#exit
router(config)#acc 1001 per ip 128.255.255.161 Configures an access list
0.0.255.255 121.255.255.162 0.0.255.255
router(config)#cry ip tr test esp-des esp-md5- Configures how to protect the dataflow
hmac securely.
router(cfg-crypto-trans)#mo tu Designates the tunnel mode that will be
used.
router(cfg-crypto-trans)#exit
router(config)#cry map map1 1 IPsec-m Configures the encryption map.
router(cfg-crypto-map)#set peer 1.1.1.2 Designates the other end address of the
tunnel.
router(cfg-crypto-map)#set tr test Designates the transformation set that
will be used.
router(cfg-crypto-map)#match ad 1001 Designates the encryption access list.
router(cfg-crypto-map)#set ses i esp 1001 c
1234567812345678 a
12345678901234567890123456789012
router(cfg-crypto-map)#set ses o esp 1001 c 1234567812345678 a
1234567890123456789012345678901234 Sets the key and Security Parameter
Index (SPI).
router(cfg-crypto-map)#exit
router(config)#int s2
router(config-if-serial2)#cry map map1 Applies the interface configuration, and
the operation will specifies the local end
address of the tunnel.
router(config-if-serial2)#end
router#cle cry sa Makes the configuration effective.
router(config)#ip route 0.0.0.0 0.0.0.0 s2 Configures the default routing.
11.6.1 Features
High speed hardware encryption that is much faster than software encryption such as DES and 3DES etc.
128 bit encryption algorithms that allows for a high level of security index.
Hardware encryption that works without using up valuable CPU resources.
Applied IPsec and IKE that providing the esp-ssp02 encryption algorithm.
11.6.2 Encryption Module Application
The Maipu ENCRYPT hardware encryption module is installed in the security router’s interior bus socket. which is invisible
from the outside or by the outside card in slot and so can provide the esp-ssp02 encryption algorithm, genius hardware
pseudo-random number and read/write interface used by Smart card, and can be used for IPsec and IKE to realize hardware
encryption
Command Description
router(config)#crypto IPsec transform-set After the encryption module has been installed, the
transform-set-name esp-ssp02 esp-ssp02 algorithm in IPsec configuration can be
applied when the transformation set is configured.
This method is similar to the one described in Section
5.
Command Description
router(config-isakmp)# encryption ssp02 After the encryption module has been installed, the
IKE encryption algorithms in IISAKMP policies
configuration mode can be specified as esp-ssp02
encryption algorithms when the IKE policy is
created.
Note:
1. If a terminal closes IKE, then all IPsec terminals must close IKE.
2. When IKE is closed all operations, IKE remains invalid until it is opened once more.
When IKE is closed, IPsec only has manual configuration functions and doesn’t support key lifetime and anti-replay
functions. IKE uses UDP port 500 or port 4500 (in NAT-Traversal) to assure that communications won’t be blocked in the
IKE and IPsec interfaces.
IKE policies describes which security parameters are applied to protect subsequent IKE negotiation. Each terminal’s
security association (SA) will identify the security parameters after both terminals agree on a policy. The SA is applied to
the subsequent IKE communication during negoiation.
Each IKE policy has the following parameters:
Encryption algorithm
Hash algorithm
Authenticating method
Diffie-Hellman groupware identification
Lifetime of IKE security association
The following commands are executed as the following steps to configure security policy:
Step One: Enter ISAKMP policy configuration (config-isakmp) mode commands in global configuration mode.
Command Description
router(config)#crypto isakmp policy priority Priority: 1—9999
IKE policy identity: Default10000 is the least.
router(config)#no crypto isakmp policy Cancels an IKE policy.
[priority]
Example:
Command Task
router(config)# crypto isa po 123 Creates an IKE policy with the priority 123 and enters
config-isakmp configuration mode.
Step Two: Designate IKE encryption methods in ISAKMP policy configuration mode.
Command Description
router(config-isakmp )# encryption Des: Designates use of the encryption algorithm des.
des|3des|blowfish|ssp02 3des: Designates use of the encryption algorithm
3des.
Blowfish: Designate use of the encryption algorithm
blowfish.
ssp02: Designates use of the encryption algorithm
ssp02 (using a hardware encryption module).
router(config-isakmp)# no encryption Renews the IKE encryption algorithm back to the
default algorithm (des).
Example:
Command Task
router(config-isakmp)# encry 3des Designates use of the encryption algorithm 3des in
the policy.
router(config-isakmp)#no encry Designates use of the default encryption algorithm
des in the policy.
Step Three: Designate IKE authentication method in ISAKMP policy configuration mode:
Command Description
router(config-isakmp)# authentication{rsa- rsa-sig: Designates RSA signature
sig|pre-shared} authentication to be used.
pre-shared: Designates the pre-shared key
authentication to be used.
router(config-isakmp)#no authentication Designate the use of a default authentication
method pre-shared key.
Example:
Command Task
router(config-isakmp)#authen rsa-sig Designates the RSA signature authentication method
to be used in the policy.
router(config-isakmp)#no authe Designates the default pre-shared key authentication
method to be used in the policy.
Step Four: Designate IKE hash method in ISAKMP policy configuration mode:
Command Description
router(config-is)#hash sha|md5|rmd160 Sha: Designates use of the hash algorithm sha.
md5: Designates use of the hash algorithm md5.
rmd160: Designates use of the hash algorithm rmd160.
router(config-isakmp)#no hash Renews the hash method to the default algorithm SHA
Example:
Command Task
router(config-isakmp)#hash md5 Designates the hash algorithm md5 to be used in
the policy.
router(config-isakmp)#no hash Designates the hash algorithm SHA to be used in the
policy.
Step Five: Designates the Diffie-Hellman groupware used by IKE in the ISAKMP policy configuration mode:
Command Description
router(config-isakmp)#group 1|2|5 1 Designates the 768-bit Diffie-Hellman groupware
to be used.
2 Designates the 1024-bit Diffie-Hellman groupware
to be used.
3 Designates the 1536-bit Diffie-Hellman groupware
to be used.
router(config-isakmp)#no group Resumes to the default 1–768 bit Diffie-Hellman
groupware.
Example:
Command Task
router(config-isakmp)#group 2 Designates the 1024-bit Diffie-Hellman groupware
to be used.
Step Six: Designates the IKESA lifetime in seconds in ISAKMP policy configuration mode”
Command Description
router(config-isakMP)#lifetime seconds Seconds
router(config-isakMP)#no lifetime Renews the lifetime to the default time: 86,400
seconds.
Note:
1. When IKE begins to negotiate, the first thing you should do is agree on the consistent parameters to be set for each
session. The SA on each terminal will refer to these parameters, and each terminal will reserve SA until its lifetime
expires. Before SA expires, the parameters can be reused by the subsequent IKE negotiation. This can save some
time when a new IPsec SA is set. Some of these parameters are negotiated before the SA expires.
2. When the local terminal begins to negotiate with the remote terminal, whichever terminal’s lifetime is the shortest
will be the one selected by the system.
Note:
1.When only one IP address exists, it’s used as the ISAKMP identity. When many interfaces are used to negotiate
IKE and the IP address is unknown, the hostname should be applied.
2. When the RSA key mode is configured manually for IKE negotiation, you should use the command crypto
isakmp rsa-sig-cert no-optional to keep it effective.
Example:
Command Task
router(config)#crypto isa identi host Defaults the ISAKMP identity of the local host as the
hostname router.
router(config)#ip host hostname address1 [address2 Configures all remote terminals, if the ISAKMP
… address8] identity is the hostname, then the terminal hostname is
mapped to the IP address on all remote terminals.
router(config)#no ip host hostname address Cancels the mapping.
[address1 address2 … address8]
If myrouter and yourrouter are a pair of terminals, then use the above commands on myrouter to configure ISAKMP
identity. At the same time, the remote hostname and address mapping need to be configured on yourrouter.
Command Task
router(config)#ip host yourrouter.domain.com Specifies IP addresses.
121.255.254.202 2.2.2.3
router(config)#no ip host yourrouter 121.255.254.202 Removes 121.255.254.202 from the address mapping.
If an IP address isn’t specified, all host addresses will
be deleted.
Note:
1. Ensure the router’s host name or IP domain name has been configured.
2. If the RSA key exists, the new key will substitute the existing key that has the same name.
3. If a common purpose key needs to be generated, a pair of RSA keys will also be generated. These RSA keys will be
used together with the IKE policy to designate the RSA signature.
4. The size of the key modules must be set when the RSA key is generated. Its size should be not less than 512 bits.
5. The command can be used to generate the public key pair. The private key pair will remain invisible.
Example:
router(config)# cry key ger rsa us
The name for the keys will be: lincx
Choose the size of the key modulus in the range of 512 to 2048 for your General Purpose Keys.
Choosing a key modulus greater than 512 may take a few minutes.
How many bits in the modulus(Ctrl+E to exit)[512]?
Generating RSA key (modulous is 512 bits)................................................................. Done.
# RSA 512 bits, myrouter.domain.com, THU JAN 01 00:02:08 2001
# RFC2537 format RSA Pubkey:
010368a9 73f587e9 8a8487ce a6fb676f b5ae6889 ed840cac c6e6104c 7c180e52
90d42e0b f787a7ef 83cf b1b0 6c2eef49 c1392ec9 85b989e5 8ed61a8 bdc3468e
21520798 55
Note: Each of the eight numbers are displayed in a segment for reading ease. The blank character is invalid.
4. Delete all RSA keys
Command Description
router(config)#crypto key zeroize rsa Permanently deletes all local RSA keys.
5. Designate the RSA public keys for all the other terminals
Step One: If the RSA public key is used, then all remote-end RSA public keys must be configured locally:
Command Description
router(config)#crypto key pubkey-chain rsa Enters config-pubkey-chain mode
Step three: If the whole valid domain name is used in the second step to name the remote terminal (the command named-
key), then you can specify its IP address. The command can be used when only one router interface processes IPsec.
Example:
Command Task
router(config-pubkey-key)#address 192.68.66.65
Step four: Start to input the encryption key-string data after the command key-string is executed in config-pubkey-key
mode:
Designate the remote terminal’s RSA public key. The key can be seen when the remote terminal’s manager generates the
router’s previous RSA key.
Command Description
router(config-pubkey-key)#key-string [help] Input the key in hexidecimal form. While inputting
this, the keyboard’s CTRL key can be pressed to
input data continuously. Before the command is
used, the command addressed-key or named-key
must be used to identify the remote terminal.
Use the help function to display information about
public key operation.
In the public key configuration mode, the command no key-name or no key-address can be used to delete the terminal
peer’s public key. The following command can also be used to delete all public keys:
Command Description
router(config)#crypto pubkey-chain zeroize Clears all RSA public keys at the opposed end when
your terminal doesn’t have a key.
Note: The command only clears the public key information in memory. You can’t alter the information in the configuration
file without rewriting it.
If the authentication method specified in the IKE policy is a pre-shared key, then the pre-shared key must be configured.
Before the pre-shared key is configured, the ISAKMP identity of each terminal must be first setup.
Use the following commands to configure the pre-shared key in global configuration mode:
Command Description
router(config)#crypto isakmp key keystring Keystring: the pre-shared key
address peer-address peer-address: IP address of the remote terminal
router(config)#crypto isakmp key keystring peer-hostname: the remote terminal’s host name
hostname peer-hostname keystring: designates the pre-shared key. It can be
any combination of numbers and characters.
router(config)#no crypto isakmp key address Cancels the pre-shared key
peer-address
router(config)#no crypto isakmp key Cancels the pre-shared key
hostname peer-hostname
Note:
1. No matter where a pre-shared key is specified in IKE policy, that key must be configured.
2. You must know the identity of the key you wish to configure. You can find out by inputting crypto ISAKMP
identity.
3. You must configure the pre-shared key on both terminals at the same time.
4. If the ISAKMP IP address has been set in the remote terminal, then the address key is used.
5. If the ISAKMP host has been set in the remote terminal, then the hostname key is used.
When the hostname key word is used, the remote terminal’s hostname can also be mapped to all of its IP address interfaces
that may be used in the IKE negotiation. (The command ip-host completes this function.) You must do this mapping,
unless the hostname has been already been mapped to the IP address on the DNS server.
Example:
Command Task
router(config)#cryp isa key
123456789abcdefghijdlm hostname
yourrouter.domain.com
Use the following command in the global configuration mode to specify the peer adopting the Aggressive Mode:
Command Description
router(config)#crypto isakmp peer ip-address Ipaddress: the IP address of the peer adopting
ipaddress the Aggressive Mode.
Use the following command in global configuration mode to specify the peer adopting not the Aggressive Mode but Main
Mode:
Command Description
router(config)#no crypto isakmp peer ip-address Ipaddress: the IP address of the peer adopting
ipaddress not the Aggressive Mode but Main Mode.
Note:
This configuration has effect on only one peer only when it will initiate the first phase IKE negotiation to the other end,
but it is not effective when accept the negotiation request from the remote.
Command Description
router(config)#crypto ike auto-build Adding the keyword no before the command
represents the configuration will be canceled.
Note:
The configuration takes effect globally, that is to say that it is valid for all ipsec-isakmp encryption map sets that
have applied to interfaces and have been configured completely. Howerver, the configuration takes no effect on a dynamic
encryption map set and an encryption map item (a template item) to which the dnynamic encryption set is mapped
1. Monitoring IKE
The following series of commands can be executed to display relative IKE data in EXEC mode.
1. To display the ISAKMP policy:
Command Description
router#show crypto isakmp policy Priority: Priority level
[priority] Displayed contents include: priority, encryption
algorithm, hash algorithm, authentication mode,
Diffie-Hellman group and lifetime.
6. To display the local ISAKMP identity, plus the remote host’s ISAKMP identity and address map:
Command Description
router#show crypto isakmp identity local|remote Local: Displays the ISAKMP identity of the local
host.
Remote: Displays the ISAKMP identity and address
map list of the remote-end host.
8. To display the information about the identity of the peer adopting the IKE Aggressive Mode.
Command Description
router#show crypto isakmp peer
2. IKE Debugging
1. Use the following debugging commands to observe IKE procedure information in EXEC mode:
router#[no] debug crypto isakmp {normal|packet|serious}
Syntax Description
Normal Displays the procedure information. The default
status is ‘close’.
Packet Displays the information of the message. The default
status is ‘close’.
Serious When system errors occur, error information is
presented here. The default status is open.
No Closes the debugging data display
2. Use the following command to activate the IKE send negotiation in EXEC mode:
router#debug init ike connection-id {pending|phase1}
Syntax Description
connection-id Designates the IKE send negotiation connection
number. This number can be seen through the
command show crypto isakmp connection.
pending Designates an entire IKE negotiation and builds IPsec
SA.
phase1 Designates that the first stage of IKE negotiation
should be finished.
11.7.3 Configuration Examples
Router A Router B
Security
tunnel s
128.255.254.201 f0 s2 2 f0 121.255.254.202
2.2.2.2 2.2.2.3
The corresponding IPsec configuration must be performed in order for IKE to be used. For the purposes of illustrating the
preceding example, suppose the corresponding configuration hadn’t been performed. Router A would have to be configured
first.
Router A:
Command Task
IPsec Configuration:
Configure an encryption transform set:
routera(config)#cr ips tr t0 esp-3des ah-sha-hmac
routera(cfg-crypto-trans)#ex
routera(config)#cr ips tr t1 esp-des esp-md5-hmac
routera(cfg-crypto-trans)#ex
Configure an access list:
routera(config)#acc 1001 permit ip 128.255.0.0
0.0.255.255 121.255.0.0 0.0.255.255
Configure the encryption map:
routera(config)#cr map map1 1 IPsec-i
routera(cfg-crypto-map)#set tr t0 t1
routera(cfg-crypto-map)#set peer 2.2.2.3
routera(cfg-crypto-map)#match addr 1001
routera(cfg-crypto-map)#set pfs group2
routera(cfg-crypto-map)#set secur life sec 2000
routera(cfg-crypto-map)#set secur life kilo 3800000
Apply the encryption map:
routera(config)#int s2
routera(config-if-serial2)#ip addr 2.2.2.2 255.255.0.0
routera(config-if-serial2)#encap ppp
routera(config-if-serial2)#phy syn
routera(config-if-serial2)#clock rate 64000
routera(config-if-serial2)#no ip route-c
routera(config-if-serial2)#cr map map1
routera(config-if-serial2)#ex
IKE Configuration:
Configure IKE security policy:
routera(config)#cr isa pol 100
routera(config-isakmp)#auth rsa-sig
routera(config-isakmp)#enc 3des
routera(config-isakmp)#hash md5
routera(config-isakmp)#group 2
routera(config-isakmp)#life 4000
routera(config-isakmp)#ex
Configure ISAKMP identity, hostname and address
mapping:
routera(config)#cr isa id host R-A The local ISAKMP identity is R-A, and it is
independent of the hostname configured by the
hostname command in global configuration
mode.
routera(config)#ip host R-B 2.2.2.3 121.255.254.202 Configures ISAKMP identity with the remote-
end’s corresponding IP address of R-B.
Because the authentication method rsa-sig has
been configured in the policy, the RSA signature
pair must be generated on the local host. If
pre-shared has been adopted, then the following
operation to generate and configure the remote
terminal’s key needn’t be performed, but the
pre-shared key must be configured.
Generate RSA signature key: Generats the RSA public key
routera(config)#cr key gen rsa
The name for the keys will be: R-A
Choose the size of the key modulus in the
range of 512 to 2,048 for your Signature Keys.
Choosing a key modulus greater than 512 may
take a few minutes.
How many bits in the modulus [512]?
Generating RSA key (modulous is 512
bits)............ Done.
# RSA 512 bits, R-A, FRI MAY 25 00:10:28 2001
# RFC2537 format RSA Pubkey:
7f3da22f f139e66a 8d37539b 14e7a57e 93948f00
c75ac94b 6750dc3e 80b3e27b
7f3da22f f139e66a 8d37539b 14e7a57e 93948f00
c75ac94b 6750dc3e 80b3e27b
123abcd1 34
routera(config)#cr key pub rsa Configures the remote-end public key that is
routera(cfg-pubkey-chain)#named R-B generated from R-B.
routera(cfg-pubkey-key)#key-str
Input public key (Ctrl+E to exit):
010358e7 99f1a220 574aea3e f6d99e7f 355d7210
ec027aab 81b7bb1b 480aed6e
1c39f8de 7e4d8031 9978442f 3db86a53 c6da6046
f43a2950 8ce131ff 61a23eaf
f6571234 22
^e
routera(cfg-pubkey-key)#ex
routera(cfg-pubkey-chain)#ex
routerb(config)#int s2
routerb(config-if-serial2)#ip addr 2.2.2.3 255.255.0.0
routerb(config-if-serial2)#encap ppp
routerb(config-if-serial2)#phy syn
routerb(config-if-serial2)#no ip route-c
routerb(config-if-serial2)#cr map map2
routerb(config-if-serial2)#ex
routerb(config)#cr isa po 100
routerb(config-isakmp)#auth rsa-sig
routerb(config-isakmp)#enc 3des
routerb(config-isakmp)#hash md5
routerb(config-isakmp)#group 2
routerb(config-isakmp)#lifet 4000
routerb(config-isakmp)#ex
router(config)#cr is id host R-B
router(config)#cr k g r
Note:
1. If the RSA signature authentication method is chosen, then the RSA public key must be configured with each other.
2. You can now perform communication to make IKE work. There two kinds of methods you can use to test this:
You can ping messages from one Ethernet segment to another Ethernet segment. This will activate IKE to start
negotiation and build an IPsec SA.
The debug init ike 1 pend command can also be used in EXE mode to make IKE start negotiation.
Examining IKE SA
routera#sh cr isa sa
localaddr peeraddr state sa-id
2.2.2.2 2.2.2.3 OAK_QM_IDLE : MAIN_R3 1
Examining IPsec SA
routera#sh cr ips sa
================ Security Association Information ================
Interface: serial2
Crypto map tag: map1, entry seq-num: 1 , local addr: 2.2.2.2
Local ident(addr/mask):(2.2.2.2/255.255.255.255)
Remote ident(addr/mask):(2.2.2.3/255.255.255.255)
local crypto endpt: 2.2.2.2, remote crypto endpt: 2.2.2.3
inbound esp sas:
spi:0X71ac1d29 (1907105065)
transform: esp-3des,
in use settings = {Tunnel}
Current input 31680 bytes
Replay detection support: Y
outbound esp sas:
spi:0X18eb1a47 (418060871)
transform: esp-3des,
in use settings = {Tunnel}
group sa's SPI: 0X18eb1a48 (418060872)
sa timing: remaining key lifetime(k/sec):(3799969/1902)
Current output 31680 bytes
Replay detection support: Y
Permitted flows:
Flow:Protocol: any
Source addr: 128.255.0.0/255.255.0.0
Destination addr: 121.255.0.0/255.255.0.0
Sport: any
Dport: any
inbound ah sas:
spi:0X71ac1d28 (1907105064)
transform: ah-sha-hmac
in use settings = {Transport}
Current input 32160 bytes
Replay detection support: Y
outbound ah sas:
spi:0X18eb1a48 (418060872)
transform: ah-sha-hmac
in use settings = {Transport}
group sa's SPI: 0X18eb1a47 (418060871)
Current output 32160 bytes
Replay detection support: Y
Examining the detailed RSA public key data of the appointed remote terminal
routera#sh cr key pub rsa name R-B
Key name: R-B
Key address: (null)
Usage: RSA Signature Key
Source: Manual
Data:(0x):
010358e7 99f1a220 574aea3e f6d99e7f 355d7210 ec027aab 81b7bb1b 480aed6e
1c39f8de 7e4d8031 9978442f 3db86a53 c6da6046 f43a2950 8ce131ff 61a23eaf
f6571234 22
Noticeö
ö
Presently, VPDN only supports PPP dial-up, and the tunneling protocol only supports L2TP.
Syntax Descriptions
vpdn-group-number It is the name of the VPDN group, and
its type is NUMBER.
£Configuration mode¤ Global configuration
Notice:
Presently, LAC request-dialin and LNS request-dialout have been realized.
11.8.2 Special LAC configuration
Enter the special LAC configuration mode when the VPDN group selects the keyword request-dialin for the L2TP device.
Identify LAC
To establish a tunnel, LAC and LNS need be identified by each other. According to LAC identification, LNS can find the
corresponding VPDN-GROUP from its configuration and send back its own identification so that LAC can apply the
identification to the command show. For LAC, the identification, which LNS adopts during the course of establishing a
tunnel, isn’t important, but LAC must correctly identified itself, or else, LNS has no way to find the VPDN group related
with LAC.
Employ the following command to configure the identification:
local name lac-host-name
Syntax Descriptions
lac-host-name It is the name LAC uses to identify himself to LNS,
and its type is STRING.
£Configuration mode¤ the LAC request-dialin configuration mode
Command Descriptions
receive-window-size It is the receive-window-size, and its range is <4-
300>.
£Configuration mode¤ the VPDN group configuration mode
Noticeö
ö
Be sure to perform the configuration strictly according to the configuration manual.
PPP dial-up
Figure 10-15
Illustrationöö
Shown as the figure above, the PC dials in LAC through the remote dial-up, and the middle network is between LAC and
LNS.
LAC is configured as follows:
Command Descriptions
Router(config)# vpdn enable Enable VPDN.
router(config)# vpdn-group 1 Create a VPDN group
router(config-vpdn)#request-dialin Permit the request-dialin of the VPDN
group.
router(config-vpdn-req-in)# protocol l2tp Specify the L2TP protocol for the VPDN
group.
router(config-vpdn-req-in)#domain mp-2.com Specify the domain name to relate a user
with a VPDN group.
router(config-vpdn)#initiate-to ip 192.168.10.2 Specify the IP address of LNS.
router(config-vpdn)# local name r3 Specify the name for LAC to identify itself
on LNS.
router(config-vpdn)# l2tp tunnel password 7 a Specify the share password for
identification.
router(config-if-serial0/0)#physical-layer sync Configure the serial-port as the
synchronous mode.
router(config-if-serial0/0)#encapsulation ppp Encapsulate the protocol.
router(config-if-serial0/0)#ppp authentication pap Configure the interface to employ the PAP
authentication.
router(config-if-serial1/0)#physical-layer async Configure the serial-port as the
asynchronous mode.
router(config-if-serial1/0)#encapsulation ppp Encapsulate the protocol.
router(config-if-serial1/0)#ip address 129.255.14.66 Configure the IP address and subnet mask
255.255.255.0 of the interface s1/0.
router(config-if-serial1/0)#dialer in-band Enable DDR on the interface.
router(config-if-serial1/0)#dialer-group 1 Configure the interface to be subject to
some dialer-group.
router(config-if-serial1/0)# modem outer Use the outer modem.
Configure on LNS as follows:
Command Descriptions
router(config)# vpdn enable Enable VPDN.
router(config)# vpdn-group 2 Create a VPDN group.
router(config-vpdn)# accept-dialin Permit the accept-dialin of the VPDN
group.
router(config-vpdn-acc-in)# protocol l2tp Specify the L2TP protocol in the VPDN
group.
router(config-vpdn-acc-in)#virtual-template 1 Specify the virtual template interface.
router(config-vpdn)#terminate-from hostname r3 LAC provides the name of LNS.
router(config-vpdn)# local name r2 LNS provides its name to LAC.
router(config-vpdn)# l2tp tunnel password 7 a Specify the share password for
authentication.
router(config)#int virtual-template1 Create a virtual template interface.
router(config-if-virtual-template1)# encapsulation ppp Encapsulate the protocol.
router(config-if-virtual-template1)# ppp authentication pap Adopt the PAP as the authentication
protocol.
router(config-if-virtual-template1)#ip unnumber loopback1 Enable the IP un-number on the interface.
router(config-if-virtual-template1)# peer default ip address Specify the opposite-end IP address of the
pool vpdn-pool interface.
router(config)# user mp-5@mp-2.com password 0 a Configure the username and password for the
dialin user.
router(config)# ip local pool vpdn-pool 172.16.20.10 Configure the address pool.
172.16.20.100
router(config-if-loopback1)# ip address 172.16.20.1 Configure the IP address of L1.
255.255.255.0
router(config-if-serial2/0)#physical-layer sync Configure the serial interface as the
synchronous mode.
router(config-if-serial2/0)#clock rate 9600 Configure the clock.
router(config-if-serial2/0)# encapsulation ppp Encapsulate the protocol.
router(config-if-serial2/0)# ip address 192.168.10.2 Configure the IP address.
255.255.255.0
Noticeö ö
Different verification can be configured on two sides of the Tunnel interface, which has no effect on its connectivity.
tunnel destination
Configure the IP address of the opposite end of the Tunnel interface. The form no of the command is used to delete the IP
address of the opposite end of the Tunnel interface.
tunnel destination ip-address
no tunnel destination ip-address
Syntax Descriptions
ip-address Specify that the opposite end employs the IP address of the
factual physical port of the Tunnel interface.
£Default¤Specify no IP address of the opposite end of the Tunnel interface.
£Command mode¤the Tunnel interface configuration mode.
Noteö ö
1) Ip-address must be consistent with the physical port of the opposite end and assure the port is reachable.
2) The destination address of local Tunnel interface must keep consistent with the source address of the opposite-end
Tunnel interface.
tunnel key
Specify the identification key-number of the tunnel. And the form no of the command is used to cancel the identification
key of the tunnel.
tunnel key key-number
no tunnel key key-number
Syntax Descriptions
key-number Specify the identification key-number of the tunnel. And its
value range is 0-4294967295.
£Default¤Specify no identification key-number of the tunnel.
£Command mode¤the Tunnel interface configuration mode.
Noteö ö
Key-numbers of both sides of the tunnel must be consistent.
tunnel sequence-datagrams
Configure two sides of the tunnel to verify the sequence-number of datagrams. This configuration can be used to discard
disordered datagrams. The form no of the command is employed to disable the verification of the sequence-number of
datagrams.
tunnel sequence-datagrams
no tunnel sequence-datagrams
£Default¤Don’t verify the sequence-number of datagrams.
£Command Mode¤the Tunnel interface configuration mode.
Noteö ö
Different verification can be configured on the tunnel interface, without any effect on its connectivity.
tunnel source
Configure the local address of the tunnel interface. The form no of the command is used to delete the local port of the
tunnel interface.
tunnel source {ip-address|interface-name}
no tunnel source {ip-address|interface-name}
Syntax Descriptions
ip-address Specify that the local end uses the IP address of the
factual physical port of the tunnel interface.
interface-name Specify that the local end uses the regular name of the
factual physical port of the tunnel interface.
£Default¤Specify no the local port of the tunnel interface.
£Command mode¤the tunnel interface configuration mode.
Figure 10-16
Illustrationö ö
Shown as the figure above, two tunnels are established between Router 1 and Router 2 through the IP network so that
different services can use different logical channels.
Router1 is configured as follows:
Command Descriptions
router(config)# interface fastethernet0 Enter the configuration status of the
port f0.
router(config-if-fastethernet0)#ip address 129.255.20.188 Configure the IP address of the
255.255.255.0 subnet mask of the port f0.
router(config-if-ethernet0)#ip address 129.255.14.66 255.255.255.0 Configure the IP address of the
subnet mask of the port e0.
router(config-if-serial1/0)#physical-layer sync Configure the serial-port as the
synchronous mode.
router(config-if-serial1/0)# clock rate 9600
router(config-if-serial1/0)# encapsulation ppp
router(config-if-serial1/0)# ip address 20.1.1.1 255.255.255.0 Configure the IP address of the
subnet mask of the port s1/0.
router(config-if-serial1/0)# ip address 20.1.2.1 255.255.255.0 Distribute a secondary address to the
secondary s1/0.
router(config-if-serial1/0)#intface tunnel1
router(config-if-tunnel1)# ip address 1.1.1.1 255.255.255.0 Configure the IP address of the
subnet mask of the tunnel1.
router(config-if-tunnel1)#tunnel source 20.1.1.1 The local end uses the IP address of
the factual physical port of the tunnel
interface.
router(config-if-tunnel1)#tunnel destination 30.1.1.2 The opposite end uses the IP address
of the factual physical port of the tunnel
interface.
router(config-if-tunnel1)#ip route peer-address 1.1.1.2 Specify the IP address of opposite
end of the tunnel 1 in the dynamic route.
router(config-if-tunnel1)#intface tunnel2
router(config-if-tunnel2)#ip address 2.1.1.1 255.255.255.0 Configure the IP address of the
subnet mask of the port tunnel2.
router(config-if-tunnel2)# tunnel source 20.1.2.1 The local end uses the IP address of
the factual physical port of the tunnel
interface.
router(config-if-tunnel2)#tunnel destination 30.1.2.2 The opposite end uses the IP address
of the factual physical port of the tunnel
interface.
router(config-if-tunnel2)#ip route peer-address 2.1.1.2 Specify the IP address of opposite
end of the tunnel 2 in the dynamic route.
router(config-ospf)#network 129.255.20.0 0.0.0.255 area 0 Configure the relative dynamic
routing protocol.
router(config-ospf)#network 1.1.1.0 0.0.0.255 area 0
router(config-ospf)#network 2.1.1.0 0.0.0.255 area 1
router(config-ospf)#network 129.255.14.0 0.0.0.255 area 1
router(config)# ip route 30.1.1.0 255.255.255.0 20.1.1.2 Configure the relative static routing
protocol for the middle channel.
router(config)# ip route.30.1.2.0 255.255.255.0 20.1.2.2
Route2 is configured as follows:
Command Descriptions
router(config)# interface fastethernet0 Enter the configuration status of the port f0.
router(config-if-fastethernet0)#ip address 192.168.2.254 255.255.255.0 Configure the IP address of the subnet mask of
the port f0.
router(config-if-ethernet0)#ip address 192.168.1.254 255.255.255.0 Configure the IP address of the subnet mask of
the port e0.
router(config-if-serial1/0)# physical-layer sync Configure the serial-port as the synchronous
mode.
router(config-if-serial1/0)# clock rate 9600 Configure the clock
router(config-if-serial1/0)# encapsulation ppp Encapsulate the protocol
router(config-if-serial1/0)# ip address 30.1.1.2 255.255.255.0 Configure the IP address of the subnet mask of
the port s1/0.
router(config-if-serial1/0)# ip address 30.1.2.2 255.255.255.0 secondary Distribute a secondary address to the s1/0.
router(config-if-serial1/0)#intface tunnel1
router(config-if-tunnel1)# ip address 1.1.1.2 255.255.255.0 Configure the IP address of the subnet mask of
the tunnel1.
router(config-if-tunnel1)#tunnel source 30.1.1.2 The local end uses the IP address of the factual
physical port of the tunnel interface.
router(config-if-tunnel1)#tunnel destination 20.1.1.1 The opposite end uses the IP address of the
factual physical port of the tunnel
interface.
router(config-if-tunnel1)#ip route peer-address 1.1.1.1 Specify the IP address of opposite end of the
tunnel 1 in the dynamic route.
router(config-if-tunnel1)#intface tunnel2
router(config-if-tunnel2)#ip address 2.1.1.2 255.255.255.0 Configure the IP address of the subnet mask of
the port tunnel2.
router(config-if-tunnel2)#tunnel source 30.1.2.2 The local end uses the IP address of the factual
physical port of the tunnel interface.
router(config-if-tunnel2)#tunnel destination 20.1.2.1 The opposite-end uses the IP address of the
factual physical port of the tunnel
interface.
router(config-if-tunnel2)#ip route peer-address 2.1.1.1 Specify the IP address of opposite end of the
tunnel 2 in the dynamic route.
router(config-ospf)#network 192.168.1.0 0.0.0.255 area 0 Configure the relative dynamic routing
protocol.
router(config-ospf)#network 1.1.1.0 0.0.0.255 area 0
router(config-ospf)# network 2.1.1.0 0.0.0.255 area 1
router(config-ospf)# network 192.168.2.0 0.0.0.255 area 1
router(config)#ip route 20.1.1.0 255.255.255.0 30.1.1.1 Configure the relative static route of the
middle physical line.
router(config)# ip route 20.1.2.0 255.255.255.0 30.1.2.1
Notice:
This is an application of the network isolation. And usually, it can work in with NIA/URA to realize the isolation of user
authentication.
10.9.3 GRE Checking and Debugging
show tunnel-chain
Display all Tunnel configurations.
show tunnel-chain
ûCommand modeüthe privilege user mode.
show gre statistics
Display the gre statistics.
show gre statistics
ûCommand modeüthe privilege user mode.
debug tunnel data
Enable the information debugging switch. The form no of the command is used to disable the tunnel debugging switch.
debug tunnel data
no debug tunnel data
ûCommand modeüthe privilege user mode.
11.10 Configuration of Digital Certificate
In this section, we mainly narrate the terminologies, principles and characteristics of Digital Certificate as well as relative
debugging commands and information.
Main contents are as followsÖ
Terminologies involved in Digital Certificate;
Introduction to Digital Certificate;
Debugging commands and debugging information.
Asymmetric CryptographyæIn Asymmetric Cryptography systems, there exists a certain relation between cipher key
and decryption key, but they are entirely different, that one of them can be made public and never mind that someone can
calculate or deduce the other. So, the asymmetric key is also called public key.
CertificateæA certificate, as a special form of digital marking sentence, provides a mechanism to confirm the relationship
between public key and entities that hold private key, signed and delivered by the certificate authority (holding other pair of
private key and public key). Generally, a certificate also contains other information relating to subject public key, such as the
identification information of an entity that has the right to use private key. So when a certificate is delivered, the certificate
authority should prove the correctness of the binding between the subject public key and the subject identification
information.
CA----Certification AuthorityæSimply speaking, it is an entity or service that delivers certificates. CA acts as the role of
a guarantor that is bound between the subject public key and the subject identification information that are all included in the
delivered certificate. IKE needs the support from CA Certification Center when negotiating by certificate.
(3) Configure the address information of a certificate server (optional configuration) under the CA trusted point
configuration (ca-identity) mode.
Command Descriptions
router(ca-identity)#enrollment url address Configure the URL address of CA (or RA) Server for
online application and query.
router(ca-identity)#no enrollment url address Delete the URL address of CA (or RA) Server.
(4) Configure certificate revocation verification policy (optional configuration) under the CA trusted point configuration
(ca-identity) mode
Command Descriptions
router(ca-identity)#revoke check off Loose verification certificate revocation (default).
router(ca-identity)#revoke check on Strict verification certificate revocation.
Noteö ö
1) The option Revoke check represents the policy when verification the certificate validity through CRL.
2) If configured with the loose verification is or adopting the default configuration, then a router accepts the user certificate
of the opposite entity when it can not find the right CRL.
3) If configured with the strict verification and cannot find the right CRL, then the router doesn’t accept the user certificate
of the opposite entity.
4) The default configuration is the loose verification.
(5) Configure the certificate validity period policy (optional) under CA trusted point configuration (ca-identity) mode
Commands Descriptions
router(ca-identity)#time check off Validate the certificate validity period (default).
router(ca-identity)#time check on Do not validate the certificate validity period.
Noteö ö
1) The option time check represents the policy that is employed when CRL verifies the certificate validity.
2) If configured not to verify the certificate period, then the router accepts the user certificate of the opposite entity when it
has no way to get the standard time correctly and fails to adopt the local time to validate the certificate.
3) If configured not to verification verify the certificate period or adopting the default configuration, then the router refuse
to accept the user certificate of the opposite entity when it has no way to get the standard time correctly and fails to adopt the
local time to validate the certificate.
4) If the device clock is inaccurate, and both device clock and CA don’t support time query, it is suggested to enable this
option, otherwise it will cause the failure of certificate verification or the certificate unavailable.
(6) Configure the automatic update policies (optional) under the CA trusted point configuration (ca-identity) mode.
Command Descriptions
router(ca-identity)#crl autorenew peroid hours Set the CRL automatic update period, and the unit
is hour.
Noteö ö
1) Starting up the CRL automatic update and setting the little update period may enhance the system security, but if CRL is
larger, it may increase system load.
2) The CRL automatic update time represents that even if the next update time specified by CRL doesn’t expire, it will still
try to refresh CRL. And this may avoid the impact of delivering certificate ahead of schedule by CRL when the certificate is
revoked.
3) If the option time optional is already set, then there is no way to confirm the next update time specified by CRL. So it
refreshes CRL by the default automatic update time.
4) The default CRL update cannot be automatically refreshed.
Noteö ö
1) Before using the online certificate query or application, please configure the URL address of the CA trusted point.
2) The fingerprint of root CA is acquired from the CA center when a user enrolls, or is acquired by other out-of-band
manner.
(2) Use this command, under the configuration mode, to apply for a user certificate on line.
Command Descriptions
router(config)#crypto ca enroll name Apply to the CA center for a user certificate.
For examplesæ
Commands Descriptions
router(config)#cry ca enroll mpca Apply to the CA trusted point mpca for a user
% Start certificate enrollment .. certificate.
Password: ****
% Request certificate now?[yes]/[no]:y
% User Certificate enroll success.
Input the user password (sometimes you may
input no password according to the demand of
CA,) and
Does the certificate username include IP
address?
Noteö ö
1) Please configure the URL address of the CA trusted point before performing online certificate query and application.
2) When a user applies the user certificate, the CA certificate must have been authenticated and the corresponding key pair
has been generated locally. If double key pairs need be generated, please employ the application signature to encrypt two
certificates.
(3) Get back the user certificate enrolled successfully.
If the administrator does not authorize the application immediately, please contact with the administrator for the certificate.
Use the following command to get back the certificate after the administrator authorizes the application.
Command Descriptions
router(config)#crypto ca retrive name Get back the certificate in the enrolled-currently
state.
After the enroll command crypto ca enroll name is executed, if the state of local certificate is requesting, it represents that
the certificate is waiting for authorization.
(4) Use this command, under configuration mode, to perform the online CRL update.
Command Descriptions
router(config)#crypto ca crl request name Perform the online CRL update immediately.
Noteö
ö
1) Please configure the URL address of CA trusted point before using the online certificate query and application.
2) Before a user performs the online application of CRL, the CA certificate must be authenticated firstly and the
corresponding user certificate has been applied.
3) If the system time is incorrect, it may make the CA certificate or the user certificate unavailable. Here, the user can
firstly configure the option time optional of the CA trusted point.
(2) Use this command, under certificate chain configuration mode, to introduce the certificate through the IC card.
Command Descriptions
router(config-cert-chain)#ic certificate input Introduce the certificate from IC cards.
(3) Use this command, under certificate chain configuration mode, to input the CA certificate from the screen.
Command Descriptions
router(config-cert-chain)#certificate ca input Introduce the CA certificate from the screen, and
[pem | der] the keywords pem and der represent the format of
the certificate.
For exampleö
Command Descriptions
router(config-cert-chain)# certificate ca input pem Require inputting or pasting the
% Input the CA certificate data: certificate in pem format (use two
-----BEGIN CERTIFICATE----- continuous carriage returns to end
MIICATCCAaugAwIBAgIKYAkAAL4joz0BADANBgkqhkiG9w the input).
0BAQ
UFADBSMQ4wDAYDVQQDEwVjYTE3NzEMMAoGA1UECx Require the user to authenticate CA,
MDc2VjMQswCQYDVQQKEwJtcDELMAkGA1UECBMCc2Mx as the same of the online application.
CzAJBgNVBAcTAmNkMQswCQYDVQQGEwJDTjAeFw0wMj
EwMDgxODI4MTRaFw0wNzEwMDgxODI4MTRaMFIxDjAMB
gNVBAMTBWNhMTc3MQwwCgYDVQQLEwNzZWMxCzAJB
gNVBAoTAm1wMQswCQYDVQQIEwJzYzELMAkGA1UEBx
MCY2QxCzAJBgNVBAYTAkNOMFwwDQYJKoZIhvcNAQEB
BQADSwAwSAJBANtHec+d3wUkoCr3YdYhC2wttVSORSgbqN
DQATt9dRijskQy9wpbVrSHJGgD71CoL794CFQPOxdB/t1bcPm3
zwcCAwEAAaNjMGEwDwYDVR0TAQH/BAUwAwEB/zAOBg
NVHQ8BAf8EBAMCAQYwHQYDVR0OBBYEFFxZwmjXOtDf
7vnCbOk2uvC8rMyFMB8GA1UdIwQYMBaAFFxZwmjXOtDf7v
nCbOk2uvC8rMyFMA0GCSqGSIb3DQEBBQUAA0EAjGtnVb/Ji
N+IsJsrYX6w5z53GCAZN8xregMQK/6t1qM/s/9JMZE+AQbPkqf
d7um0t3qhc8xGr5aUNMIimpmzRg==
-----END CERTIFICATE-----
Noteö ö
1) Any mistake in format input or data input can result in no way to introduce.
2) You can use the editor to open the pem format of certificate, paste its contents on the screen, and then introduce it from
the screen.
3) The certificate in der format (binary file purely) can not be pasted directly, it can only be opened by the hex editor and
then be input as ASCII character.
4) Certificates can be converted between PEM format and der format by other tools.
(4)Use this command, under certificate chain configuration mode, to input CRL from the screen
Command Descriptions
router(config-cert-chain)#crl input [pem | der] Introduce CRL from the screen, and the keywords
pem and der represent its format.
For exampleö
Command descriptions
router(config-cert-chain)#crl input der
30 81 e9 30 81 94 02 01 01 30 0d 06 09 2a 86 48
86 f7 0d 01 01 05 05 00 30 52 31 0e 30 0c 06 03
55 04 03 13 05 63 61 31 37 37 31 0c 30 0a 06 03
55 04 0b 13 03 73 65 63 31 0b 30 09 06 03 55 04
0a 13 02 6d 70 31 0b 30 09 06 03 55 04 08 13 02
73 63 31 0b 30 09 06 03 55 04 07 13 02 63 64 31
0b 30 09 06 03 55 04 06 13 02 43 4e 17 0d 30 32
31 31 31 38 30 33 35 30 31 33 5a 17 0d 30 32 31
31 32 31 30 33 35 30 31 33 5a a0 0e 30 0c 30 0a
06 03 55 1d 14 04 03 02 01 01 30 0d 06 09 2a 86
48 86 f7 0d 01 01 05 05 00 03 41 00 7d 5a 52 28
71 86 e0 3a 88 91 96 87 5e 07 5b 1f c7 db 86 ff
0e a7 35 4a 6f 95 32 48 53 f2 59 c8 bf 2c d1 ac
66 9b 7b d3 d2 d9 3c b2 88 28 88 66 02 61 9d 35
f7 ad bd 7e cf 80 0c 48 dd a3 30 2d
(2) Use this command, under the privilege user mode, to display the information about the CA trusted point configured.
Command Descriptions
router#show crypto ca identity Display the configuration about CA trusted point.
(3) Use this command, under the privilege user mode, to display the information about the configured certificate.
Command Descriptions
router#show crypto ca certificates [pem | der] Display the information about the configured
certificate.
The keywords pem and der specify the format of
the certificate. If no keyword is specified, it is
displayed in the general format.
For exampleæ
Command Descriptions
router# show cry ca certificates pem
CA Certificate: Before here on is the key
Issuer : CN=ca177, OU=sec, O=mp, ST=sc, L=cd, C=CN information about the certificate.
Serial Number: 60090000BE23A33D0100
PEM data:
-----BEGIN CERTIFICATE----- From here on is the certificate data
MIICATCCAaugAwIBAgIKYAkAAL4joz0BADANBgkqhkiG9w in the pem format.
0BAQ
UFADBSMQ4wDAYDVQQDEwVjYTE3NzEMMAoGA1UECx
MDc2VjMQswCQYDVQQKEwJtcDELMAkGA1UECBMCc2Mx
CzAJBgNVBAcTAmNkMQswCQYDVQQGEwJDTjAeFw0wMj
EwMDgxODI4MTRaFw0wNzEwMDgxODI4MTRaMFIxDjAMB
gNVBAMTBWNhMTc3MQwwCgYDVQQLEwNzZWMxCzAJB
gNVBAoTAm1wMQswCQYDVQQIEwJzYzELMAkGA1UEBx
MCY2QxCzAJBgNVBAYTAkNOMFwwDQYJKoZIhvcNAQEB
BQADSwAwSAJBANtHec+d3wUkoCr3YdYhC2wttVSORSgbqN
DQATt9dRijskQy9wpbVrSHJGgD71CoL794CFQPOxdB/t1bcPm3
zwcCAwEAAaNjMGEwDwYDVR0TAQH/BAUwAwEB/zAOBg
NVHQ8BAf8EBAMCAQYwHQYDVR0OBBYEFFxZwmjXOtDf
7vnCbOk2uvC8rMyFMB8GA1UdIwQYMBaAFFxZwmjXOtDf7v
nCbOk2uvC8rMyFMA0GCSqGSIb3DQEBBQUAA0EAjGtnVb/Ji
N+IsJsrYX6w5z53GCAZN8xregMQK/6t1qM/s/9JMZE+AQbPkqf
d7um0t3qhc8xGr5aUNMIimpmzRg==
-----END CERTIFICATE-----
(4) Use this command, under the privilege user mode, to display the CRL information configured.
Command Descriptions
router#show crypto ca crls [pem | der] Display the CRL information configured.
The keywords pem and der specify the format of
the certificate. If no keyword is specified, it is
displayed in the general format.
Note:
1) If the old version (adopting the previous encryption algorithm) has been upgraded to the new version (adopting
the new encryption algorithm ), the previous encryption algorithm can be compatible because no service new-encrypt
is configured by default.
2) If the new encryption algorithm has been realized and the previous encryption algorithm has been downloaded,
no service new-encrypt must be configured for the system to be compatible with the previous encryption algorithm.
2) Basic Configuration Commands of Login-secure
Enable login-secure
service login-secure
The command above is used to enable the login-secure service.
no service login-secure
e command above is used to disable the login-secure service.
ÏCommand modeÐthe global configuration mode.
router>en
password:
password:
password:
% Bad passwords
router>en
password:
password:
password:
% Bad passwords
//After three times, the Enable operation is denied; execute the command show login-secure information can display
the following record information including try-time and forbid-time.
router>
router>en
%enable operation is locked by login-secure service
router>
router>en
%enable operation is locked by login-secure service
router>
Chapter 12 Quality of Service (QoS) Configuration
This chapter describes basic Quality of Service (QoS) principles and corresponding configuration methods.
With priority queuing, the router will send out a packet with the highest priority level before sending a packet with a lower
priority. When the outbound interface is very congested, the packets will be queued from highest to lowest priority. If the
interface isn’t congested, then the router will send all of the packets forward at the same level of priority.
Normal is usually the default queue setting. A packet that isn’t already classified or distributed to a specified queue in any
router can be put into a queue.
You can configure the router so that it can classify packets by:
TCP or UDP port numbers.
Packet size.
The arriving packet’s interface.
Any item described in a standard or extended access list.
IP fragments.
You can also choose to use the default scattered packet mode.
Command Description
interface <interface > <high / medium / normal / low> interface <interface >:
Distributes the interface priority when the packet
arrives.
high / medium / normal / low:
Defines the queue priority of queue.
default <high / medium / normal / low> Default:
Distributes a priority to any packet that doesn’t
match the appointed standard.
protocol ip <high /medium /normal / low> protocol IP: Assigns the data packet using IP
<fragments/ gt /lt /list /tcp/ udp> protocol.
fragments: Assigns a priority by whether or not the
data packet is fragmented.
gt/lt: Assigns a priority by packet size.
list: Assigns a priority by data according to the
access list.
tcp/udp: Assigns a priority by outbound tcp/udp
port number.
router config-if-xxx
Command Description
Note:
1) The same priority list can be applied to many interfaces.
2) Different priority policies can also apply to different interfaces.
3) You can only use one priority list for each interface.
The priority queue default depth of a Maipu router, from high priority to low priority, is 15000, 30000, 45000 and 65535.
This value can be changed when you input the following commands while configuring the router’s priority queue size:
Command Description
When a priority queue is full, packets will be tailed-dropped normally. But you can choose RED algorithm as packet drop-
type:
Router config priority-list <list-number>
Command Description
drop-type random-detect <RED group name> Chooses RED algorithm as packet drop-type.
<RED group name>: name of the RED group. The
following will describe how to configure a RED
group.
drop-type tailed-dropped Chooses default tailed-dropped algorithm as packet
drop-type.
Unix host
ip:192.168.255.253/24
ip:192.168.255.30/24
Router2
S1/2
PPP
Router1 S0
ip:128.255.254.1/24
terminal ip:128.255.254.24/24
1) In the preceding figure (Figure 3), the Maipu router (Router1) connects with a terminal. The router’s interface
serial0 connects with the interface serial1/2 of the Cisco router (Router2) on the opposite end. The link has terminal
service data, FTP data and other data. The terminal data is to be set to the highest priority, FTP is to be set to the
lowest priority and other data is to be set to normal.
2) The IP address of the remote UNIX host is 192.168.255.253. The process itest should be run on port 3051. FTP
runs on TCP ports 20 and 21.
router#configure terminal
router(config)# priority-list 1 protocol ip low tcp 21 In list 1, the packet going to port number TCP21
is put in the low priority queue.
router(config)# priority-list 1 protocol ip low tcp 20 In list 1, the packet going to port number TCP20
is put in the low priority queue.
router(config)# priority-list 1 protocol ip high tcp In list 1, the packet going to port number
3051 TCP3051 is put in the high priority queue.
router(config)# interface serial0
router#configure terminal
router(config)# access-list 1001 permit tcp any Access list 1001 permits packets with any
192.168.255.253 0.0.255.255 eq 3051 source address, the destination address named
192.168.0.0 and the TCP port number named
3051 to pass through.
router(config)# access-list 1001 permit ip any Access list 1001 permits any IP packet to pass
any through.
router(config)# exit
router(config)#access-list 1002 permit tcp any Access list 1002 permits packets with any
192.168.255.253 0.0.255.255 eq 20 source address, the destination address named
192.168.0.0 and the TCP port number named 20
to pass through.
router(config)# access-list 1002 permit tcp any Access list 1001 permits packets with any
192.168.255.253 0.0.255.255 eq 21 source address, the destination address named
192.168.0.0 and the TCP port number named 21,
to pass through.
router(config)# access-list 1002 permit ip any Access list 1002 permits any IP packet to pass
any through.
router(config)#priority-list 1 protocol ip low list Packets according access list 1002’s rules are
1002 put in the low priority queue.
router(config)#priority-list 1 protocol ip high list Packets according to access list 1001’s rules are
1001 put in the high priority queue.
router(config)#interface serial0
Note: Although the queue depth can be adjusted, you should generally try to avoid changing it from the default depth –
especially when priority queuing is not meeting current system demands.
A Weight Fair Queue (WFQ) will sort packet information to ensure that many users with different needs can share bandwidth
at one time when the network is busy. It also ensures that all messages are transmitted in real time when there is little
traffic. In fact, a high-bandwidth message will not become lost in the system if the network is congested – it will be allowed
to pass through. A message with low-bandwidth needs will continuously re-queue until there is less traffic to let the high-
bandwidth message go through the network.
A WFQ saves packet information. When a packet comes into the system, the system sorts the packet into its corresponding
queue. If there a queue for the packet doesn’t exist, a new queue will be created for the packet.
queue
Queue1 Packets leaving from the
Sor Queue i f
center(config-if-xxx)
Command Description
Show wfq interface type number See the wfq information in a certain interface
applied wfq
Show wfq See the wfq information in all of the interface
applied wfq
ra#debug wfq interface type number debug the wfq information in a certain intface
Show wfq interface type number See the wfq information in a certain interface
applied wfq
Show wfq See the wfq information in all of the interface
applied wfq
ra#debug wfq interface type number debug the wfq information in a certain intface
This system assigns a queue to each user session based on the amount of information that user needs access to. Like WFQ,
these queues save the passing packets as they enter the router. The system will sort and queue a packet.
When the system de-queues, the system will start polling user information. According to the different configurations that
each queue possesses, the corresponding total number of bytes taken from each user’s queue will be different. The user who
needs access to the greatest number of bytes will have the highest priority. (If the sorting rule allowing this to happen isn’t
configured, then the packet will enter the default queue.)
Sixteen queues can be defined for each interface here. Each queue is titled and simply identified with a number between 1
and 16. (The number doesn’t have anything to do with queuing priority.)
Configure the router so it can sort packets according to the following standards:
Protocols (ICMP, IGMP, TCP and UDP) and TCP and UDP port numbers,
Packet size.
The arriving packet’s interface.
Any item described by a standard or an extended access list.
IP fragments.
A packet’s source address and destination address.
You can also choose to use the default scattered packet mode.
Queue
Priority Packets leaving from the
Queue1 10%
Sor Queue i f
10%
Packets that must be Queue Dequeuing scheduling
sent through the Queue 16 30%
Figure 5 Customer Queuing Sketch Map
Note: The queue with serial number 16 is often considered the default queue. A packet neither sorted nor assigned to an
appointed queue will be put in the default queue.
12. 4.2 Configure CQ
Configuration:
Define a user-defined customer queuing list using a number between 1 and 16.
Command Description
fragments <0-16,Min queue number> <0- Fragments: Sets the queuing rule according to
16,Max queue number> whether the packet is fragmented or not.
<Min queue number>: Sets the minimal queue
number that packet can enter.
<Max queue number>: Sets the maximal queue
number that packet can enter.
gt/lt/et <1-1500> <0-16,Min queue number> <0- gt/lt/et: Sets the queuing rule according to the
16,Max queue number> packet size. It can be more than, less than or
equal to the size of the appointed packet.
<1-1500>:Defines the packet size.
icmp/igmp/tcp/udp <0-16,Min queue number> icmp/igmp/tcp/udp: Sets queuing rule according to
<0-16,Max queue number> different protocol type.
default <queue-number> Default: All packets that don’t accord with the
above rules will be put in the default queue.
router config-if-xxx
Command Description
custom-list <list-number> Applies the defined list to the interface.
The default buffer size of the Maipu router user-defined queue interface is 65,535 bytes. The default buffer size of each
queue from 0 to 16 is 65,535 bytes. The value of the parameter can be altered through the following command:
router config custom-queue-list <list-number>
Command Description
custom-queue-list <list-number> Set the buffer size of each queue from 0 to 16.
queue <0-16,Min queue number> <0-16,Max queue
number> limit <size>
When a customer queue is full, packets will be tailed-dropped normally. But you can choose RED algorithm as packet drop-
type:
router config custom-queue-list <list-number>
Command Description
drop-type random-detect <RED group name> Chooses RED algorithm as packet drop-type.
<RED group name>: name of the RED group. Section
2.5 describes how to configure a RED group.
drop-type tailed-dropped Chooses default tailed-dropped algorithm as packet
drop-type.
After CQ has been configured, the following debugging command can be used to verify and check the action. The detailed
commands are as follows:
center
Command Description
show cq Displays the router’s relative CQ interface
information.
show cq interface <interface> Displays the specified interface’s relative CQ
information.
debug cq debug the router’s relative CQ interface
information.
debug cq interface <interface> debug the specified interface’s relative CQ
information.
12. 4.6 An example
Unix host
ip:192.168.255.253/24
ip:130.255.78.1/30
Router2
ip:130.255.78.1/30 S1/2
PPP
ip:130.255.78.2/30
Router1 S0
ip:128.255.254.1/24
Terminal ip:128.255.254.24/24
2) The IP address of the remote UNIX host is 192.168.255.253. The process itest will run on TCP port 3051 and the
FTP will run on the TCP port 20 and 21.
Command Task
center(config)#custom-queue-list 1 tcp 1 1 130.255.78.2 Puts the ftp data packets of TCP port 3051
255.255.255.255 any any any 3051 into queue 1.
Puts the ftp data packets of TCP port 20 into
center(config)# custom-queue-list 1 tcp 2 2 queue 2.
128.255.254.24 255.255.255.255 any any any 20
center(config)# custom-queue-list 1 tcp 2 2 Puts the ftp data packets of TCP port 21 into
128.255.254.24 255.255.255.255 any any any 21 queue 2.
center(config)# custom-queue-list 1 queue 1 1 byte-count Defines the de-queuing byte numbers into
6000 queue 1 of each circle.
center(config)# custom-queue-list 1 queue 2 2 byte-count Define the de-queuing byte numbers in the
1500 queue 2 of each circle.
router(config)#interface serial0
router(config-if-serial0)# custom-list 1 Applies list 1 to the interface.
A Weighted Random Early Detect Queue (WREDQ) is just like FIFOQ except packet drop algorithm and the number of
queues(10 queues). It selects RED as packet drop algorithm. It classifies packets according to IP priority (namely the first 3
bits of TOS field in IP header).
While WRED queuing is a complex procedure, but it needs little configuration.
queue
Queue0 Packets leaving from the interface
Classi Queue12
fy
Packets that must be sent Queue … Dequeuing scheduling
through the interface Queue 9
Figure 4 Weighted Fair
Queue Sketch Map
Configuration:
center(config-if-xxx)
Command Description
CBWFQ assigns a weight to different classes of IP packets. The bandwidth of the interface configured with CBWFQ will be
allocated according to the weight.
CBWFQ configuration is a complex procedure, configuring a CBWFQ mainly involves three steps:
1) Defining a match class.
2) Defining a CBWFQ policy.
3) Applying the defined CBWFQ policy to an interface.
Configuration:
Configuration:
priority <1_100000> Defines packets of this match class enter LLQ queue,
and bandwidth for LLQ(Least Latency Queue)
<1-100000>: Defines LLQ bandwidth, kbits/s
bandwidth percent <1-75> Defines bandwidth percentage for packets of this
match class.
<1-75>: Defines the percentage of bandwidth.
bandwidth <1-100000,bandwidth> <1- Defines bandwidth for packets of this match class.
100000,total bandwidth of this interface>
set ip precedence <0-7> Sets IP precedence for packets of this match class.
<0-7>: Defines IP precedence value being set.
set ip dscp <0-63> Sets IP dscp field for packets of this match class.
<0-63>: Defines IP dscp field value being set..
set mpls experimental imposition <0-7> Set MPLS experimental value at tag imposition for
packets of this match class.
<0-7>: Defines MPLS experimental value at tag
imposition.
set mpls experimental topmost <0-7> Set MPLS experimental value on topmost label for
packets of this match class.
<0-7>: Defines MPLS experimental value on topmost
label.
Command Description
router config-if-xxx
Command Description
service-policy output <policy-name> Configures CBWFQ on the interface.
Applies the defined CBWFQ policy to the
output packets of the interface.
service-policy input <policy-name> Applies the defined CBWFQ policy to the
input packets of the interface, but only set-
rules in this policy will be effective.
no service-policy output Cancels CBWFQ queues used on the interface.
After CBWFQ has been configured, the following debugging command can be used to verify and check the action. The
detailed commands are as follows:
center
Command Description
show cbwfq Displays the router’s relative CBWFQ interface
information.
show cbwfq interface <interface> Displays the specified interface’s relative CBWFQ
information.
<interface>: Specifies the interface.
Debug wfq This command can display CBWFQ informaion
Notes:
1) One 2M private line is adopted between two network nodes. The private line is used to bear the transmission of
voice data, terminal services and data.
In order to guarantee IP-voice quality and bandwidth of the telnet data packets, we can use CBWFQ.
Configurations of router1:
Command Task
Router1#conf t
router1(config)#access-list 1001 permit ip host 192.168.1.6 IP-voice data packets
host 192.168.1.5
router1(config)#access-list 1002 permit tcp host Telnet data packets
192.168.2.100 host 192.168.0.100 eq 23
router1(config)#access-list 1003 permit tcp host FTP management packets
192.168.2.101 host 192.168.0.101 eq 21
router1(config)#access-list 1003 permit tcp host FTP application data packets
192.168.2.101 host 192.168.0.101 eq 20
router1(config)#class-map voip Defines VOIP match class
router1(config-cmap)#match access-group 1001 Defines match rules for VOIP match class
router1(config)#class-map telnet Defines TELNET match class
router1(config-cmap)#match access-group 1002 Defines match rules for TELNET match class
router1(config)#class-map ftp Defines FTP match class
router1(config-cmap)#match access-group 1003 Defines match rules for FTP match class
router1(config)#policy-map one Defines CBWFQ policy ONE
router1(config-pmap)#class voip Enter configuration-mode of VOIP class
router1(config-pmap-c)#bandwidth percent 50 Assigns 50% bandwidth for VOIP class
router1(config-pmap)#class telnet Enter configuration-mode of TELNET class
router1(config-pmap-c)#bandwidth percent 20 Assighs 20% bandwidth for TELNET class
router1(config-pmap)#class ftp Enter configuration-mode of FTP class
router1(config-pmap-c)#bandwidth percent 5 Assighs 5% bandwidth for FTP class
router1(config)#interface serial 0/0
router1(config-if-serial0/0)#service-policy output one Applies policy ONE on the s0/0 interface
MAIPU router uses Committed Access Rate(CAR) as the algorithm of bandwidth management. CAR algorithm allocates
bandwidth to IP data-packet flows according to rate-limit rules.
The detailed configuration are as follows(issuing rate-limit command under router config-if-xxx mode):
Syntax Description
{input | output} Apply the rule to ingress/egress packets
access-list-No Specify an access-list no to match packets. If its default configuration is adopted,
all ingress/egress packets of the interface must be matched. The value range is from 1
to 2000.
CIR Define committed Information rate(bit/s), a value in 8000-100000000
Conform burst Define conform burst rate, the depth of conform bucket(byte), a value in
1500-50000000
Exceed burst Define exceed burst rate, the depth of exceed bucket(byte), a value in 0-
100000000
actions [action val] Define actions of conform /exceed burst:
continue : do nothing but continue matching next rule
drop : drop this packet
transmit : forward this packet
set-prec-continue : set the precedence of a packet as <action val> and
continue matching next rule
set-prec-transmit : set the precedence of a packet as <action val> and forward
this packet
set-dscp-continue : set DSCP of a packet as <action val> and continue
matching next rule
set-dscp-transmit : set DSCP of a packet as <action val> and forward this
packet
Syntax Descriptions
reservable-bandwidth This is the reservable-bandwidth, and its value range is
between 1 and 10000000 kbps
largest-reservable-flow This is the largest reservable bandwidth of each flow,
and its value range is between 1 and 10000000kbps.
burst burst-factor Set the maximum burst percentage of the reserved flow,
and the value range of burst-factor is between 100 and 1000.
And the default value is 500(%).
delay time-value It is the delay time (millisecond) used to update Adspec
in Guaranteed services, and its value range is between 1 and
5000, 90 (ms) by default.
neighbor access-list Utilize the access list to limit the communication of
RSVP neighbors. Its value range of access-list is between 1
and 1000.
signaling {conform | exceed} {dscp value | Tag the flows that succeed in being reserved, meet or go
precedence value } beyond the bandwidth. When value is corresponding with
DSCP, its value range is between 0 and 63, while
corresponding with precedence, between 0 and 7.
udp-multicasts multicast-address Enable and listen in the multicast address when some
intermediate routers can’t support the original sockets or
default multicast addresses.
The value range of multicast-address is of multicast
group address, and its default is 224.0.0.14.
£Default¤ RSVP is not running.
£Command mode¤The interface configuration mode.
Note:
The maximum reservable bandwidth cannot exceed 75% of the interface maximum bandwidth.
Command Descriptions
route1#conf t
router1(config)#interface s0/0
router1(config-if-serial0/0)# fair-queue Enable WFQ.
router1(config-if-serial3/0)#bandwidth 2000 Designate the interface bandwidth to
be 2M.
router1(config-if-serial0/0)#ip rsvp bandwidth 64 64 Enable the RSVP resource reservation
function.
router1(config-if-serial0/0)#encapsulation ppp
router1(config-if-serial0/0)#ip address 192.168.0.5
255.255.255.252
Configure ROUTER2 as follows:
Command Descriptions
Route2#conf t
Router2(config)#interface s0/0
Router2(config-if-serial0/0)# fair-queue Enable WFQ.
router2(config-if-serial3/0)#bandwidth 2000 Designate the interface bandwidth to
be 2M.
Router2(config-if-serial0/0)#ip rsvp bandwidth 64 64 Enable the RSVP.
Router2(config-if-serial0/0)#encapsulation ppp
Router2(config-if-serial0/0)#ip address 192.168.0.6
255.255.255.252
Syntax Descriptions
Sender Configure the PATH message proxy, of which the followed parameters are as
follows:
the destination address reservable-flow, the resource address of reservable-
flow, IP protocol number of reservable-flow, the destination port of reservable-
flow, the source port of reservable-flow, the previous hop address of PATH
message, the supposed receiving interface of PATH message, the reservable-flow
bandwidth, the reservable-flow burst-size.
sender-host Configure the PATH message proxy for the local application. And no receiving
interface and previous hop addresses need be configured.
reservation Configure the RESV message proxy, of which the followed parameters are as
follows:
the destination address a reservable-flow, the source address of a reservable-
flow, IP protocol number of a reservable-flow, the destination port of a reservable-
flow, the source port of a reservable-flow, the previous hop address of a RESV
message, the supposed receiving interface of RESV message, the reservable
share-style, the service that the reservable-flow applies for, the reservable-flow
bandwidth, the reservable-flow burst-factor.
reservation-host Configure the RESV message proxy for the local application. No receiving
interface and the previous hop address need be configured.
Monitoring and Debugging RSVP (Resource Reservation Protocol)
show ip rsvp installed
This command is used to display the information about the flows that succeeds in RSVP reserving currently.
show ip rsvp installed
£Command mode¤The privilege user mode.
show ip rsvp neighbour
This command is used to display the RSVP neighbor list that switches the RSVP signaling with the local router.
show ip rsvp neighbour
£Command mode¤The privilege user mode.
show ip rsvp sender
This command is used to display the list (PSB) of the PATH messages that the local router received.
show ip rsvp sender
£Command mode¤The privilege user mode.
show ip rsvp reservation
This command is used to display the list (RSB) of the RESV messages that the local router received.
show ip rsvp reservation
£Command mode¤The privilege user mode.
show ip rsvp blockade-state-block
This command is used to display the list (BSB) of the RESV messages that are denied by the previous hop and are received
by the local router.
show ip rsvp blockade-state-block
£Command mode¤The privilege user mode.
show ip rsvp timer
This command is used to display the list of the timers relevant with each RSVP in the local router.
show ip rsvp timer
£Command mode¤The privilege user mode.
debug ip rsvp
This command is used to display the process that creates the RSVP reservation.
debug ip rsvp
£Command mode¤The privilege user mode.
Chapter 13 802.1Q Specifications
This chapter describes how to configure your MP2600 router so it can connect to a Virtual LAN (VLAN) and an exterior
network.
Mp5124 Switch
vlan1
port1- 10
( market department)
vlan2
Port11- 20 f0.1 f0.2
( market department)
( vlan1)( vlan2)
Mp2600Router
Figure 1 One-Armed Routing
Thus, VLAN1 or VLAN 2’s data stream can get to router sub-interface f0.1/ f0.2 through relay port 1. The routing between
two VLANs is accomplished through the use of two sub-interfaces. Because the router only has one physical interface that
connects to a switch port, the router will have a one-armed router alias.
13.1.3 Subnet Isolation
As long as two sub-interfaces and their corresponding VLAN are configured in default mode, the two VLANs can
communicate with each other. But in some circumanstances, it isn’t what we expected.. To do this, you will have to
create a new access list based on the one-armed routing configuration to filter communications between the two VLANs.
The access list must be applied to the corresponding VLAN sub-interface.
13.2 802.1Q Configuring Commands
Only sub-interfaces 1 to 63 of the Ethernet interface can be named, per 802.1Q protocols. Each sub-interface can be
configured with any VLAN ID number from 1 to 4,094.
13.2.1 Configuring 802.1Q Commands
The 802.1Q protocol configuration involves the following three steps:
creating a sub-interface
naming 802.1Q protocol
setting up an IP layer
A. Create A Sub-Interface
Router config interface fastethernet0.
Syntax Description
Notes:
1) Fastethernet0.0 is a master interface and can’t change 802.1Q protocol.
2) You can’t have more than 63 sub-interfaces.
B. Name 802.1Q Protocol
router(config-if-fastethernet0.1)#
Command Description
Shutdown
No shutdown
Notes:
1) The sub-interface can only encapsulate 802.1Q protocol. The protocol will only be named when a sub-interface has
been created.
2) Your VLAN ID number can only be from 1 to 4,094.
C. Set-up An IP Layer
router(config-if-fastethernet0.1)# ip ?
Command Description
Address <unicast address> < network mask> Configures the sub-interface IP address on the sub-
interface.
access-group <IP access list | Access-list Applies an access list to the sub-interface.
name> <in | out>
Notes:
1) The IP address configured on the sub-interface and the IP address of all the equipment on the same VLAN should be
contained in the same network segment.
2) If you want to use the one-armed routing function, communication between some equipment must be prohibited.
An access list must be applied to the interface.
13.2.2 A Typical One-Armed Router Application
) )
03
03
9/$1 9/$1
9/$1 , ' 9/$1 , '
(7+(51(7 (7+(51(7
Command Task
To configure fastethernet0.2:
Command Task
Note: The VLAN 1 PC’s default gateway is set to IP address 1.1.1.4 in the MP200’s fastethernet0.1 interface. The
VLAN 2 PC’s default gateway is set to IP address 1.1.2.4 in the MP2600’s fastethernet0.2 interface.
Configuration Results:
router#show run
Building Configuration...done
hostname router
no service password-encrypt
no service enhanced-secure
interface loopback0
exit
interface fastethernet0
exit
interface fastethernet0.1
ip address 1.1.1.4 255.255.255.0
encapsulation dot1q 1
exit
interface fastethernet0.2
ip address 1.1.2.4 255.255.255.0
encapsulation dot1q 2
exit
13.2.3 A Typical Subnet Isolation Application
03
) )
03
9/$1 9/$1
9/$1 , ' 9/$1 , '
(7+(51(7 (7+(51(7
Command Task
Router config #ip access-list standard 1 Creates a standard access list 1 on the
router.
router (config-std-nacl)#deny 1.1.1.0 0.255.255.255 Sets the first access list 1 rule to prohibit
data from 1.1.1.0/24 from passing
through.
Router config #ip access-list standard 2 Creates a standard access list 2 on the
router.
router (config-std-nacl)#deny 1.1.2.0 0.255.255.255 Sets the first access list 2 rule to prohibit
data from 1.1.2.0/24 from passing through.
To configure fastethernet0.1:
Command Task
To configure fastethernet0.2
Command Task
Configuration Results:
router#show run
Building Configuration...done
hostname router
no service password-encrypt
no service enhanced-secure
ip access-list standard 1
deny 1.1.1.0.0.255.255.255
permit any
exit
ip access-list standard 2
deny 1.1.2.0 0.0.255.255.255
permit any
exit
interface loopback0
exit
interface fastethernet0
exit
interface fastethernet0.1
ip address 1.1.1.4 255.255.255.0
encapsulation dot1q 1
ip access-group 2 out
exit
interface fastethernet0.2
ip address 1.1.2.4 255.255.255.0
encapsulation dot1q 2
ip access-group 1 out
exit
13.2.4 Displaying Configuration Statistics
Command Description
ö
Create an HDCPö
router(config)#ip dhcp pool word Define an address pool and enter DHCP
configuration mode.
The name of the address pool is the value of word.
In DHCP configuration mode:
router(dhcp-config)# default-router Configure the default gateway of the host.
router(dhcp-config)# dns-server Configure DNS server address of the host.
router(dhcp-config)# domain-name Configure the server name of the host.
router(dhcp-config)# netbios-name-server Configure the address of the server netbios-name.
router(dhcp-config)# network Define the address assigned in the address pool.
router(dhcp-config)#exit Exit the interface mode.
In INTERFACE configuration mode:
router(config-if-fastethernet0)#ip address dhcp Act as dhcp client by requesting a address from some
DHCP server
The second step: Configure the optional parameters passing to the host
DHCP can send more other information to the host in addition to assign addresses dynamically.
Table 14-3 configure DHCP address pool optional parameters
Command Description
router(dhcp-config)#default-router A.B.C.D Configure the default gateway of the host.
A, B, C and D are the default gateways.
I
router(config)#ip dhcp excluded-address Remove the address of the interface f0 of the router
129.255.78.44 from the address pool.
router(config)#ip dhcp pool goat maipu Define an address pool maipu.
router(dhcp-config)# Define the address for address assignment in the
network 129.255.0.0 255.255.0.0 address pool.
router(dhcp-config)#default-router Configure the default gateway of the host:
129.255.78.44 129.255.78.44.
router(dhcp-config)#dns-server 61.139.2.69 Configure DNS server address of the host
router(dhcp-config)#netbios-name-server Configure the address of the server netbios-name .
129.255.78.27
router(dhcp-config)#end The configuration finished.
Noteö ö
The host connecting with the interface fastethernet0 of the router, through the above configuration, can get the other
assigned addresses except 129.255.78.44äused by the interface fastethernet0 of the routeråof the network segment
129.255.0.0. And the host will be configured with the information on DNS server, the default gateway and the server
netbios-name.
15.1 Commands
You can use the following three commands to configure NDSP in global configuration mode:
Command Description
ndsp run Enable NDSP . The no ndsp run command is used to
deactivate NDSP . The default mode leaves NDSP
turned off.
ndsp timer Specifies frequency of transmission of NDSP update. The
default interval is 60 seconds.
ndsp holdtime: Specfies the amount of time a receiving device should hold
the information sent by your device before discarding it.
The default interval is 180 seconds.
ndsp enable NDSP is enabled by default on all supported interfaces to
send and receiver NDSP information.
NDSP is enabled by default on all supported interfaces to send and receiver NDSP information. You can disable NDSP on an
interface supports NDSP by using the no ndsp enable command.
Command Description
ndsp enable Enabled NDSP on an interface.
15.2 Examples
If you want to run NDSP on your router, you would input:
router#configure terminal
router(config)# ndsp run
router(config)#exit
router#
If you don’t want to run NDSP on your router anymore, you would input:
router#configure terminal
router(config)#no ndsp run
router(config)#exit
router#
Chapter 16 SNMP Configuration
SNMP (Simple Network Management Protocol) is a standard protocol to manage the Internet. Its purpose is to assure that the
management information can be transmitted between the Network Management Station and the managed equipment——
agent. It is convenient for the system manager to manage the network system.
SNMP adopts the tree labeling method to number each managed element and insures the number is exclusive. About the
detailed information on SNMP protocol, refer to the TCP/IP data.
16.1 SNMP Instruction Set
z Router (config)#snmp-server ?
Command Description
snmp-server start Activate SNMP network management.
snmp-server community Set the SNMP community name.
snmp-server contact Set the contact mode of the device manager.
snmp-server host Set the host name or IP address of the network
management station receiving SNMP trap.
snmp-server location Set the location of the device.
snmp-server view Set the network management view.
snmp-server enable traps Enable to send specified type of traps
snmp-server AddressParam Set the address parameter.
Note:
The parameter community-name is used to specify the community name that is added to the router. Usually, the
community name must be the same as that configured on the network management station, or else the network management
station has no way to perform any operation to the router.
The parameter { ro | rw} is used to set the network management station’s rights to operate the router. The parameter ro
means read-only and rw means reading/writing.
The parameter view is used to specify the view scope for the community. Maipu router can do without the configuration
of the parameter view (it can do with the default).
The parameter access-list is the access control list that is used to perform the access control of hosts in the community.
So, nothing but those hosts that are in the same community with the router and permitted by the router’s access control list
can access the router. (About the detailed information, refer to Maipu router access control module)
For example:
Add the community public to the router, and then set the reading/writing right to operate the router for the network
management station whose community name is public:
router(config) #snmp-server community public rw
Note:
After starting up the router, you must configure the community for it, or else, the network management station has no
way to manage the router by means of snmpv1/v2c;
If you want to perform writing operations on the router, such as upgrading a program, backing up the configuration file,
the parameter < ro/rw/view > must be set as rw(reading/writing).
Note:
The parameter < ip/name > represents the destination name or IP address to which the traps message will be sent.
Usually, it is the IP address or name of the host on which the network management application has been installed. It is
noticeable that the trap message is the message the router forwardly sends to the host on which the network management
application has been installed.
If the parameters following host, such as traps, community-name and version, are not configured, the system will adopt
the default configuration: type—traps, community-name—public and version—2.
Enable to send specified traps
Router(config)#snmp-server enable traps [module-name [trap-type]]
module-name trap-type Description
bgp Enable SNMP BGP traps
backward-transition Enable BGP backward transition trap
established Enable BGP established trap
dlsw Enable SNMP DLSw traps
circuit-down Enable DLSw circuit down trap
circuit-up Enable DLSw circuit up trap
tconn-down Enable DLSw tconn down trap
tconn-partner-reject Enable DLSw tconn partner reject trap
tconn-prot-violation Enable DLSw tconn port violation trap
tconn-up Enable DLSw tconn up trap
frame-relay Enable SNMP frame-relay traps
dlci-status-change Enable frame-relay DLCI status change trap
pvc-connect-status- Enable frame-relay PVC connect status change trap
change
pvc-connect-status- Enable frame-relay PVC connect status notify trap
notify
isdn Enable SNMP isdn traps
call-information Enable isdn call information trap
ospf Enable SNMP OSPF traps
if-authen-failure Enable OSPF interface authentication failure trap
if-config-error Enable OSPF interface config error trap
if-rx-bad-packet Enable OSPF interface receive bad packet trap
if-state-change Enable OSPF interface state change trap
lsdb-approaching- Enable OSPF lsdb approaching overflow trap
overflow
lsdb-overflow Enable OSPF lsdb overflow trap
max-age-lsa Enable OSPF max age lsa trap
nbr-state-change Enable OSPF neighbor state change trap
originate-lsa Enable OSPF originate lsa trap
tx-retransmit Enable OSPF retransmit trap
virtif-authen-failure Enable OSPF virtual interface authentication failure trap
virtif-config-error Enable OSPF virtual interface config error trap
virtif-rx-bad-packet Enable OSPF virtual interface receive bad packet trap
virtif-state-change Enable OSPF virtual interface state change trap
virtif-tx-retransmit Enable OSPF virtual interface retransmit trap
virtnbr-state-change Enable OSPF virtual neighbor state change trap
pim Enable SNMP PIM traps
neighbor-loss Enable PIM neighbor loss trap
rsvp Enable SNMP RSVP traps
lost-flow Enable RSVP lost flow trap
new-flow Enable RSVP new flow trap
snmp Enable SNMP traps
authentication Enable authentication trap
coldstart Enable coldstart trap
enterprise Enable enterprise specific traps
linkdown Enable link dowm trap
linkup Enable link up trap
warmstart Enable warmstart trap
x.25 Enable SNMP x.25 traps
reset Enable SNMP x.25 traps
restart Enable SNMP x.25 traps
0 Get-request PDUs
0 Get-next PDUs
0 Set-request PDUs
0 General errors
0 Response PDUs
2 Trap PDUs
0 SNMPv3 Reports:
0 Invalid Msgs
0 Unknown PDUHandlers
0 Unavailable Contexts
0 Unknown Contexts
0 Unsupported SecLevels
0 Not In TimeWindows
0 Unknown UserNames
0 Unknown EngineIDs
0 Wrong Digests
0 Decryption Errors
The foregoing information indicates that the router hasn’t received the SNMP message presently, but has sent two trap
SNMP messages that are trap messages. The information SNMPv3 Reports describes is the error statistics information that
appears when SNMPv3 messages are processed.
Router# show snmp-server community
Note:
The command is used to display the information about the community that the router has joined in. The execution result
of the command is displayed as follows:
Router#show snmp-server community
Community Name Relating View Index Access Right ACL-name
public 1 Read-Write
private 1 Read-Only
It indicates that the router has joined in two communities: public and private.
Router# show snmp-server host
Note:
The command is used to display the information of the destination address that has been configured on the router and to
which the traps message will be sent. The execution result of the command is displayed as follows:
Router# show snmp-server host
It indicates that the router has set the destinations to which the two traps messages will be respectively sent: 128.255.254.55
and mp-12434.
Router# show snmp-server oidAlias
Note:
The command is used to display the oid sequence’s alias that has been set on the router:
Router# show snmp-server oidAlias
MIB-II 1.3.6.1.2.1
ifEntry 1.3.6.1.2.1.2.2.1
MIB-II_system 1.3.6.1.2.1.2.1
It indicates that three oid aliases have been set on the router: the aliases of 1.3.6.1.2.1, 1.3.6.1.2.1.2.2.1 and 1.3.6.1.2.1.2.1 are
MIB-II, ifEntry and MIB-II_system (The three oid aliases are the default configuration of the SNMP proxy of the router.).
Router# show snmp-server view
Note:
The command is used to display the view that has been configured on the router:(Generally, a view is composed of
several sub-tree nodes) :
Router# show snmp-server view
It indicates that one view has been configured on the router: its name is default, and view index is 1, including all nodes
under the sub-tree 1.3.6.1. (The view is the default configuration of the SNMP proxy of the router).
When configuring automatic proxy forwarding, you many know no IP address of the surrogated equipment. Here, you
do nothing but input 0.0.0.0 at the location of ip-address. Moreover, the automatic proxy forwarding can not work without the
keepalive mechanism.
For example:
Use the following command to configure the destination entity: IP address—1.1.1.1, port-number—162èengineID—
abcdef1234:
router(config)#snmp-server engineID remote 1.1.1.1 162 abcdef1234
The foregoing command is used to configure the automatic proxy forwarding. Before the command is configured, the
corresponding username need be configured in advance. The function of the command is to relate several engines (SNMPv3
entities) to an engine group. One user can be specified for each engine group. In this way, the username can be used to access
any engine of the engine group. The parameter {noauth |auth |priv} is used to describe the security level of the username,
and must be consistent with the username.
For example:
Use the following command to configure an engine group: group-name—group1, username—user1, security level—
auth:
router(config)#snmp-server engineGroup group1 user1
For example:
Use the following command to configure a group: group name—group1, security level—authentication encryption,
notify-view—view3, read-view—view1, and write-view—view2.
Router(config)#snmp-server group group1 v3 authpriv read view1 write view2 notify view2
For example:
Use the following command to configure a user: the user name—user1, corresponding group name-group1, security
level—authentication encryption, authentication protocol—MD5, password—123456, encryption protocol—DES,
password—234567.
Router (config)# snmp-server user user1 group1 v3 auth md5 123456 encrypt des 234567
Use the following command to configure a remote user: the user name—user2, IP address—1.1.1.1, port-number—162,
security level—authentication encryption, authentication protocol—SHA, password—123456, encryption protocol—DES,
password—123456.
router(config)#snmp-server user user2 group1 remote 1.1.1.1 162 v3 auth sha 123456 encrypt des 123456
The command is used to display the engineID (including both remote engineID and local engineID ) that has been
configured on the router:
router#show snmp-server engineID
Local engine ID: 12345678
IPAddress: 1.1.1.1.0.162 remote engine ID: abcdef1234
The information above indicates that two engineIDs have been configured on the router: one is the local engineID and
another is the remote engineID.
Note:
The command is used to display the address parameter table that has been configured on the router:
router#show snmp-server AddressParams
SNMP TargetAddressParam List:
ParamName User Name MP_model SecurityModel SecurityLevel
==================================================================
addparam1 user2 v3 USM authpriv
z Configure the address parameter on the router; the name—addparam1, the corresponding user—useer2, the message
processing mode—v3, the security model—USM, the security level—authentication encryption.
z
z router#show snmp-server TargetAddress
Note:
The command is used to display the destination address table that has been configured on the router:
z
z router#show snmp-server TargetAddress
TargetAddressList:
===================================================
Name: target1
Address: 1.1.1.1.0.162
ParamName: addparam1
TagList: tag1 tag2
TimeOut(sec) :2
RetryCount :2
===================================================
z A destination address item has been configured on the router: the name—target1, the destination address—1.1.1.1,
UDP port-number—162, the taglists—tag1 and tag2, the timeout—2 seconds, try-time—twice.
z
z router#show snmp-server notify notify
Note:
The command is used to display the notification table configured on the router.
Note:
The command is used to display the notification filtering table configured on the router.
Note:
The command is used to display the notification configuration table configured on the router.
router#show snmp-server notify profile
Note:
The command is used to display the engine group configured on the router.
Command Description
Debug snmp-server all Debug all snmp, excluding response
16.3 Remote Network Monitoring (RMON)
RMON instruction set is listed as follows:
Command Description
router(config)#rmon Activate the RMON
task.
router(config)#no rmon Cancel the RMON
task.
router(config)#rmon alarm <1-65536> <OID> <1-65536> absolute/delta risingthreshold Configure the RMON
<0-2147483647> <1-65536> fallingthreshold <0-2147483647> <1-65536> alarm.
router(config)#rmon event <1-65536> description word log <1-65536> owner <word> Configure the RMON
trap <word> event.
The procedure to configure the remote monitoring RMON on the MP router is described as follows:
Step 1: Start the remote monitoring RMON.
router (config)#rmon < CR >
Step 2: Configure relative alarms and objects that are remotely monitored.
router(config)#rmon alarm <1-65536> <OID> <1-65536> absolute/delta risingthreshold <0-2147483647> <1-65536>
fallingthreshold <0-2147483647> <1-65536>
Note:
The parameter <1-65536> behind rmon alarm is the serial number of the alarm;
The parameter <OID> is the object that is remotely monitored (an index need be added behind the object oid). The
object can be represented with an oid sequence or an oid alias, and the following parameter <1-65536> is the time interval to
sample the value of the parameter <OID>÷
The parameter absolute/delta indicates that the type of sampling is of the absolute/relative value÷
The parameter <0-2147483647> behind the parameter risingthreshold is the rising threshold value, and the parameter
<1-65536> indicates the serial number of the event that arises when the rising threshold value is triggered (the default value
is 1)÷
The parameter <0-2147483647> behind the parameter fallingthreshold is the falling threshold value, and the parameter
<1-65536> indicates the serial number of the event that arises when the falling threshold value is triggered (the default value
is 1);
At present, the rmon has only realized monitoring the 10th –21st objects in the interface table (ifTable) of the standard
MIB. The object alias ifEntry of the interface table has been generated automatically in the OID table when the system starts
up. About some information about supporting OID variable, refer to the command router# show rmon alarm
supportVariable.
Step 3: Configure the action that will be implemented proportionally when the remote monitoring RMON is triggered.
router(config)#rmon event <1-65536> description word log <1-65536> owner <word> trap <word>
Note:
The parameter <1-65536> behind rmon event is the serial number of the event ÷
The parameter word behind description is the description of the event. The parameter log <1-65536> and trap <word>
represents the event action. The parameter log indicates that the recording is implemented in the log; the parameter <1-
65536> represents the maximal number of records÷The parameter trap denotes the remote destination to which the trap
information is sent, and the parameter <word> denotes the community name.
The parameter owner <word> denotes the owner of the event.
An example of RMON Configuration
Remotely monitoring the OID object ifEntry.10 on the interface fastethernet0 of the router demands that the ifEntry.10
should be sampled one time every other 5 seconds (Suppose that the interface index of the interface f0 is 1, the object
instance is ifEntry.10). The rising threshold value and the falling threshold value are 5000 respectively. If the sampling result
triggers the threshold, then the trap message will be sent to the community public. At the same time, it will be recorded in
the log on the router (At most 100 records can be recorded.). The detailed configuration is described as follows:
router (config)#rmon
router (config)#rmon event 1 description Monitoring the number of bytes received on the interface f0
log 100 trap public
RMON debugging commands
The RMON command show is used to display the basic information:
Command Description
router# show rmon event Display the information about the rmon event that has
been configured.
router# show rmon alarm Display the information about the rmon alarm that has
been configured.
router# show rmon alarm supportVariable Examine the monitored objects that rmon supports
presently.
Note:
show rmon event—to display the information about the rmon event that has been set:
router# show rmon event
Output:
Event 1 is active, owned by config
Description : maipu
Event firing causes: log and trap, last fired at 00:25:17
Current log entries:
logIndex logTime Description
----------------------------------------------------------------
4 00:12:27 Rising threshold crossing
5 00:23:26 Rising threshold crossing
6 00:23:36 Rising threshold crossing
7 00:23:46 Rising threshold crossing
8 00:23:56 Rising threshold crossing
9 00:24:07 Rising threshold crossing
10 00:24:27 Rising threshold crossing
11 00:24:47 Rising threshold crossing
12 00:25:07 Rising threshold crossing
13 00:25:17 Rising threshold crossing
show rmon alarm supportVariable——To examine the information about the OID alias of the monitored
objects that are presently supported by rmon.
Output:
Currently support MIB object: (NOTE:be sure to add the index after OID)
After the command has been executed, the result output includes:
At present, rmon has only realized monitoring the 10th –21st objects in the interface table of the standard MIB. The object
alias ifEntry of the interface table has been generated automatically in OID alias table when the system starts up.
16.3 Remote Network Monitoring (RMON)
RMON Instruction Set
Command Description
router(config)#rmon Activates the RMON task.
router(config)#no rmon Cancels the RMON task.
Configures the RMON alarm information.
router(config)#rmon alarm <1-65536> <OID> <1-65536>
absolute/delta risingthreshold <0-2147483647> <1-
65536> fallingthreshold <0-2147483647> <1-65536>
Step Two: Configure the objects that must be remotely monitored by inputting:
router(config)#rmon alarm <1-65536> <OID> <1-65536> absolute/delta risingthreshold <0-2147483647> <1-65536>
fallingthreshold <0-2147483647> <1-65536>
Notes About Step Two:
1) The first <1-65536> parameter (after rmon alarm) is the serial number of the alarm.
2) The <OID> parameter is the object ID that is remotely monitored. The following <1-65536> value is the time
interval parameter that samples the <OID> parameter.
3) Absolute/delta indicates the absolute/relative value.
4) <0-2147483647> after the risingthreshold parameter refers to the rising threshold value, while <1-65536> indicates
the event’s serial number needed when the rising threshold value is triggered.
5) <0-2147483647> after the fallingthreshold parameter refers to the falling threshold value, while <1-65536>
indicates the event’s serial number needed when the falling threshold value is triggered.
Presently, rmon monitors the 10th to 21st objects in the standard MIB interface table. The object alias ifEntry will be
generated automatically in OID table when the system starts.
The following command can output information about the supported OID variable:
router# show rmon alarm supportVariable.
Step Three: Configure the operation when RMON remote monitoring is triggered. Input:
router(config)#rmon event <1-65536> description word log <1-65536> owner <word> trap <word>
Notes About Step Three:
1) The <1-65536> parameter (after rmon event) refers to the event’s serial number.
2) The parameter word after description describes the event. Log <1-65536> and trap <word> indicate the event’s
content: the former refers to the log record and the latter indicates the remote destination where the trap information
is being sent.
3) Owner <word> indicates the owner of the event.
RMON Configuration Example:
Remotely monitor the OID variable ifEntry.10 on the router by demanding that it should be sampled once every five
seconds. The rising and falling threshold values are both 5,000. If the sampled result triggers the threshold, then the trap
information will be sent to public. At the same time, this activity will be recorded in the router’s log.
To start the configuration, input:
router (config)#rmon <cr>
router (config)#rmon alarm 1 ifEntry.10 5 absolute risingthreshold 5000 1 fallingthreshold 5000 1 <cr>
router (config)#romon event 1 description monitoring the variable ifEntry log 1000 trap public
Debugging RMON Commands:
The RMON show command displays the basic information:
Command Description
router# show rmon alarm supportVariable Examines the OID alias data of RMON’s monitored objects.
To display information about the RMON event, input router # show rmon event.
Output:
Description: Maipu
----------------------------------------------------------------
Description:
Output:
Ethern
Command Task
Router(config)# sntp server 129.255.6.88 Configure the IP address of the NTP server with
129.255.6.88.
Syntax Description
Timezone-name The time zone name.
Hour-offset The hour offset relative to UTC time, and its value range is
between –23 and 23.
minute-offset The minute offset relative to UTC time, and its value range
is between 0 and 59.
Ethernet
Command Task
Router(config)# clock timezone chengdu 9 Configure the hour offset relative to UTC standard time with
9.
Chapter 18 Multicast Route Configuration
This chapter mainly introduces the core multicast packet forwarding on a router, IGMP application and the selection of
multicast routes.
Main contents of this chapter are as follows:
Configuring IGMP
Configuring PIM-SM
18.1 Configure IGMP
IGMP (Internet Group Management Protocol) is one of the TCP/IP protocol family that answers for managing the IP
multicast members, and it is mainly used to create and maintain the multicast membership between an IP host and multicast
routers that connect with it directly.
Currently, the IGMP Version 2 is adopted popularly, and it specifies three types of packets: Membership Query packet,
Membership Report packet and Leave Group packet.
Membership-query packet:
According to the different addresses, Membership-query packets are divided into general-query packets (by which the
router can know what members there are in the direct network, with the destination group address being 224.0.0.1) and
group-specific-query packets (by which the router can knows whether there is a specific group member in the direct network,
with the destination group address being 0 or a valid multicast group address).
Membership-report packet:
When receiving a membership-query packet, the host identifies the group on the interface that sends this query packet, and
sets a Host Group Delay timer for each member group. When this timer expires, the host sends a membership-report packet
to this router. When this router receives the packet, it adds this group into the local group member list in the network at which
this group is located, and enables the Group Membership Interval timer. If the router still doesn’t receive any membership-
report packet when the maximal query response timer expires, then this indicates that there is no local group member in the
network, and the router needn’t forward the received multicast packets to the network with which it connects.
Leave-group packet:
IGMP Version 2 allows a host to send a leave-group packet (with the destination group address 224.0.0.2) to all routers
when it leaves a multicast group.
IGMP is unsymmetrical between the host and the router. For the host side, it needs to respond the IGMP query packet of
the multicast router with a membership-report packet; for the router side, it needs to send general-query packets periodically,
and then to determine what members there are in the network at which the router itself is located according to the received
response packets. Subsequently, when receiving the leave-group packet of the host, the router sends a specific-member-query
packet to determine whether there exists no member in a specific group.
Main contents of this chapter are as follows:
Descriptions of commands to configure IGMP
An example of IGMP configuration
Monitoring and debugging IGMP
18.1.1 Descriptions of commands to configure IGMP
ip igmp join-group
This command is used to configure the router interface to be a multicast group member. The form no of this command is
used to delete the router interface from the group membership.
ip igmp join-group groups-address
no ip igmp join-group groups-address
Syntax Description
groups-address Groups-address is the group address to be added into the
multicast group.
£Default¤Invalid.
£Command mode¤The interface configuration mode.
ip igmp query-interval
This command is used to configure the interval for the router to send IGMP query packets. The form no of this command
is used to reset the default value of the interval for the router to send IGMP query packets.
ip igmp query-interval seconds
no ip igmp query-interval
Syntax Description
Seconds The interval to send IGMP query packets, and its value range is between 1
and 65535.
£Default¤The default value of the interval for the router to send IGMP query packets is 60 seconds.
£Command mode¤The interface configuration mode.
ip multicast-routing
This command is used to enable the multicast routing. The form no of this command is used to disable the multicast
routing.
ip multicast-routing
no ip multicast-routing
£Default¤Disables the multicast routing.
£Command mode¤The global configuration mode.
18.1.2 An Example of IGMP Configuration
The example is illustrated as the following figure:
Source (group 224.1.1.23)
Video camera
Video
terminal
Illustration:
The interface s0/1 Ô22.1.1.1Õof the local router router1 adopts the PPP protocol to connect with the interface s1/1Ô
22.1.1.2Õof the opposite-end router router2. The local serverÔ129.255.94.76Õserves as the source the multicast group
224.1.1.23, in which a member (namely a video terminal) connects with the opposite-end router. In fact, the opposite-end can
simultaneously serve as both a multicast source and a video terminal; similarly, the local-end can also serve as a video
terminal.
o The relevant configurations of router1 / router2 are as follows:
Command Task
router1#configure terminal
router1(config)#ip multicastÉrouting Enable the multicast routing protocol.
router1(config)#interface s0/1
router1(config-if-serial0/1)#physical-layer sync
router1(config-if-serial0/1)#clock rate 2000000
router1(config-if-serial0/1)#encapsulation ppp
router1(config-if-serial0/1)#ip address 22.1.1.1
255.255.255.0
This command is used to configure the multicast
router1(config-if-serial0/1)#ip pim sparse-mode routing protocol, also used for all interfaces that forward
multicast.
This command is used to add the local router into
router1(config-if-serial0/1)#ip igmp join-group
the multicast group 224.1.1.23, but it is not necessary,
224.1.1.23
and usually used for debugging.
Modify the default IGMP query interval to be 30
router1(config-if-serial0/1)#ip igmp query-interval 30
seconds.
router1(config-if-serial0/1)# interface f0
router1(config-if-fastethernet0)#ip address
129.255.22.253 255.255.0.0
This command is used to configure the multicast
router1(config-if-fastethernet0)#ip pim sparse-mode routing protocol, and also used for all interfaces that
forward multicast.
router1(config-if-fastethernet0)#exit
router1(config)#ip pim rp-candidate s0/1 Configure multicast RP proxy.
router1(config)#ip pim bsr-candidate s0/1 Configure multicast BSP proxy.
router2#conf t
router2(config)#ip multicastÉrouting Enable the multicast routing.
router2(config)#interface s1/1
router2(config-if-serial1/1)#physical-layer sync
router2(config-if-serial1/1)#encapsulation ppp
router2(config-if-serial1/1)#ip address 22.1.1.2
255.255.255.0
This command is used to configure the multicast
router2(config-if-serial1/1)#ip pim sparse-mode routing protocol, and also used for all interfaces that
forward multicast.
router2(config-if-serial1/1)#interface f0
router2(config-if-fastethernet0)#ip address 130.255.1.1
255.255.0.0
This command is used to configure the multicast
router2(config-if-fastethernet0)#ip pim sparse-mode routing protocol, and also used for all interfaces that
forward multicast.
router2(config-if-fastethernet0)#exit
Notice:
Please implement the configuration strictly according to the Configuration Manual.
What is discussed here is about the command enable multicast routing and the relevant IGMP management configuration.
For the detailed configuration of the multicast communication, please go on referring to the following sections.
18.1.3 Monitoring and Debugging IGMP
show ip igmp groups
This command is used to display the state of multicast group members, which are gotten from the IGMP information, in
the direct network.
show ip igmp groups
£Command mode¤The privilege user mode.
show ip igmp interface
This command is used to display the IGMP interface information.
show ip igmp interface
£Command mode¤The privilege user mode.
show ip igmp stat
This command is used to display the status information of IGMP packets.
show ip igmp stat
£Command mode¤The privilege user mode.
debug ip igmp
This command is used to display the IGMP DEBUG information, including IGMP sending/receiving packets, and
adding/deleting group members.
debug ip igmp
£Command mode¤The privilege user mode.
£Default¤If this command is not followed by the parameter group-list, then it indicates that this RP is the candidate RP
for all groups.
£Command mode¤The global configuration mode.
Note:
In PIM-SM protocol, the sharing RPT (RP Path Tree) that is created by the route multicast data contains one root (one
rendezvous point) and multiple leaves (multiple group members). The RP is voted through BSR selection. After the BSR is
generated, all C-RPs (Candidate RP) unicasts C-RP messages to the BSR periodically,, and then the BSR diffuse these
messages to the entire PIM area.
It is suggested that the C-RP of the corresponding multicast group should be as close to the corresponding multicast
source as possible when it is configured.
ip pim sparse-mode
This command is used to enable PIM-SM protocol on the interface, simultaneously, to enable IGMP protocol (of the router
version) on the interface if it is not enabled yet. The form no of this command is used to disable PIM-SM protocol on the
interface.
ip pim sparse-mode
no ip pim sparse-mode
£Default¤ PIM-SM is disabled on an interface.
£Command mode¤The interface configuration mode.
18.2.2 An PIM-SM Configuration Example
The example is illustrated as the following figure:
Video terminal A
Video camera A
Frame relay
Video terminal B
Video terminal C
Video camera C
Illustration:
The interface s2/0 Ô22.1.1.1Õof Router A adopts PPP protocol to connect with the interface s0/0Ô22.1.1.2Õof the
opposite-end Router. The interface s3/0 Ô22.2.2.1Õof the Router B adopts the frame-delay to connect with the interface
s0/0Ô22.2.2.2Õof the opposite-end Router C. The three routers connect respectively with different multicast group sources,
which serve as the receiving-ends simultaneously.
o The router A configuration is as follows:
Command Task
routerA#configure terminal
routerA(config)#ip multicastÉrouting Enable the multicast routing.
routerA(config)#interface s2/0
routerA(config-if-serial2/0)#physical-layer sync
routerA(config-if-serial2/0)#clock rate 1800000
routerA(config-if-serial2/0)#encapsulation ppp
routerA(config-if-serial2/0)#ip address 22.1.1.1 255.255.255.0
routerA(config-if-serial2/0)#ip pim sparse-mode This command is used to configure the
multicast routing protocol, and used for all
interfaces that forward multicasts.
routerA(config-if-serial2/0)#interface f0
routerA(config-if-fastethernet0)#ip address 80.255.22.253 255.255.0.0
routerA(config-if-fastethernet0)#ip pim sparse-mode This command is used to configure the
multicast routing protocol, and used for all
interfaces that forward multicasts.
routerA(config-if-fastethernet0)#exit
routerA(config)#ip access-list standard 1 Configure the standard access list.
routerA(config-std-nacl)#permit host 230.1.1.1 Configure the usage range of the access list.
routerA(config-std-nacl)#exit
routerA(config)#ip pim rp-candidate fastethernet0 group-list 1 Configure the RP proxy of the specified
group.
routerA(config)#ip pim bsr-candidate s2/0 Configure the multicast BSR proxy.
routerA(config)#router ospf 1
routerA(config-ospf)#network 22.1.1.0 0.0.0.255 area 5
routerA(config-ospf)#network 80.255.0 0.0.255.255 area 5
o The router B configuration is as follows:
Command Task
routerB(config)# configure terminal
routerB(config)#ip multicastÉrouting Enable the multicast routing.
routerB(config)#frame-relay switching
routerB(config)#interface s0/0
routerB(config-if-serial0/0)#physical-layer sync sync
routerB(config-if-serial0/0)#encapsulation ppp
routerB(config-if-serial0/0)#ip address 22.1.1.2
255.255.255.0
routerB(config-if-serial0/0)#ip pim sparse-mode This command is used configure the multicast
routing protocol, and used for all interfaces that
forward multicasts.
routerB(config-if-serial0/0)#interface f0
routerB(config-if-fastethernet0)#ip address 129.255.22.253
255.255.0.0
routerB(config-if-fastethernet0)#ip pim sparse-mode This command is used to configure the multicast
routing protocol, and used for all interfaces that
forward multicasts.
routerB(config-if-fastethernet0)#interface serial3/0
routerB(config-if-serial3/0)#clock rate 2000000
routerB(config-if-serial3/0)#ip address 22.2.2.1
255.255.255.0
routerB(config-if-serial3/0)#ip pim sparse-mode
routerB(config-if-serial3/0)#encapsulation frame-relay
routerB(config-if-serial3/0)#frame-relay intf-type dce
routerB(config-if-serial3/0)#frame-relay interface-dlci 100
routerB(config-if-serial3/0)#frame-relay map ip 22.2.2.2 100
broadcast
routerB(config-if-serial3/0)#exit
routerB(config)#ip access-list standard 1 Configure the standard access list.
routerB(config-std-nacl)#permit host 224.1.1.2 Configure the usage range of the access list.
routerB(config-std-nacl)#exit
routerB(config)#ip pim rp-candidate fastethernet0 group-list Configure the RP proxy of a specific group.
1
routerB(config)#router ospf 1
routerB(config-ospf)#network 22.0.0.0 0.255.255.255 area 5 Enable the OSFP on interfaces s0/0 and s3/0..
routerB(config-ospf)#network 129.255.0.0 0.0.255.255.255 Enable the OSFP on the interface f0.
area 5
o The Router C is configured as follows:
Command Task
routerC(config)# configure terminal
routerC(config)#ip multicast-routing Enable the multicast routing.
routerC(config)#int s0/0
routerC(config-if-serial0/0)#ip address 22.2.2.2
255.255.255.0
routerC(config-if-serial0/0)#ip pim sparse-mode This command is used to configure the multicast
routing protocol, and used for all interfaces that
forward multicasts.
routerC(config-if-serial0/0)#encapsulation frame-relay
routerC(config-if-serial0/0)#frame-relay intf-type dte
routerC(config-if-serial0/0)#frame-relay interface-dlci 100
routerC(config-if-serial0/0)#frame-relay map ip 22.2.2.1
100 broadcast
routerC(config-if-serial0/0)#interface f0
routerC(config-if-fastethernet0)#ip address 94.255.22.33
255.255.0.0
routerC(config-if-fastethernet0)#ip pim sparse-mode This command is used to configure the multicast
routing protocol, and used for all interfaces that
forward multicasts.
routerC(config-if-fastethernet0)#exit
routerC(config)#ip access-list standard 1
routerC(config-std-nacl)#permit host 224.2.2.3 Configure the usage range of the access list.
routerC(config-std-nacl)#exit
routerC(config)#ip pim rp-candidate f0 group-list 1 Configure the RP proxy of a specific group.
routerC(config)#router ospf 1
routerC(config-ospf)#network 22.2.2.0 0.0.0.255 area 5
routerC(config-ospf)#network 94.255.0.0 0.0.255.255 area 5
Note:
Please implement the configuration strictly according to the Configuration Manual.
What is discussed here is the basic configuration specification for multicast communication. Multicast also supports other
link layer protocols and dynamic routing protocols. Their configurations aren’t described here.
18.2.3 Monitoring and Debugging PIM-SM
show ip mcache
This command is used to display the cache information of the core multicast route.
show ip mcache
£Command mode¤The privilege user mode.
show ip mroute
This command is used to display the information about a PIM multicast route list.
show ip mroute
£Command mode¤The privilege user mode.
show ip pim bsr
This command is used to display the information about the PIM bootstrap router.
show ip pim bsr
£Command mode¤The privilege user mode.
show ip pim interface
This command is used to display the information about the PIM interface.
show ip pim interface
£Command mode¤The privilege user mode.
show ip pim neighbor
This command is used to display the information about PIM neighbors.
show ip pim neighbor
£Command mode¤The privilege user mode.
show ip pim rp
This command is used to display the information about the PIM RP (Rendezvous Point).
show ip pim rp
£Command mode¤The privilege user mode.
Router1 Router2
Pc1 Pc2
Illustration:
As shown in figure above, the interface s1/0 of router1 connects to the interface s1/2 of router2 by means of PPP protocol. At
the same time, the Ethernet interfaces of the two routers connects with two PCs that can serve as the multicast source or
multicast receiving-end
Router1 is configured as follows.:
R
Syntax Descriptions
outer2
router1#configure terminal
router1 (config)#ip multicastÉrouting Enable the multicast routing. is
router1 (config)# interface fastethernet0 config
router1 (config-if-fastethernet0)# ip address ured
131.255.127.3 255.255.0.0
router1 (config-if-fastethernet0)# ip dvmrp Configure the multicast routing protocol as
DVMRP. follow
The command can be applied to all
interfaces forwarding multicast packets. s.:
router1 (config-if-fastethernet0)# interface
serial1/0
router1 (config-if-serial1/0)# physical-layer sync
router1 (config-if-serial1/0)#encapsulation ppp
router1 (config-if-serial1/0)# ip address 8.0.0.1
255.0.0.0
router1 (config-if-serial1/0)# ip dvmrp Configure the multicast routing protocol
DVMRP.
The command can be applied to all
interfaces forwarding multicast packets.
router1 (config-if-serial1/0)# exit
Syntax Descriptions
Notice
Router2#configure terminal
Router2(config)#ip multicastÉrouting Enable the multicast routing. ö
Router2(config)# interface fastethernet0
T
Router2(config-if-fastethernet0)# ip address
151.255.127.6 255.255.0.0 he
Router2(config-if-fastethernet0)# ip dvmrp Configure the multicast routing protocol routin
DVMRP. g
protoc
The command can be applied to all interfaces
forwarding multicast packets. ol
need
Router2(config-if-fastethernet0)# interface
not be
serial2/1
config
Router2(config-if-serial2/1)# physical-layer sync
ured
Router2(config-if-serial2/1)#clock rate 2000000 for
Router2(config-if-serial2/1)#encapsulation ppp DVM
Router2(config-if-serial2/1)# ip address 8.0.0.26 RP.
255.0.0.0 H
Router2(config-if-serial2/1)# ip dvmrp Configure the multicast routing protocol ere is
DVMRP. the
The command can be applied to all interfaces basic
forwarding multicast packets. config
Router2(config-if-serial2/1)# exit uration
descri
ption of multicast communication. The multicast can also support other link-layer protocols, and corresponding
examples are not listed here.
18.3.3 DVMRP Monitoring and Debugging
show ip dvmrp interface
Use the command above to display the information about DVMRP interface.
show ip dvmrp interface
£Command mode¤the privileged user configuration mode.
show ip dvmrp neighbor
Use the command above to display the information about DVMRP neighbors.
show ip dvmrp neighbor
£Command mode¤the privileged user configuration mode.
show ip dvmrp route
Use the command above to display the information about DVMRP route.
show ip dvmrp route
£Command mode¤the privileged user configuration mode.
debug ip dvmrp all
Use the command above to display all DEBUG information about DVMRP.
debug ip dvmrp all
£Command mode¤the privileged user configuration mode.
debug ip dvmrp cache
Use the command above to display the DEBUG information about DVMRP core cache.
debug ip dvmrp cache
£Command mode¤the privileged user configuration mode.
debug ip dvmrp member
Use the command above to display the DEBUG information about DVMRP member joining-in/leaving.
debug ip dvmrp member
£Command mode¤the privileged user configuration mode.
debug ip dvmrp packet
Use the command above to display the DEBUG information about DVMRP packets.
debug ip dvmrp packet
£Command mode¤the privileged user configuration mode.
debug ip dvmrp peer
Use the command above to display the DEBUG information about DVMRP neighbor event.
debug ip dvmrp peer
£Command mode¤the privileged user configuration mode.
debug ip dvmrp prune
Use the command above to display the DEBUG information about DVMRP prune.
debug ip dvmrp prune
£Command mode¤the privileged user configuration mode.
debug ip dvmrp route
Use the command above to display the DEBUG information about DVMRP route.
debug ip dvmrp route
£Command mode¤the privileged user configuration mode.
Chapter 19 AAA Configuration
This chapter mainly describes how to configure AAA (Authentication, Authorization and Accounting) on the router. AAA
is the abbreviation of Authentication, Authorization and Accounting. As a client program that runs on the network access
server (NAS), it provides a consistent framework for you to configure the three security functions, Authentication,
Authorization and Accounting.
The main contents of this chapter are as follows:
Command descriptions of configuring the relevant AAA;
An example of AAA configuration;
Debugging AAA
19.1 Descriptions of Command Relevant with AAA
aaa new-mode
This command is used to enable AAA on the router. The form no of the command is used to close AAA function.
aaa new-model
no aaa new-model
£Default¤Disable AAA.
£Command mode¤The global configuration mode.
aaa authentication banner
This command is used to modify the displayed welcome information when you login on a router. The form no of the
command is used to reset the default welcome information.
aaa authentication banner banner
no aaa authentication banner
Syntax Description
banner This is the welcome information displayed on the
screen when you log in the router.
£Default¤The default welcome information is “User Access Verification”.
£Command mode¤The global configuration mode.
aaa authentication fail-message
This command is used to modify the caution information when you fail to login on the router. The form no of the command
is used to reset the default caution information.
aaa authentication fail-message fail-message
no aaa authentication fail-message
Syntax Description
fail-message This is the caution information when you fail to login
on the router.
£Default¤The default caution information is “Access denied!”.
£Command mode¤The global configuration mode.
aaa authentication username-prompt
This command is used to modify the displayed text that is used to prompt you to input user name. The form no of this
command is used to reset the default-displayed text.
aaa authentication username-prompt username-prompt
no aaa authentication username-prompt
Syntax Description
username-prompt The displayed text when you are cautioned to input
your user name.
£Default¤The default displayed text is “login:”.
£Command mode¤The global configuration mode.
aaa authentication password-prompt
This command is used to modify the displayed text when you are cautioned to input your passport. The form no of this
command is used to reset the default-displayed text.
aaa authentication password-prompt password-prompt
no aaa authentication password-prompt
Syntax Description
password-prompt The displayed text when you are cautioned to input
your passport.
£Default¤The default displayed text is “passport:”.
£Command mode¤The global configuration mode.
aaa authentication login
This command is used to configure the login identity authentication method list. The form no of this command is used to
delete the method list.
aaa authentication login {default|list-name} method1[method2…]
no aaa authentication login {default|list-name}
Syntax Description
default Define the default method list.
list-name This is the method list name.
method Authentication methods:
None: Pass directly without authenticating the identity,.
Enable: Use the valid passport to authenticate the identity (the global
enable passport).
Local: Use the local user database to authenticate the identity.
Line: Use the line passport to authenticate the identity.
Radius: Use RADIUS to authenticate the identity.
Tacacs: Use TACACS to authenticate the identity.
£Default¤No authentication method list is defined.
£Command mode¤The global configuration mode.
Note:
Cooperating with the command login authentication in line mode, the method list can be used to authenticate the login
identities for some lines.
The default method list applies to all the interfaces and lines (except the interfaces or lines that are defined explicitly and
referred to) automatically.
aaa authentication enable
This command is used to configure the identity authentication method list for you to enter the privilege user mode. The form
no of this command is used to deletes the method list.
aaa authentication enable default method1[method2…]
no aaa authentication enable default
Syntax Description
default Define the default method list.
method Authentication methods:
None: Pass directly without authenticating the identity,
Enable: Use the valid passport to authenticate the identity (the user enable passport or
the global enable passport).
Line: Use the line passport to authenticate the identity.
Radius: Use RADIUS to authenticate the identity.
TacacsÖUse TACACS to authenticate the identity.
£Default¤No authentication method list is defined.
£Command mode¤The global configuration mode.
Note:
When using the radius authentication method, you should use the passport of the user $enab15$ (need to be set on the radius
server) as the authentication passport.
aaa authentication ppp
This command is used to configure a PPP identity authentication method list. The form no of this command is used to delete
the method list.
aaa authentication ppp list-name method1[method2…]
no aaa authentication ppp list-name
Syntax Description
list-name This is the method list name.
method Authentication methods:
None: Pass directly without authenticating the identity.
Local: Use the local user database to authenticate the identity.
Radius: Use RADIUS to authenticate the identity.
Tacacs: Use TACACS to authenticate the identity.
£Default¤No authentication method list is defined.
£Command mode¤The global configuration mode.
£Usage specification¤This method needs to cooperate with the command ppp authentication to apply the method list to
the PPP authentication of an interface.
aaa authorization
This command is used to limit the user access authorization. The form no of the command is used to allow the access
authorization.
aaa authorization {exec|network} {default|list-name} method1[method2…]
no aaa authorization {exec|network} {default|list-name}
Syntax Description
exec Configure the EXEC authorization command method list.
network Configure the authorization method list of the network service.
default Define a default method list.
list-name This is the method list name.
method Authorization methods:
if-authenticated : If a user passes the identity authentication, then he is authorized to
access the request function.
Local: Use the local database to authorize.
None: Operate no authorization.
Radius: Request the authorization information from RADIUS server.
Tacacs: Request the authorization information from TACACS server.
£Default¤No access authorization is limited (being equivalent to the keyword none).
£Command mode¤The global configuration mode.
Note:
1) When the EXEC authorization method list has been configured and you execute EXEC, NAS can implement the
authentication to you to determine whether you have the authorization to execute the EXEC shell program; if NAS fails to
authorize, then you can’t execute EXEC.
2) EXEC supports the authorization of Vendor-specific AV of ciscoSecureACS radius (Cisco), and AV is defined as
follows:
Define autocmd—auto-command, value is the command string, and its format is:
autocmd=STRING
Define nohangup—whether the connection is broken after the system executes the auto-command, and its format
is:
nohangup=FALSE/TRUE or 0/1
Define priv-lvl—the right level authorized to the login user, the range of value is from 0 to 15, and its format is:
priv-lvl=NUM
Define timeout—the entire connection time authorized to the login user, value is a number (by second), and its
format is:
timeout=NUM
aaa accounting
This command is used to configure the AAA accounting method list. The form no of this command is used to cancel the
method list.
aaa accounting {connection|exec|network} {default|list-name} {none|start-stop| stop-only| wait-start} method1[method2]
no aaa accounting {connection|exec|network} list-name
Syntax Description
connection Configure the accounting command that the user uses when he logins to other routers
through telnet or rlogin.
exec Configure the accounting command of enabling the EXEC session.
network Configure all accounting commands of the service requests that are relevant with the
network.
default Define a default method list.
list-name This is the method list name.
none Don’t process accounting.
start-stop Send a start-accounting notice when a process starts, and send an end-accounting notice
when the process ends. Whether or not the server receives the start-accounting notice, all
requested user processes will start to execute.
stop-only Send an end-accounting notice when the requested user process ends.
wait-start Send a start-accounting notice and an end-accounting notice to the AAA accounting
server. The requested user service isn’t enabled until the notices above are acknowledged.
method accounting methods:
Radius: send the accounting information to the RADIUS server.
Tacacs: send the accounting information to the TACACS server.
Note:
To execute the accounting work as little as possible, you can use the keyword stop-only to send a stop-record-accounting
notice when a requested user process ends.
To get more accounting information, you can use the keyword start-stop. In this way, RADIUS or TACACS can send a
start-accounting notice when the requested process starts, and can send an end-accounting notice when the process ends.
To obtain more control right to the accounting , you can use wait-start, which ensures that the process request of the user
can’t be authorized until the RADIUS or TACACS server receives the start-accounting notice.
aaa accounting suppress null-username
This command is used to forbid creating a accounting record for the user whose user name is null. The form no of this
command is used to allow creating a accounting record for the user whose user name is null.
aaa accounting suppress null-username
no aaa accounting suppress null-username
ûDefaultüAllow to create a accounting record for the user whose user name is null.
tacacs-server host
This command is used to configure the Tacacs server. The form no of this command is used to delete the Tacacs server.
tacacs-server host address [key key] [port port] [timeout timeout]
no tacacs-server host address
Syntax Description
address The address of the Tacacs server.
key The key that is used for the communication between the router and the
Tacacs server.
port The TCP port number that is used to connect with the Tacacs
background program.
timeout Set the interval timer for waiting the response from the Tacacs server.
This command is used to configure the encryption key of the Tacacs. The form no of this command is used to delete the
key.
tacacs-server key key
no tacacs-server key
tacacs-server timeout
The command is used to configure the interval timer for waiting the Tacacs server response. The form no of this command is
used to reset the default value.
tacacs-server timeout timeout
no tacacs-server timeout
ûDefaultü5 seconds.
radius-server host
This command is used to configure the RADIUS server. The form no of this command is used to delete the RADIUS
server.
radius-server host address [acc-port acc-port] [auth-port auth-port]
no radius-server host address
Syntax Description
address The address of the RADIUS server.
acc-port The UDP destination port that is specified for the authentication
request.
auth-port The UDP destination port that is specified for the accounting
request.
radius-server dead-time
This command is used to configure dead-time. The form no of this command is used to set dead-time to be 0.
radius-server dead-time dead-time
no radius-server dead-time
Syntax Description
dead-time This is the time length. During the time, no request is
sent to the RADIUS server
ûUsage guideüAfter the command is used, the system labels the RADIUS severs that don’t respond to the authentication
requests as unusable, and don’t send requests to these servers during the dead-time period of time.
radius-server key
This command is used to configure the RADIUS encryption key. The form no of this command is used to delete the RADIUS
encryption key.
radius-server key key
no radius-server key
radius-server timeout
This command is used to configure the interval timer for waiting the response from RADIUS server. The form no of this
command is used to reset the default value.
radius-server timeout timeout
no radius-server timeout
£Default¤5 seconds.
£Command mode¤The global configuration mode.
radius-server retransmit
This command is used to configure the maximum times of retransmitting a packet to the RADIUS server. The form no of
this command is used to reset the default value.
radius-server retransmit retries
no radius-server timeout
Syntax Description
retries The maximum times of retransmitting a packet.
£Default¤3 times.
£Command mode¤The global configuration mode.
ip {tacacs|radius} source-interface
This command is used to configure the interface address, which is specified for the router to switch packets with the
RADIUS or TACACS server. The form no of this command is used to reset the default value.
ip {tacacs|radius} source-interface interface-name
no ip {tacacs|radius} source-interface
Syntax Description
interface-name The interface name.
Network access
User
Illustration:
In the configuration above, the PPP protocol is encapsulated between the user devices and the network access server
(NAS), and login authentication uses the default method list.
The relevant NAS configurations are as follows:
Command Task
NAS#configure terminal Enter the configuration mode.
NAS (config)# aaa new-model Enable AAA authentication.
NAS (config)# aaa authentication banner Configure the welcome words for a use to login.
^ Welcome ^
NAS (config)# aaa authentication fail- Configure the prompt information for a user to fail to login.
message ^ Sorry, Don’t come in ^
NAS (config)# aaa authentication login The authentication methods (radius, tacacs and none) are adopted for
default radius tacacs none identification authentication of the telnet or rlogin user. (One or more
authentication methods can be selected.)
NAS (config)# aaa authentication enable The authentication method radius enable is adopted for the telnet or
default radius enable rlogin user to enter the privilege use mode.
NAS (config)# aaa authentication ppp Configure the PPP authentication, and cooperate with the command ppp
auth-name radius tacacs local authentication on the interface s1/0.
NAS (config)# aaa authorization exec Configure that only users who are added into the RADIUS server can be
default radius authorized to execute the EXEC shell program; if the authorization fails, then
the users cannot execute EXEC.
NAS (config)# aaa accounting exec default Enable the accounting command of the exec session, and a stop-
stop-only radius accounting notice is sent to the RADIUS server when the requested user
process ends.
NAS (config)# aaa accounting connection Enable the accounting command connection, and implement the
default stop-only radius accounting when NAS logins on other router through telnet or rlogin.
NAS (config)# aaa accounting network list Enable the accounting command (list) that the PPP service requests.
stop-only radius (Because the PPP protocol is encapsulated between the user devices and the
NAS.)
NAS (config)# radius-server host Configure the address of the RADIUS server.
192.168.0.1
NAS (config)# radius-server key maipu Configure the key of the RADIUS server, and the key must be the same
as that of the NAS server on the RADIUS server.
NAS (config)# tacacs-server host Configure the address and key of the TACACS server, and the key must
192.168.0.2 key mp be the same as that of the NAS server on the RADIUS server.
NAS (config)#interface s1/0 Enter the interface mode.
NAS(config-if-serial1/0)#ppp accounting Enable the PPP authentication accounting on the interface. Its name is
list list, which is the same as that following aaa accounting network.
Note:
Please implement the configuration strictly according to the Configuration Manual.
During the course of adopting the configured method list to authenticate a user, only when the previous method doesn’t
response can the router try the next method. If the identity authentication fails at any point of the period, namely, the security
server or the local user name database response in the form of denying the user to access, then the identity authentication
process will end and no other identity authentication method will be tried.
19.3 Checking and Debugging AAA
show accounting
This command is used to display the AAA accounting information.
show accounting
£Command mode¤The privilege user mode.
debug aaa authentication
This command is used to open the switch of AAA authentication debugging information. The form no of this command is
used to close the switch.
debug aaa authentication
no debug aaa authentication
£Command mode¤The privilege user mode.
debug aaa authorization
This command is used to open the switch of AAA authorization debugging information. The form no of this command is
used to close the switch.
debug aaa authorization
no debug aaa authorization
£Command mode¤The privilege user mode.
debug aaa accounting
This command is used to open the switch of AAA accounting debugging information. The form no of this command is used
to close the switch.
debug aaa accounting
no debug aaa accounting
£Command mode¤The privilege user mode.
debug tacacs
This command is used to open the switch of TACACS debugging information. The form no of this command is used to close
the switch.
debug tacacs
no debug tacacs
£Command mode¤The privilege user mode.
debug radius
This command is used to open the switch for RADIUS debugging information. The form no of this command is used to close
the switch of RADIUS debugging information.
debug radius [in-plain]
no debug radius
Syntax Description
in-plain Display the RADIUS packet information in the form of
plaintext.
£Command mode¤The privilege user mode.
£Default¤5 seconds.
£Command mode¤The interface configuration mode.
Note:
Through sending the Hello packet periodically, LSR finds or maintains a Hello neighbor.
mpls ldp hello-hold-interval
This command is used to set the hold time of ldp hello. The hold time specifies the maximum hold time (by second) for the
LSR to keep the previous Hello message before sending the next Hello message to its peer. LSRs can, through respectively
putting forward its own Hello hold time firstly, negotiate the Hello hold time with each other and then adopt the minimum
value of them. The form no of this command is used to reset the default value of the Hello hold time.
mpls ldp hello-hold-interval <1-60>
no mpls ldp hello-hold-interval
Syntax Description
1-60 Hello hold time.
£Default¤15 seconds.
£Command mode¤The interface configuration mode.
Note:
LSR maintains a Hello hold timer for each Hello neighbor peer. When an LSR receives a Hello message from a specific
Hello neighbor, the corresponding Hello hold timer will be restarted. If the LSR hasn’t still received the next Hello message
from the specific Hello neighbor when the Hello hold timer expires, then LSR deletes this Hello neighbor, and sends the
corresponding announcement message; subsequently, closes the TCP connection and ends the LDP session.
Hello hold time being 0 indicates the default value. For a link Hello message (connecting with the neighbor directly), the
default value is 15s; while for a destination Hello message (not connecting with the neighbor directly), the default value is
45s.
mpls ldp keepalive-interval
This command is used to set the interval (by second) for LSR to send a Keepalive message periodically. The form no of
this command is used to reset the default setting of the Keepalive message.
mpls ldp keepalive-interval <1-60>
no mpls keepalive-interval
Syntax Description
1-60 The interval for LSR to send a Keepalive message periodically.
£Default¤15 seconds.
£Command mode¤The interface configuration mode.
Note:
An LSR must ensure that the LDP peer can receive at least one LDP message (any LDP message is effective) in the
keepalive-interval. But if there is no other LDP message for LSR to send, then LSR must send a session hold message.
mpls ldp keepalive-hold-interval
This command is used to set the ldp session hold interval. LSRs can, through putting forward its own session hold interval
respectively, negotiate the session hold interval with each other, and then adopts the minimum value of them. The form no of
this command is used to reset the default value of the session hold interval.
mpls ldp keepalive-hold-interval
no mpls ldp keepalive-hold-interval
Syntax Description
1-60 The ldp session hold interval.
£Default¤45 seconds.
£Command mode¤The interface configuration mode.
Note:
Through the LDP PDU received from the session transmission connection, an LDP checks the integrality of the LDP
session. The LSR maintains a session hold timer for each LDP session connection, and the corresponding session hold timer
can be restarted when the LSR receives the LDP PDU from a specific session connection. If the LSR hasn’t still received
LDP PDU from the LDP peer when the session hold timer expires, then LSR sends an announcement message, closes the
TCP connection and ends the LDP session.
mpls route-cache
The MPLS fast switching is realized through route cache mechanism. The purpose of the route cache is to reduce the
repeated searching of a routing table and to accelerate the packets sending speed through using previous cache searching
results. But under certain circumstances, users can choose to enable/disable the following two places to process route cache.
mpls route-cache
no mpls route-cache
£Command mode¤The interface configuration mode.
Note:
The mpls fast switching is turned on by default, The form no of this command is used to disable this function.
20.3 An Example of MPLS\VPN Configuration
Illustration:
In the configuration figure above, router1 and router3 are PE devices, and router2 is a P device. P\PE devices construct
the MPLS backbone network, in which the IGP routing protocol OSFP is running. IBGP is running between two PE devices
that respectively connect with two different networks----VPNA\VPNB. Through BGP announcing the VRF table, the
network vrf_a in router1 interconnects with the network vrf_a in router3, and the network vrf_b in router1 interconnects with
the network vrf_b in router3. VPNs are realized through MPLS\BGP.
The concrete configuration of Router1 is as follows:
Command Task
Router1(config)# mpls ip Run MPLS.
Router1(config)# ip vrf vrf_a Create a vrfa
Router1(config -vrf)# rd 1:1 Configure the route descriptor.
Router1(config -vrf)# route-target export 1:1 Set properties of the destination VPN.
Router1(config -vrf)# route-target import 1:1 Set properties of the destination VPN.
Router1(config -vrf)#exit
Router1(config)# ip vrf vrf_b Create a vrfb.
Router1(config -vrf)# rd 2:2 Configure the route descriptor.
Router1(config -vrf)# route-target export 2:2 Set properties of the destination VPN.
Router1(config -vrf)# route-target import 2:2 Set properties of the destination VPN.
Router1(config -vrf)#exit
Router1(config)# interface loopback0 Configure the loopback address with 12.12.12.12.
Router1 (config-if-loopback0)# ip address 12.12.12.12
255.255.255.255
Router1 (config-if-loopback0)# interface fastethernet 1/0
Router1 (config-if-fastethernet1/0)# ip vrf forwarding vrf_a Add the interface into the vrfa.
Router1 (config-if-fastethernet1/0)# ip address 10.1.1.1 Configure the IP address.
255.255.0.0
Router1 (config-if- fastethernet1/0)# interface fastethernet 1/1
Router1 (config-if-fastethernet1/1)# ip vrf forwarding vrf_b Add the interface into the vrfb.
Router1 (config-if-fastethernet1/1)# ip address 10.2.1.1 Configure the IP address.
255.255.0.0
Router1 (config-if-fastethernet1/1)#interface serial0/1
Router1 (config -if-serial0/1)# encapsulation ppp Encapsulate PPP.
Router1 (config -if-serial0/1)# ppp mpls Use MPLS on the interface (when the link layer protocol
is PPP).
Router1 (config -if-serial0/1)# ip address 21.2.1.1 255.255.0.0
Router1 (config -if-serial0/1)# mpls ip Use MPLS on the interface.
Router1 (config -if-serial0/1)# exit
Router1 (config)# router ospf 1 Configure IGP (OSPF).
Router1 (config-ospf)# network 12.12.12.12 0.0.0.0 area 0
Router1 (config-ospf)# network 21.2.0.0 0.0.255.255 area 0
Router1 (config-ospf)#exit
Router1 (config)#router bgp 100 Configure BGP, and the AS number is 100.
Router1 (config -bgp)# no synchronization Set the asynchronous mode between BGP and IGP.
Router1 (config -bgp)# neighbor 14.14.14.14 remote-as 100 Specify the AS number of the BGP peer.
Router1 (config -bgp)# neighbor 14.14.14.14 update-source Specify TCP connection port.
loopback0
Router1 (config-bgp)# address-family ipv4 vrf vrf_a Configure the vrf_a address family.
Router1(config-bgp-af)# no synchronization Set the asynchronous mode between BGP and IGP
Router1 (config-bgp-af)# redistribute connected Redistribute direct routes.
Router1 (config-bgp-af)exit
Router1 (config –bgp)# address-family ipv4 vrf vrf_b Configure the vrf_b address family.
Router1 (config-bgp-af)# no synchronization Set the asynchronous mode between BGP and IGP.
Router1 (config-bgp-af)# redistribute connected Redistribute direct routes.
Router1 (config-bgp-af)#exit
Router1 (config-bgp)# address-family vpnv4 Configure the VPN address family.
Router1 (config-bgp-af)# neighbor 14.14.14.14 activate
Router1 (config-bgp-af)# neighbor 14.14.14.14 next-hop-self
Router1 (config-bgp-af)# neighbor 14.14.14.14 send-community Send properties of the expanded community to the peer.
extended
Router1 (config-bgp-af)#exit
Router1 (config-bgp)#exit
The software upgrade of Maipu router includes two kinds of situations. One is the upgrade of the ROOT program (Namely
Monitor or the root program), and its main functions include the management and allocation of the flash space, with the low
upgrade-frequency; and the other is the upgrade of the program (IOS) in a router. When functions of the router need be
expanded, the program (IOS) need be upgraded.
21.1.1 Upgrade the Hex File of the ROOT program through the Console Interface
The function Hyper Terminal provided by Windows 95/98/NT is used to send the upgrading program to the router. The
following will, taking example for the Hyper Terminal application in Windows, describe the upgrade process.
Step 1: Set the Hyper Terminal.
Start the Hyper Terminal application and select the corresponding serial port (such as COM 1) and set its attributes: 9600
baud rate, the soft flow control, eight data bits, no parity and one stop bit.
Step 2: Enter the Monitor mode.
If some information similar to “Monitor version 2.02 is Booting (^c enter monitor mode) ...” is displayed on the screen
when the router starts up, you can press “CTRL+C” to enter the Monitor mode immediately. The prompt character of the
mode is “mpMonitor:>” or “Monitor:>”.
If no foregoing information is displayed on the screen when the router starts up, you need set the baud rate of the Hyper
Terminal as 115200, restart the router, and then press the key ENTER to enter the Monitor mode.
Step 3æReconfigure the speed of the Console interface and the Hyper Terminal to upgrade the hex file of the ROOT
program.
When the prompt character “mpMonitor:>” or “Monitor:>” appears, the command “mpMonitor:>s 115200” is used to set
the speed of the Console interface as 115200bps. At the same time, the speed of the Hyper Terminal is set as 115200bps
(attribute-configuration-baud rate). Stop the connection in the Hyper Terminal and start the connection again. Press “lr
<CR>” behind “mpMonitor:>” and select the option ‘Send text file’ in the menu ‘Transmit’. After the ROOT program (hex
file) that will be upgraded is selected, its transmission starts. After the upgrade ends, set the attributes of the Hyper Terminal
back to the initial setting, and restart it.
You can, according to the information “Monitor version xxx is Booting (^c enter monitor mode) ...”, judge whether the
ROOT program is upgraded successfully.
Noteö
ö
Different modesof Maipu router may adopt different ROOT program. Before the ROOT program is upgraded, please
affirm whether the ROOT program that need be upgraded is suit for the model of Maipu router lest the upgrading mistake
make the router unusable.
After the ROOT program of Maipu low-end router is upgraded from v1.xx to v2.xx or 3.xx, the MAC address of the router
may be changed. To keep the MAC address exclusive and avoid the address conflict that may result in the network fault,
please notice that one ROOT program can only be upgraded on one router.
To void the MAC address conflict resulting from upgrading ROOT as possible, the MAC address of the Ethernet interface
of the router isn’t changed after the ROOT program of Maipu low-end router is upgraded from v2.xx to v3.xx. If you want to
change the MAC address, please refer to step 3----use the command “lr filename r <CR>” to upgrade the ROOT program.
And the filename can be the combination of any letters.
Maipu router provides three kinds of methods for the software upgrade. These methods can ceaselessly extend functions of
the router. The following is to describe the three methods of the software upgrade.
###################################################################################
OK
21.2.2 Upgrade the Bin File of an Application through the Console Interface
Noteö
ö
The purpose of setting the baud rate as 115200bps is only to improve the transmission speed and reduce the time of
upgrading the application.
21.2.3 Upgrade the Hex File of an Application through the Console Interface
This chapter discusses how you can use your Maipu router’s network test tools to diagnose problems with the system.
Notes:
You can stop the ping procedure by pressing Ctrl+Shift+6 on the keyboard at the same time.
After the ping command has been executed, you will see the following onscreen output:
! shows a successful action, while . shows a failed action.
If ping worked, you will statistical information about the number of sent/received data packets, the percentage of data
packets that responded and the minimum, average or maximum response time values.
After you execute the ping <CR> command in privileged user mode, you can input optional parameters. The following two
examples explain these parameters and their meanings.
Example 1: Here, the command ping doesn’t have any extended options:
router#ping
Option Task
Output:
Example 2: After you choose the extended command options, you can set such options as source route, record timestamp
and display detailed information, etc.:
router#ping
Option Task
Target IP address: 128.255.255.1
Repeat count [5]: 1930
Data packet size [76]: 1000
Timeout in seconds [2]: 1
Extended commands [no]: y
Source address or interface:
128.255.255.223
Type of service [0]: 1
Set DF bit in IP header? [no]: y Decides whether or not the IP layer will permit an ICMP data packet to
be segmented.
Validate reply data? [no]: y Decides whether or not the received ICMP data packet should be
examined.
Data pattern [abcd]: asdf Appoints ICMP data regarding requested data packets.
Loose, Strict, Record, Timestamp, Appoints loose/strict source route, record route and timestamp.
Verbose[none]: L
Source route: 128.255.255.223
128.255.255.1
Loose, Strict, Record, Timestamp,
Verbose[LV]: r
Number of hops [6]: 3 Appoints the hops number.
Loose, Strict, Record, Timestamp, Number of hops [2]: 2
Verbose[LVR]: t
Loose, Strict, Record, Timestamp,
Verbose[LVRT]:v
Loose, Strict, Record, Timestamp,
Verbose[LRT]:
Sweep range of sizes [no]: y Decides whether or not the ICMP size scope requesting the data packet
should be appointed.
Sweep min size [74]: Minimum
Sweep max size [65530]: 2000 Maximum
Sweep interval [1]: 10 Shows the increasing interval between two adjacent ICMP data packets
Output:
Press key (ctrl + shift + 6) interrupt it.
Sending 1930, [74..2000]-byte ICMP Echos to 128.255.255.1 , timeout is 1 seconds:
Packet has IP options: Total option bytes = 40 .
Loose source route: 128.255.255.223 128.255.255.1
Record route number : 3
Record timestamp number : 2
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!........
Success rate is 64% (1235/1930). Round-trip min/avg/max = 0/12/1000 ms.
22.1.2 Traceroute
The traceroute command is used to test gateways that the data packet has passed through en route to its destination. Its
main function is to test the network connection for dropped connections.
Traceroute shows records the source address of each ICMP TTL overtime message. It will show you the path of the
packet passing from the source to the destination.
You would operate Traceroute when you’ve sent a packet with a TTL of 1, yet received an ICMP error data packet message
indicating the packet can’t be sent, since TTL=0. (If the packet is sent again when the TTL is 2, the second hop router will
similarly send back an ICMP error data packet message, because TTL is 0 when the packet passes through the second
router.) This kind of procedure continues until the packet arrives at the destination.
Traceroute can run in both common user and privileged user modes:
Note:
You can stop the traceroute procedure by pressing Ctrl+Shift+6 on the keyboard at the same time.
After the command has been executed, you will see the following output:
The sent ICMP data packet information (TTL value, IP header, etc.)
A list of all the routers through which the ICMP data packet has passed through (ie. interface address, the average round
trip time or ICMP data packet error.
After you execute traceroute<CR> in privileged user mode, you can input optional parameters. The following two
examples explain the parameters and their meanings.
Example 1: Here, traceroute doesn’t have any extended options – just basic optional parameters:
MP2600#traceroute
Option Task
Output:
Type escape sequence to abort.
Tracing the route to 192.168.8.254 , min ttl = 1, max ttl = 30 .
1 2.1.1.1 16 ms * 33 ms * 16 ms *
2 192.168.8.254 16 ms * 33 ms * 16 ms *
Example 2: After you pick the extended command options, you can set some options such as the source route, record time
stamp and detailed information display:
router#traceroute
Option Task
Output:
Type escape sequence to abort.
Tracing the route to 192.168.8.254 , min ttl = 1, max ttl = 30 .
Packet has IP options: Total option bytes = 40 .
Loose source route: 128.255.255.1
Record timestamp number : 7
1 16 ms 0 ms 16 ms
2 0 ms 0 ms 16 ms
3 !S !S !S
Note: The Traceroute command shows error messages with the ICMP data packet’s help. Besides that, the command can
usually display the average round trip time.
Traceroute data can be expressed in the form of one of the following prompts:
!N: unreachable network
!H: unreachable host
!S: unreachable source route
!A: prohibiting access (ie. prohibited network access, prohibited host access and prohibited management access)
!F: unreachable data packet that needs to be fragmented
?: unknown data packet
22.1.3 Netstat
The netstat command can be used only in privileged user mode to display system tables (ie. the host table, the route table,
the ARP table and the multicast table), the interface status/configuration, protocol statistics and buffer information. These
optional command parameters are as follows:
router#netstat ?
Command Description Remark
-a Displays the system’s interior ARP table
-e Examines the status code This is followed with the hex format status code
-g Displays the interior system’s multi-
broadcast table
-h Displays the system’s host table
-I Displays the router’s interface status
-m Displays data buffers in the network stack.
-n Displays system buffers in the network
stack.
-p Displays special statistics Supports five protocols: IGMP, ICMP, IP, TCP
and UDP.
-r Displays routing table data
-s Displays IP protocol summary statistic
information (for all protocols)
<CR> Displays TCP and UDP port and protocol
connections
22.1.4 Show
In privileged user mode, the show command can be used to:
Display the system clock
Display system equipment and interfaces
Display system statistic information
Display system start-up parameters
Display system tasks
Display system stacks
Make sure that the PC is connected with the router’s Ethernet port correctly.
If a Hub or LAN Switch is used to connect to the Ethernet, make sure the PC is connected with the Ethernet port of the router
correctly. The LED indicator on the Hub or LAN Switch will indicate if it is.
You can execute the ping command to test the link from the PC to the Ethernet’s port. When the hardware is connected
incorrectly, there will be no response or no change to the data packet input/output information when the PC pings the router.
Use either of the two following testing procedures to ping the router: (Note: 128.255.255.1 refers to the router’s Ethernet
port IP address.)
In DOS shell:
c:>ping 128.255.255.1
Pinging 128.255.255.1 with 32 bytes of data
Request timed out.
Request timed out.
Request timed out.
Make sure whether the PC’s configured IP addresses Ethernet port is set correctly. The network addresses must be the
same – only the host addresses can be different. If these conditions are met and you’re still getting no response from the
router, then the Ethernet port has been configured incorrectly.
Locate the failure.
The Ethernet interface can support two types of IP protocol: Ethernet_II and Ethernet_SNAP. Maipu routers can receive
these different IP packet formats simultaneously. However, the end user must appoint the IP packet’s format. Please
ensure that the sent IP packet’s format is similar to the other equipment being used by the Ethernet protocol.
The Ethernet router ports can support two speeds: 10 and 100Mbps. It can also support two kinds of working modes: half
duplex and full duplex. These working modes and transmission rates can be easily fixed in the system through automatic
negotiation.
After we know that the Ethernet port has been excluded as a possible problem, the router’s problem might be located in the
WAN port. Follow these steps to determine the problem:
Your Maipu router supports many kinds of WAN interface cables – V24, V35 and so on. The WAN interface type should
be checked against these cables, and you should ensure the WAN interface is running in the proper
synchronous/asynchronous mode. If necessary, reconfigure the router’s synchronous/asynchronous serial interface.
If your interface runs in asynchronous mode, then examine whether it’s running at the correct speed. In asynchronous
mode, the WAN serial port will support a very broad scope of data transmission speeds. The lowest speed is 1,200 bps and
the highest is 115,200 bps.
The WAN interface can also run in two synchronous modes: DTE and DCE. If it runs in DCE mode, examine whether the
clock rate and the clock mode provided by the router are set correctly. If it works in DTE mode, then check the clock
provided by DSU/CSU.
When the hardware or connection parameters are set incorrectly, the PC won’t respond or won’t show packets moving
through the system when tested by the ping function.
The router’s WAN interface supports many protocols, such as HDSL, X.25, FR, SLIP, PPP and CSLIP. The WAN routers on
both sides of the communication won‘t talk with each other until the same protocols have been set.
If you use Point-to-Point Protocol (PPP) and have adopted PAP or CHAP as the authentication protocol, please ensure
whether the two password configurations are consistent.
If you use the modem in asynchronous mode, please ensure whether the modem has been set correctly.
If the above configurations are incorrect, the interface won’t be able to connect with the protocols, event though the number
of output/input data packets on your system may appear to have increased.
If the link layer protocol is set to PPP in asynchronous dial-up mode, ensure whether the two ends of your dialer maps are set
correctly:
dialer map ip ipAddress telephoneNumb
The ipAddress command refers to the opposite terminal’s IP address and the telephoneNumber is the phone number
connected to this peer.
Routers on both sides of WAN must ensure that the network IP addresses are the same. If the IP address is set incorrectly,
the IP data packet route many have been sent to a wrong destination. When the WAN interface adopts the IP unnumbered
mode to borrow the IP address of the Ethernet interface, faults can occur much more easily.
Examine the route. MP routers presently support many routing methods, such as static routing, RIP v1/v2, OSPF, IRMP
dynamic routing and Dial-on-Demand Routing, etc. The router transmits a data packet in terms of its route information.
A data packet can be transmitted unsuccessfully because the route is incorrectly configured. Sometimes, the routers will
connect successfully with the hosts or other routers, but, sometimes, will disconnect to other network segment equipment.
In this case, if a static route has been adopted, you must manually set the route for the unreachable network segment.
However, if the router has adopted a RIP, OSPF and IRMP dynamic route, the router must configure the route protocols
correctly in order for the data to be successfully transmitted and for the local routing table to be updated.
Chapter 23 Discription Of the Interface Cable Signals
23.1 Ethernet Interface Cable (twisted-pair wire interface RJ45)
Pin 1 and Pin 2 are the sending ends, and Pin 3 and Pin 6 are the receiving ends. Like the interface of a PC Ethernet
Adapter , they can be connected to a HUB directly.
Table 4-1 the general wire list of the V.24/V.35 interface cable
2.0 WARRANTY:
Dax provides this extensive warranty to all QDP customers in order to establish
outstanding quality service to all Dax customers and give them a high return on the
investment in Dax products.
4.0 UNITS THAT ARE NOT QUALIFIED FOR THREE YEARS CARRY IN
WARRANTY:
The following Dax Units are not qualified for 3 years carry in warranty since
they only carry one year warranty:
a. Dax Internal modems
b. Dax Power supplies
9.0 JURISDICTION :
Any dispute shall be subject to exclusive jurisdiction of the courts in
Chennai.
Service Centre
New No. 21(Old No.11), II Street,
R.K. Nagar, Mandaveli, Chennai – 28.
Ph. No.: 2462 0217 / 2462 0218
E-MAIL: service@daxnetworks.com
Contact: Manager – IRA
Co-ordinator – Service Centre
Please refer our website www.daxnetworks.com for the current updated address and
contact phone numbers.
WARRANTY CARD FOR DXMP ROUTER
This DXMP ROUTER has been manufactured under the most stringent quality standards by an ISO
9001 Certified Company and is guaranteed to perform. This DXMP ROUTER carry a comprehensive 3-
year warranty. In the unlikely event of the product malfunctioning due to any manufacturing defect, you
can get it exchanged instantly as per our IRA (Instant Replacement Anywhere) policy guidelines within
one year of purchase from date of sale by Dax or get it repaired / replaced at free of charge with in the
Carry-in warranty period. For replacement or repair, please walk-in with the product to your vendor or
any Dax authorized distributor. Just make sure that you produce this card and the serial number of your
product along with proof of date of purchase when you require replacement / repair. For any additional
support, please contact the Dax Technical Support Department at
Note: Please refer our website for IRA / Support Centres & Dax Authorized Distributors.