新客网WWW.XKER.COM:致力做中国最专业的网络学院!
学院: 操作系统 - 网络应用 - 服务器 - 网络安全 - 工具软件 - 办公软件 - Web开发 - 数据库 - 网页设计 - 图形图像 - 媒体动画 - 硬件学堂 - 存储频道 - QQ专区
您的位置:首页 > 网络学院 > 服务器 > 服务器相关 > 正文:思科C3550配置DHCP服务器实例

思科C3550配置DHCP服务器实例

新客网 XKER.COM 2008-01-16 来源: 收藏本文
  第五步:配置3550作为DHCP服务器

  /*VLAN 2可用地址池和相应参数的配置,有几个VLAN要设几个地址池*/

  Switch(Config)Ip Dhcp Pool Test01

  /*设置可分配的子网*/

  Switch(Config-pool)Network 192.168.2.0 255.255.255.0

  /*设置DNS服务器*/

  Switch(Config-pool)Dns-server 192.168.2.10

  /*设置该子网的网关*/

  Switch(Config-pool)Default-router 192.168.2.1

  /*配置VLAN 3所用的地址池和相应参数*/

  Switch(Config)Ip Dhcp Pool Test02

  Switch(Config-pool)Network 192.168.3.0 255.255.255.0

  Switch(Config-pool)Dns-server 192.168.2.10

  Switch(Config-pool)Default-router 192.168.3.1

  /*配置VLAN 4所用的地址池和相应参数*/

  Switch(Config)Ip Dhcp Pool Test03

  Switch(Config-pool)Network 192.168.4.0 255.255.255.0

  Switch(Config-pool)Dns-server 192.168.2.10

  Switch(Config-pool)Default-router 192.168.4.1

  第六步:设置DHCP保留不分配的地址

  Switch(Config)Ip Dhcp Excluded-address 192.168.2.2 192.168.2.10

  Switch(Config)Ip Dhcp Excluded-address 192.168.3.2 192.168.3.10

  Switch(Config)Ip Dhcp Excluded-address 192.168.4.2 192.168.4.10

  第七步:启用路由

  /*路由启用后,各VLAN间主机可互相访问*/

  Switch(Config)Ip Routing

  第八步:配置访问控制列表

  Switch(Config)access-list 103 permit ip 192.168.2.0 0.0.0.255 192.168.3.0 0.0.0.255

  Switch(Config)access-list 103 permit ip 192.168.3.0 0.0.0.255 192.168.2.0 0.0.0.255

  Switch(Config)access-list 103 permit udp any any eq bootpc

  Switch(Config)access-list 103 permit udp any any eq tftp

  Switch(Config)access-list 103 permit udp any eq bootpc any

  Switch(Config)access-list 103 permit udp any eq tftp any

  Switch(Config)access-list 104 permit ip 192.168.2.0 0.0.0.255 192.168.4.0 0.0.0.255

  Switch(Config)access-list 104 permit ip 192.168.4.0 0.0.0.255 192.168.2.0 0.0.0.255

  Switch(Config)access-list 104 permit udp any eq tftp any

  Switch(Config)access-list 104 permit udp any eq bootpc any

  Switch(Config)access-list 104 permit udp any eq bootpc any

  Switch(Config)access-list 104 permit udp any eq tftp any

  第九步:应用访问控制列表

  /*将访问控制列表应用到VLAN 3和VLAN 4,VLAN 2不需要*/

  Switch(Config)Int Vlan 3

  Switch(Config-vlan)ip access-group 103 out

  Switch(Config-vlan)Int Vlan 4

  Switch(Config-vlan)ip access-group 104 out

  第十步:结束并保存配置

  Switch(Config-vlan)End

  Switch#Copy Run Start
共2页: 上一页 [1] [2] 下一页
收藏】 【评论】 【推荐】 【投稿】 【打印】 【关闭
发表评论
要记得去论坛讨论,点击注册新会员匿名评论
评论内容:不能超过250字,需审核后才会公布,请自觉遵守互联网相关政策法规。
阅读排行
随机推荐
实用信息推荐