CISCO路由上的一些简单配置命令

no ip domain-lookup          不进行域名解析
line console 0              进入设备线接口
logging synchronous         不进行日志同步
no exec-timeout             不设定超时时间(设定时间exec-timeout 50)
default interface s2/0      清除端口配置信息
 
 
vlan间路由
1.在交换机上划分VLAN
在特权模式下  vlan database
创建vlan       vlan 10  name jishu
选择端口     interface fastEthernet0/2
选择模式      swithport mode access
划分到一个vlan中   switchport access vlan 10
开启端口            no shutdown
2.路由与交换机相连部分要创建干道(在交换机上)
选择端口    interface fastEthernet0/1
            switchport  trunk encapsulation dot1q
            switch mode trunk
            no shutdown
3.配置
定义子接口: interface f0/0.10
             description to vlan 10
             encapsulation dot1q 10
             ip address 192.168.3.1(要和所在vlan中一个网段) 255.255.255.0
             exit
三层交换情况下(交换机具有路由功能)
在全局模式下: interface vlan 10
               ip address 192.168.2.234 255.255.255.0
               exit
               interface vlan 20
               ip address 192.168.3.234 255.255.255.0
               exit
ospf协议的配置
router ospf 2 
network 192.168.2.0 0.0.3.255 area 1(1代表区域)
router-id 1.1.1.1  给路由配id
clear ip ospf process  清楚进程
虚拟电路:
area 2(所要穿越的区域) virtual-link 1.1.1.1(对点路由的id号)
配虚拟电路双方都需要配置.
 
 
ppp(pap ,chap )
pap:
(r1)   username jiabin password jiabin
       int s2/0
       ip add 192.168.12.1 255.255.255.0
       clock rate 64000
       no shutdown
       encapsulation ppp
       ppp authentication pap
       exit
(r2)  
       int s2/0
       ip add 192.168.12.2 255.255.255.0
       clock rate 64000
       no shutdown
       encapsulation ppp
       ppp pap sent-username jiabin password jiabin(与上面用户名密码相同,采用的是明文)
       exit
chap:
(r1)
        username r1 password jiabin
       int s2/0
       ip add 192.168.12.1 255.255.255.0
       clock rate 64000
       no shutdown
       encapsulation ppp
       ppp authentication chap
       exit 
(r2)  
       username r2 password jiabin
       int s2/0
       ip add 192.168.12.2 255.255.255.0
       clock rate 64000
       no shutdown
       encapsulation ppp
       ppp authentication chap
       exit 

你可能感兴趣的:(职场,休闲,路由配置命令)