【 TiDB 使用环境】测试
【 client-go 版本】v2.0.7
【复现路径】
- 客户端进程中连接tikv服务, 然后将网卡down掉
【遇到的问题:问题现象及影响】
- 客户端进程内存不断的增长,一天能上涨800MB
- 网卡上线后,内存也没有释放
【其他分析】
- 通过日志发现tikv-go客户端不断的重连pd
[2023/12/01 14:45:10.483 +08:00] [WARN] [pd_service_discovery.go:400] [“[pd] failed to get cluster info for the leader”] [leader-addr=http://10.10.10.31:2379] [error=“[PD:client:ErrClientGetClusterInfo]error:rpc error: code = DeadlineExceeded desc = context deadline exceeded target:10.10.10.31:2379 status:CONNECTING: error:rpc error: code = DeadlineExceeded desc = context deadline exceeded target:10.10.10.31:2379 status:CONNECTING”]
[2023/12/01 14:45:10.523 +08:00] [WARN] [pd_service_discovery.go:400] [“[pd] failed to get cluster info for the leader”] [leader-addr=http://10.10.10.31:2379] [error=“[PD:client:ErrClientGetClusterInfo]error:rpc error: code = Unavailable desc = connection error: desc = "transport: Error while dialing: dial tcp 10.10.10.31:2379: i/o timeout" target:10.10.10.31:2379 status:TRANSIENT_FAILURE: error:rpc error: code = Unavailable desc = connection error: desc = "transport: Error while dialing: dial tcp 10.10.10.31:2379: i/o timeout" target:10.10.10.31:2379 status:TRANSIENT_FAILURE”]