1.用Qos限制上传速度
步骤一、定义希望限速的主机范围
S3760>en
S3760#conf
S3760(config)#access-list 101 permit ip host 192.168.1.101 any
----定义要限速的IP
S3760(config)#access-list 102 permit ip host 192.168.1.102 any
步骤二、创建规则类,应用之前定义的主机范围
S3760(config)#class-map xiansu101 ----创建class-map,名字为xiansu101
S3760(config-cmap)#match access-group 101 ----匹配IP地址
S3760(config-cmap)#exit
S3760(config)#class-map xiansu102 ----创建class-map,名字为xiansu102
S3760(config-cmap)#match access-group 102 ----匹配IP地址
S3760(config-cmap)#exit
步骤三、创建策略类:应用之前定义的规则,配置限速大小
S3760(config)#policy-map xiansu ----创建policy-map,名字为xiansu
S3760(config-pmap)#class xiansu101 ----符合class xiansu101
S3760(config-pmap-c)#police 8000 512 exceed-action drop
----限速值为8000Kbit(1MB)
S3760(config-pmap)#class xiansu102 ----符合class xiansu102
S3760(config-pmap-c)#police 4000 512 exceed-action drop
----限速值为4000Kbit
S3760(config-pmap-c)#end
步骤四、进入接口,应用之前定义的策略
S3760#conf
S3760(config)#int fa 0/10 ----进入接口
S3760(config-if)#service-policy input xiansu ---将该限速策略应用在这个接口上
2.用rate-limit output限制下载速度.
如何在接口上删除:
Switch(config)# interface G 0/2
Switch(config-if)#no switchport port-security mac-address 00d0.f800.073c ip-address 192.168.12.202 //删除192.168.12.202的绑定
绑定的命令:
Switch(config)# interface G 0/2
Switch(config-if)#switchport port-security mac-address 00d0.f800.023c ip-address 192.168.12.202
启用端口安全
switchport port-security maxmum ??
设置端口上联最大地址数
switchport port-security violation protect //s3750
如何在接口上删除:
Switch(config)# interface G 0/2
Switch(config-if)#no switchport port-security mac-address 00d0.f800.073c ip-address 192.168.12.202 //删除192.168.12.202的绑定
绑定的命令:
Switch(config)# interface G 0/2
Switch(config-if)#switchport port-security mac-address 00d0.f800.023c ip-address 192.168.12.202
2026交换机内
sh interface static 显示端口状态
sh mac-address interface fast0/?? 显示端口获取的MAC 地址
sh mac dy 查看每个端口的MAC 地址,不用上联口内的MAC地址
sh interface static 显示端口状态
sh mac-address interface fast0/?? 显示端口获取的MAC 地址
sh mac dy 查看每个端口的MAC 地址,不用上联口内的MAC地址
在S7604中用sh arp 查看MAC地址对应的IP
inter fast0/??
switchport port-security //s3750
inter fast0/??
switchport port-security //s3750
启用端口安全
switchport port-security maxmum ??
设置端口上联最大地址数
switchport port-security violation protect //s3750
保护端口,当上联地址数满或不同时丢弃
switchport port-security mac-address h.h.h.h //s3750 ip a.b.c.d
switchport port-security mac-address h.h.h.h //s3750 ip a.b.c.d
设置端口连接的电脑MAC地址
exit
arp 192.168.?.? h.h.h.h 用ARP绑定MAC和IP地址
exit
arp 192.168.?.? h.h.h.h 用ARP绑定MAC和IP地址
在3750交换机内创建不同的ACCESS-LIST
ip access-list extended 103
10 permit ip host 192.168.6.13 any 充许通过的IP地址
20 permit ip host 192.168.6.30 any
30 permit ip host 192.168.6.12 any
40 permit ip host 192.168.10.247 any 交换机管理VLAN的地址
50 deny ip any any 除了以上充许的IP外其它任意IP不能访问
ip access-list extended 103
10 permit ip host 192.168.6.13 any 充许通过的IP地址
20 permit ip host 192.168.6.30 any
30 permit ip host 192.168.6.12 any
40 permit ip host 192.168.10.247 any 交换机管理VLAN的地址
50 deny ip any any 除了以上充许的IP外其它任意IP不能访问
增加时进入访问列表中,先用no deny ip any any 然后再增加IP地址,
增加完后再把deny ip any any 加到列表最后
interface FastEthernet 0/3
switchport mode trunk
switchport trunk allowed vlan remove 5
ip access-group 103 in 在级联端口应用访问列表
description s3750-to-2026-3
www.juyuwangjia.com
增加完后再把deny ip any any 加到列表最后
interface FastEthernet 0/3
switchport mode trunk
switchport trunk allowed vlan remove 5
ip access-group 103 in 在级联端口应用访问列表
description s3750-to-2026-3
www.juyuwangjia.com
©著作权归作者所有:来自51CTO博客作者xuqinyu521的原创作品,如需转载,请注明出处,否则将追究法律责任
0
收藏
推荐专栏更多
猜你喜欢
我的友情链接
VRRP技术实现网络的由冗余和负载均衡
检测远程主机上的某个端口是否开启——telnet命令
为VMware ESXi主机添加本地存储的过程及注意事项-之3
如何在一台ESXi主机上搭建一整套VSAN集群的环境
zabbix3监控ESXI主机
在VM7虚拟机中使用主机打印机
虚拟机使用ESXi主机物理硬盘的办法
Java线程:线程的调度-休眠
我们不得不面对的中年职场危机
VMware Workstation下VMnet1等虚拟网卡与主机网卡之间的关系
职场终极密籍--记我的职业生涯
IPv6通讯原理(1) - 不能忽略的网卡启动过程
华为MSTP、VRRP与DHCP综合项目详解
PBR下一跳类型研究
VRRP实训案例配置
OSPF基本概念以及DR/BDR和虚连接OSPF特殊区域的实验操作
简单搭建OSPF,RIP,NSSA,外部路由汇总网络拓扑
OSPF路由重分发
OSPF协议的“地址汇总配置”及“虚链路配置”
扫一扫,领取大礼包
转载于:https://blog.51cto.com/xiaoyuzhijia/676304
Ctrl+Enter 发布
发布
取消