当前位置:网站首页>关于出现大量close_wait状态的理解
关于出现大量close_wait状态的理解
2022-07-31 04:10:00 【滴水可藏海】
以web服务器产生大量的close_wait状态为例
1.close_wait状态介绍:
客户端主动关闭连接,服务器接收到客户端的FIN,但是还没有发送自己的FIN,此时的状态为close_wait状态,大量的close_wait状态拖累服务器性能
2.close_wait产生的原因:
某种情况下客户端关闭了连接,但是我方忙于读写,没有关闭连接
3.解决方法:
思想:检查出客户端已经关闭的连接,关闭他
之所以会出现这种问题,肯定是服务器端的连接释放的代码存在问题
1.当服务器读写失败时,可以选择关闭连接
2.定期向连接发送询问数据,检查收到的回复数据包(Heart-Beat线程发送指定格式的心跳数据包)
3.修改keep-live参数(超时时间,tcp检查间隔时间:keeplive探测包发送的间隔,tcp检查次数:如果对方不予应答,探测包发送的次数)
ps:服务器出现大量的close_wait状态,这个锅肯定是服务器端的coder背!
边栏推荐
- A brief introduction to the CheckBox component of the basic components of Flutter
- MySQL修改root账号密码
- Implementation of a sequence table
- Bubble sort, selection sort, insertion sort, binary search directly
- (8) Math class, Arrays class, System class, Biglnteger and BigDecimal classes, date class
- $attrs/$listeners
- (树) 最近公共祖先(LCA)
- Port inspection steps - 7680 port analysis - Dosvc service
- type_traits metaprogramming library learning
- BUG definition of SonarQube
猜你喜欢

Based on the local, linking the world | Schneider Electric "Industrial SI Alliance" joins hands with partners to go to the future industry

(四)递归、可变参数、访问修饰符、理解 main 方法、代码块

Thinking about data governance after Didi fines

C语言表白代码?

VS QT - ui does not display newly added members (controls) || code is silent

组件传值 provide/inject

(八)Math 类、Arrays 类、System类、Biglnteger 和 BigDecimal 类、日期类

Recursive implementation of the Tower of Hanoi problem

LocalDate加减操作及比较大小

mysql基础知识(二)
随机推荐
BP神经网络
qlib架构
Redis 使用LIST做最新评论缓存
(8) Math class, Arrays class, System class, Biglnteger and BigDecimal classes, date class
已解决:不小心卸载pip后(手动安装pip的两种方式)
组件传值 provide/inject
Exsl file preview, word file preview web page method
Notes on the establishment of the company's official website (6): The public security record of the domain name is carried out and the record number is displayed at the bottom of the web page
three.js 制作3D相册
With 7 years of experience, how can functional test engineers improve their abilities step by step?
The application and practice of mid-to-platform brand advertising platform
[shell basics] determine whether the directory is empty
(6) Enumeration and annotation
RESTful api接口设计规范
Implementation of a sequence table
日志级别 和 打印log注意
MySQL 8.0.30 GA
Pytest e-commerce project combat (on)
Automation strategies for legacy systems
The use of beforeDestroy and destroyed