-
网络地址分配
部门
销售部
财务部
经理办公室
人事部
网管中心
端口号分配
设备名
Router0
端口
Gig4/0
Gig0/0
Gig0/1
F0/1
Multilayer switch0
F0/2
F0/3
F0/4
F0/6
Switch 2
Switch 3
Gig1/1
Gig2/1
Gig1/1
Gig2/1
Ip
地址
202.168.100.3
192.168.1.1
192.168.1.2
192.168.60.254
Vlan 50
192.168.70.254
Vlan 10
Vlan 20
Vlan 30
Vlan 40
Valn
号
10
20
30
40
50
Ip
地址
/
子网掩码
192.168.10.0/24
192.168.20.0/24
192.168.30.0/24
192.168.40.0/24
192.168.50.0/24
默认网关
192.168.10.254
192.168.20.254
192.168.30.254
192.168.40.254
192.168.50.254
Switch 0
Switch>enable
Switch#config
t
Enter configuration commands, one per
line.
End with CNTL/Z.
Switch(config)#enable password 123
Switch(config)#line con 0
Switch(config-line)#password 123
Switch(config-line)#login
Switch(config-line)#line vty 0 4
Switch(config-line)#password 123
Switch(config-line)#login
Switch(config-line)#exit
Switch(config)#int f0/4-5
^
% Invalid
input detected at '^' marker.
Switch(config)#int range
f0/4-5
Switch(config-if-
range)#switchport mode trunk
Command
rejected: An interface whose trunk encapsulation
is
Command rejected: An interface whose
trunk encapsulation is
Switch(config-
if-range)#exit
Switch(config)#vlan 20
Switch(config-vlan)#name XSB
Switch(config-vlan)#exit
Switch(config)#vlan 30
Switch(config-vlan)#name CWB
Switch(config-vlan)#exit
Switch(config)#no vlan 20
Switch(config)#no vlan 30
Switch(config)#vlan 20
Switch(config-vlan)#exit
Switch(config)#no vlan 20
Switch(config)#vlan 10
Switch(config-vlan)#name XSB
Switch(config-vlan)#exit
Switch(config)#vlan 20
Switch(config-vlan)#name CWB
Switch(config-vlan)#exit
Switch(config)#vlan 30
Switch(config-vlan)#name manage
Switch(config-vlan)#exit
Switch(config)#vlan 40
Switch(config-vlan)#name RSB
Switch(config-vlan)#exit
Switch(config)#vlan 50
Switch(config-vlan)#name Admin
Switch(config-vlan)#exit
Switch(config)#int vlan 10
%LINK-5-CHANGED: Interface Vlan10,
changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on
Interface Vlan10, changed state to up
Switch(config-if)#ip address
192.168.10.254 255.255.255.0
Switch(config-if)#no shutdown
Switch(config-if)#exit
Switch(config)#int vlan 20
%LINK-5-CHANGED: Interface Vlan20,
changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on
Interface Vlan20, changed state to up
Switch(config-if)#ip add 192.168.20.254
255.255.255.0
Switch(config-if)#no
shutdown
Switch(config-if)#exit
Switch(config)#int vlan 30
%LINK-5-CHANGED: Interface Vlan30,
changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on
Interface Vlan30, changed state to up
Switch(config-if)#ip add 192.168.30.254
255.255.255.0
Switch(config-if)#no
shutdown
Switch(config-if)#exit
Switch(config)#int vlan 40
%LINK-5-CHANGED: Interface Vlan40,
changed state to up
Switch(config-if)#
%LINEPROTO-5-UPDOWN: Line protocol on
Interface Vlan40, changed state to up
Switch(config-if)#ip add 192.168.40.254
255.255.255.0
Switch(config-if)#no
shutdown
Switch(config-if)#exit
Switch(config)#int vlan 50
%LINK-5-CHANGED: Interface Vlan50,
changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on
Interface Vlan50, changed state to up
Switch(config-if)#ip add 192.168.50.254
255.255.255.0
Switch(config-if)#no
shutdown
Switch(config-if)#exit
Switch(config)#
Switch(config)#router ospf 10
Switch(config-router)#network
192.168.10.0 0.0.0.255 area 0
Switch(config-router)#network
192.168.20.0 0.0.0.255 area 0
Switch(config-router)#network
192.168.30.0 0.0.0.255 area 0
Switch(config-router)#network
192.168.40.0 0.0.0.255 area 0
Switch(config-router)#network
192.168.50.0 0.0.0.255 area 0
Switch(config-router)#network
192.168.3.0 0.0.0.255 area 0
Switch(config-router)#network
192.168.60.0 0.0.0.255 area 0
Switch(config-router)#network
192.168.70.0 0.0.0.255 area 0
Switch(config-router)#exit
Switch(config)#int f0/2
Switch(config-if)#switchport
access vlan 50
Switch(config-if)#exit
Switch(config)#int f0/1
Switch(config-if)#no switchport
%LINEPROTO-5-UPDOWN: Line
protocol on Interface FastEthernet0/1, changed
state to down
%LINEPROTO-5-UPDOWN: Line protocol on
Interface FastEthernet0/1, changed state to up
Switch(config-if)#ip add 192.168.60.254
255.255.255.0
Switch(config-if)#no
shutdown
Switch(config-if)#exit
Switch(config)#int f0/3
Switch(config-if)#no switchport
%LINEPROTO-5-UPDOWN: Line
protocol on Interface FastEthernet0/3, changed
state to down
%LINEPROTO-5-UPDOWN: Line protocol on
Interface FastEthernet0/3, changed state to up
Switch(config-if)#ip add 192.168.70.254
255.255.255.0
Switch(config-if)#no
shutdown
Switch(config-if)#
Switch(config)#int Gig0/1
Switch(config-if)#no switchport
Switch(config-if)#ip add 192.168.1.2
255.255.255.0
Switch(config-if)#no
shutdown
Switch(config-if)#exit
Switch(config)#ip dhcp pool vlan10
Switch(dhcp-config)#network
192.168.10.0 255.255.255.0
Switch(dhcp-
config)#default-router 192.168.10.254
Switch(dhcp-config)#dns-server
202.168.100.5
Switch(dhcp-config)#exit
Switch(config)#ip dhcp pool vlan20
Switch(dhcp-config)#network
192.168.20.0 255.255.255.0
Switch(dhcp-
config)#default-router 192.168.20.254
Switch(dhcp-config)#dns-server
202.168.100.5
Switch(dhcp-config)#exit
Switch(config)#ip dhcp pool vlan30
Switch(dhcp-config)#network
192.168.30.0 255.255.255.0
Switch(dhcp-
config)#default-router 192.168.30.254
Switch(dhcp-config)#dns-server
202.168.100.5
Switch(dhcp-config)#exit
Switch(config)#ip dhcp pool vlan40
Switch(dhcp-config)#network
192.168.40.0 255.255.255.0
Switch(dhcp-
config)#default-router 192.168.40.254
Switch(dhcp-config)#dns-server
202.168.100.5
Switch(dhcp-config)#exit
Switch(config)#ip dhcp exculded-address
192.168.10.252
^
% Invalid input detected at '^' marker.
Switch(config)#ip dhcp excluded-address
192.168.10.252
Switch(config)#ip dhcp
excluded-address 192.168.10.253
Switch(config)#ip dhcp excluded-address
192.168.10.254
-
-
-
-
-
-
-
-
-
上一篇:我们的行业就是创意
下一篇:2017年度流行新词盘点