Cisco路由器的基本配置 中国网管学院
随着IT业的飞速发展,Cisco路由器被广泛应用于各行各业,本文将从基础配置入手,简单先容一下Cisco路由器的配置方法。 一、配置以太网端口 # conf t 从终端配置路由器(Cisco的各种命令均可以简写,只要不与其他命令重复即可,如configure terminal可以写成conf t)。 # int e0 指定E0口。 # ip addr ABCD ***X ABCD为以太网地址,***X为子网掩码。 # ip addr ABCD ***X secondary E0口可同时支持多个地址类型,只要各个地址类型不在同一个网段即可。 # no shutdown 激活E0口。 # exit 二、配置串口(SERIAL) 1. X.25的配置 # conf t # int S0 # ip addr ABCD ***X # ip addr ABCD ***X secondary S0口同样支持多个地址类型。 # encap X25 封装X.25协议。 # x25 addr ABCD ABCD为S0的X.25端口地址,由电信部分提供。 # x25 map ip ABCD ***X br 映射X.25地址,ABCD为对方路由器(如S0)的IP地址,***X为对方路由器 (如S0)的X.25端口地址。 # x25 htc X 最高双向通道数X的取值范围为1~4095,要根据邮电局实际提供的数字配置。 # x25 nvc X 配置永久虚电路数。X不可超过邮电局实际提供的数值,否则将影响数据的正常传输。 # no shutdown # exit 2.帧中继的配置 # conf t # int s0 # ip addr ABCD ***X # encap frante_relay # no nrzi_encoding NRZI=NO。 # frame_relay lmi_type q933a LMI使用Q933A标准。LMI(Local management Inte***ce)有3种,分别是ANSI的T1.617、CCITT的Q933A和Cisco特有的标准。 # frame-relay intf-typ ABC ABC为帧中继设备类型,它们分别是DTE设备、DCE交换机或NNI(网络接点接口)支持设备。 # frame_relay inte***ce_dlci 110 br 配置DLCI(数据链路连接标识符)。 # frame-relay map ip ABCD ***X broadcast 建立帧中继映射。ABCD为对方IP地址,***X为本地DLCI号,broadcast答应广播向前转发或更新路由。 # no shutdown # exit 3.帧中继子接口的配置 # conf t # int s0.1 point-to-point 对应S0的子接口1,点对点方式。 # ip addr ABCD ***X ABCD为子口1的IP地址,***X为子网掩码。 # frame-relay inte***ce-dlci 100 br< 4.配置拨号备份 (1)配置备份主口 # conf t # int s0 S0为主口。 # backup int asy 1 A1口为备份口。 # backup delay 0 1 延时为1秒。 (2)配置虚拟接口 # conf t # ip addr ABCD ***X ABCD为虚拟接口的IP地址,***X为子网掩码。 # encap ppp # dialer in-band 激活随叫随拨功能。 # dialer idle-timeout 7200 # dialer map ip ABCD modem-script call broadcast 1234567 br 映射对应的拨号口。ABCD为对方拨号口的ip地址,1234567为对应的电话号码。 # dialer_group 1 定义拨号组成员。 (3)配置防火墙 # dialer_list 1 pro ip permit 答应ip协议通过。 (4)配置连接口令 # user name ABCD pass ***X ABCD为对方主机名,***X为连接口令。 (5)配置拨号字符串 # conf t # chat-script call "ABORT BUSY ABORT ERROR" atdt 1234567 TIMEOUT 45 "CONNECT" 1234567为对方电话号码。 (6)配置拨号连接密码 # conf t # username ROU1 pass ***X ROU1为对方路由器名,***X为连接密码。 (7)配置线路 # conft # line aux 0 # modem inout MODEM双向传输。 # modem autoconfigure discovery 自动配置MODEM的参数。 # transport input all # speed 51200 MODEM的收发速率为51200bps。 # exit 5.配置同步/异步口 # conf t # int s2 # ph asyn 配置S2为异步口。 # ph sync 配置S2为同步口。 三、配置路由 1/2 12下一页尾页
页:
[1]