关于路由器CPU利用率过高的解决办法
发布时间:2013-07-19 17:31:09 作者:佚名
我要评论
对于路由器CPU利用率过高有什么好的解决办法呢?很大一部分朋友都不知道如何解决这个问题。下面小编就为大家介绍一下解决这个问题的方法吧,需要的朋友可以过来参考下
第一步,show process cpu 如显示IP input process is using a lot of CPU resources,检查以下情况:
一、Fast switching
在大流量的外出接口上是否被disabled.可以用 show interfaces switching 命令察看接口流量.然后在接口上重新 Re-enable fast switching .记住 fast switching是配置在output 接口.
二、Fast switching on the same interface是否被disabled. 如一个接口配有多个网段(secondary addresses )并且在这些网段间流量很大时 路由器工作在process-switches方式 .这种情况下要在接口上enable ip route-cache same-interface.
三、不能被fast switched的包有:switching cache没有entry的包、目的地是路由器的包、需要协议转换的包、做了policy routing的包、X.25 encapsulation的包、Multilink PPP、压缩和加密的包目的地是router的包.
举例:1.路由更新信息(取决于路由协议)过快的更新值显示网络不稳定并增加了CPU utilization. 可以用show ip route检查路由表
2.其它人登录运行命令导致大量log输出
3.Spoof 攻击.用show ip traffic 命令确认,可发现大量到本地的包.
第二步,用 show interfaces 和show interfaces switching命令识别大量包进出的端口;一旦你确认进入端口后,打开 ip accounting on the outgoing interface看其特征.如果是攻击,源地址会不断变化但是目的地址不变.可以用access list暂时解决此类问题 (最好在接近攻击源的设备上配置), 最终解决办法是停止攻击源。
一.需policy routing的包.在 Cisco IOS version 11.3以前, policy-routed packets不能被 fast switched. IOS version 11.3 以后允许 policy-routed packets to be fast switched.使用接口命令ip route-cache policy。
二.通过X.25封装的包,因为有 flow control on the second Open System Interconnection (OSI) layer.7.Compressed traffic.如没有Compression Service Adapter (CSA) in the router, compressed packets must be process-switched.8.Encrypted traffic. 如没有 Encryption Service Adapter (ESA) in the router, encrypted packets must be process-switched.
三.大量的User Datagram Protocol (UDP) 流量. 可以用解决 spoof attack的步骤解决.
四.大量组播流穿越路由器。可以enable fast switching of multicast packets using the ip mroute-cache interface configuration command (fast switching of multicast packets is off by default).
五.大量广播包。 Check the number of broadcast packets in the show interfaces command output.
六.路由器被 over-used 不能处理amount of traffic, 可以用 load among other routers 或者 考虑另购买high-end router.
七.路由器配置了IP NAT (Network Address Translation)并且有很多 DNS (Domain Name System) 包穿越 router. UDP or TCP packets with source and/or destination port 53 (DNS) are always punted to process level by NAT.
无论是什么原因导致high CPU utilization in the IP Input process, 都可以用 debugging IP packets察看.因为 CPU utilization已经较高, debugging产生的许多信息只能通过 logging buffered而不能 Logging to a console。 debugging过程不要超过 3-5秒。如果发现可疑的源可以断掉其设备的连接或者用ACL过滤到目的地的包。
一、Fast switching
在大流量的外出接口上是否被disabled.可以用 show interfaces switching 命令察看接口流量.然后在接口上重新 Re-enable fast switching .记住 fast switching是配置在output 接口.
二、Fast switching on the same interface是否被disabled. 如一个接口配有多个网段(secondary addresses )并且在这些网段间流量很大时 路由器工作在process-switches方式 .这种情况下要在接口上enable ip route-cache same-interface.
三、不能被fast switched的包有:switching cache没有entry的包、目的地是路由器的包、需要协议转换的包、做了policy routing的包、X.25 encapsulation的包、Multilink PPP、压缩和加密的包目的地是router的包.
举例:1.路由更新信息(取决于路由协议)过快的更新值显示网络不稳定并增加了CPU utilization. 可以用show ip route检查路由表
2.其它人登录运行命令导致大量log输出
3.Spoof 攻击.用show ip traffic 命令确认,可发现大量到本地的包.
第二步,用 show interfaces 和show interfaces switching命令识别大量包进出的端口;一旦你确认进入端口后,打开 ip accounting on the outgoing interface看其特征.如果是攻击,源地址会不断变化但是目的地址不变.可以用access list暂时解决此类问题 (最好在接近攻击源的设备上配置), 最终解决办法是停止攻击源。
一.需policy routing的包.在 Cisco IOS version 11.3以前, policy-routed packets不能被 fast switched. IOS version 11.3 以后允许 policy-routed packets to be fast switched.使用接口命令ip route-cache policy。
二.通过X.25封装的包,因为有 flow control on the second Open System Interconnection (OSI) layer.7.Compressed traffic.如没有Compression Service Adapter (CSA) in the router, compressed packets must be process-switched.8.Encrypted traffic. 如没有 Encryption Service Adapter (ESA) in the router, encrypted packets must be process-switched.
三.大量的User Datagram Protocol (UDP) 流量. 可以用解决 spoof attack的步骤解决.
四.大量组播流穿越路由器。可以enable fast switching of multicast packets using the ip mroute-cache interface configuration command (fast switching of multicast packets is off by default).
五.大量广播包。 Check the number of broadcast packets in the show interfaces command output.
六.路由器被 over-used 不能处理amount of traffic, 可以用 load among other routers 或者 考虑另购买high-end router.
七.路由器配置了IP NAT (Network Address Translation)并且有很多 DNS (Domain Name System) 包穿越 router. UDP or TCP packets with source and/or destination port 53 (DNS) are always punted to process level by NAT.
无论是什么原因导致high CPU utilization in the IP Input process, 都可以用 debugging IP packets察看.因为 CPU utilization已经较高, debugging产生的许多信息只能通过 logging buffered而不能 Logging to a console。 debugging过程不要超过 3-5秒。如果发现可疑的源可以断掉其设备的连接或者用ACL过滤到目的地的包。
相关文章

网络延迟几分钟就断? 路由器刚接核心交换机正常几分钟后无法上网解决办
最近一位小伙伴被信息化项目里的网络怪象逼到破防:核心交换机上联路由器后,前几分钟一切正常,随后延迟飙升,最后直接断网,下面我们就来看看原因分析和解决办法2026-04-13
双万兆+四个2.5G口BE7200无线路由器! 普联TPLINK 7DR7299拆机测评
今天我们要拆机的TP-LINK“7DR7299”BE7200双万兆路由器标价999元,没走“八爪鱼”电竞风,而是给了一枚黑银配色的小方盒,放在玄关、电视柜都不突兀2026-04-10
普联BE7200万兆路由器,搭载双万兆接口与WiFi7技术,高性能硬件配置提升大户型家庭网络覆盖稳定性,详细配置请看下文介绍2026-03-16
这五个开关是现代Wi-Fi 6和Wi-Fi 7路由器中关键的性能增强功能,它们分别从信号定向、频谱效率、多设备并发、抗干扰和省电调度等维度提升网络体验2026-02-25
679元万兆光口+满血2.5G全家桶! 简析中兴BE7200 MAX路由器是否值得购买
当千兆宽带尚未普及,中兴已经将万兆路由器价格拉至679元,这不是一场简单的价格战,而是对未来的大胆预判与市场规则的重新定义2026-02-06
中兴问天BE7200Pro+路由器新旧两个版本有什么区别? 两版拆机对比
中兴问天BE7200Pro+路由器新版本和旧版本呢差别在换了FEM芯片,很多朋友想知道有多大差别,详细请看下文介绍2026-02-05
满血堆料Wifi7路由器! 中兴问天BE7200MAX拆机评测
问天BE7200 MAX的一大特点就是国产自主,主控芯片查了下好像是中兴自研 ZX279133(8核64线程 NPU),搭配1GB内存和256MB闪存,下面我们就来看看拆机测评2026-02-05
TP-LINK TL-7AP3622HI无线AP值得购买吗? TL-7AP3622HI拆机
TL-7AP3622HI是一款BE3600双频Wi-Fi 7无线面板式AP,全新双2.5G BE3600面板AP,前后网口均支持2.5G,下面我们就来看看拆解测评2026-02-05
与运行时机箱发热的原理相似,路由器作为一台“小型专用电脑”,在其工作过程中必然会产生一定的热量,然而,是否正常发热并不仅仅取决于发热本身,更关键的是要关注发热的2026-01-14
诺基亚贝尔XG-040G-MD光猫均具备一个2.5G网口,同时配备USB3.0和USB2.0接口,但遗憾的是,它并不具备电话口和WIFI功能,下面我们就来看看详细侧测评2025-12-15












最新评论