ホームページ >データベース >mysql チュートリアル >Cisco小型局域网配置
cisco2811主要 配置 如下: ! interface FastEthernet0/0 description $ETH-LAN$$ETH-SW-LAUNCH$$INTF-INFO-FE 0/0$ ip address 172.17.10.10 255.255.255.248 ip nat outside ip virtual-reassembly duplex auto speed 100 ! interface FastEthernet0/1 ip
cisco2811主要配置如下:
!
interface FastEthernet0/0
description $ETH-LAN$$ETH-SW-LAUNCH$$INTF-INFO-FE 0/0$
ip address 172.17.10.10 255.255.255.248
ip nat outside
ip virtual-reassembly
duplex auto
speed 100
!
interface FastEthernet0/1
ip address 172.18.1.1 255.255.255.252
ip nat inside
ip virtual-reassembly
duplex full
speed 100
!
router rip
version 2
network 172.17.0.0
network 172.18.0.0
neighbor 172.18.1.2
!
ip route 0.0.0.0 0.0.0.0 172.17.10.9
!
ip nat pool ippool1 172.17.10.10 172.17.10.10 netmask 255.255.255.248
ip nat inside source list 1 pool ippool1 overload
!
access-list 1 permit 172.18.10.0 0.0.0.255 //只允许vlan10用户访问外部网络
!
Cisco3560主要配置如下:
!
no aaa new-model
ip subnet-zero
ip routing //启用vlan路由
no ip domain-lookup
ip dhcp excluded-address 172.18.20.254
ip dhcp excluded-address 172.18.10.254
!
ip dhcp pool vlan20
import all
network 172.18.20.0 255.255.255.0
default-router 172.18.20.254
dns-server 58.193.192.1 58.193.192.2
domain-name njust.edu.cn
lease 6 23
!
ip dhcp pool vlan10
import all
network 172.18.10.0 255.255.255.0
default-router 172.18.10.254
dns-server 58.193.192.1 58.193.192.2
domain-name njust.edu.cn
lease 6 23
!
!
interface FastEthernet0/1
switchport access vlan 10
!
interface FastEthernet0/2
switchport access vlan 20
!
interface FastEthernet0/3
switchport access vlan 20
!
interface FastEthernet0/4
switchport access vlan 20
!
!
interface FastEthernet0/23
description trunk_link cisco2950_fe0/24
switchport trunk encapsulation dot1q
switchport mode trunk
!
interface FastEthernet0/24
description uplink cisco2811_fe0/1
switchport access vlan 100
speed 100
duplex full
!
!
interface Vlan1
ip address 1.0.0.1 255.255.255.0
!
interface Vlan10
ip address 172.18.10.254 255.255.255.0
!
interface Vlan20
ip address 172.18.20.254 255.255.255.0
!
interface Vlan100
ip address 172.18.1.2 255.255.255.252
!
router rip
version 2
network 1.0.0.0 //方便从路由器直接登录交换机
network 172.18.0.0
neighbor 172.18.1.1
!
ip classless
ip route 0.0.0.0 0.0.0.0 172.18.1.1
ip http server
!
Cisco2950主要配置如下:
!
interface FastEthernet0/1
switchport access vlan 10
!
interface FastEthernet0/2
switchport access vlan 10
!
interface FastEthernet0/3
switchport access vlan 20
!
interface FastEthernet0/4
switchport access vlan 20
!
!
interface FastEthernet0/24
switchport mode trunk
!
interface Vlan1
ip address 1.0.0.2 255.255.255.0
no ip route-cache
!
ip default-gateway 1.0.0.1 //添加默认网关
ip http server
!
Cisco3560 vtp 配置为server ,Cisco2950 vtp 配置为client,vtp domain name与password相同。因为Cisco2950 trunk端口不支持ISL封装,因此两端都要dot1q。
作者“小李飞刀”