# High Redis Command Count on Machine (Suspected Keepalive/Ping Issue)

**URL:** <https://community.fly.io/t/high-redis-command-count-on-machine-suspected-keepalive-ping-issue/25281>\
**Category:** Questions / Help\
**Tags:** troubleshooting, redis, login-only\
**Created:** [July 3, 2025, 7:22am UTC](https://community.fly.io/t/high-redis-command-count-on-machine-suspected-keepalive-ping-issue/25281 "2025-07-03T07:22:01Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![brrum](https://sea1.discourse-cdn.com/fly1/user_avatar/community.fly.io/brrum/32/41862_2.png) [@brrum](https://community.fly.io/u/brrum)\
**Post date:** [July 3, 2025, 7:22am UTC](https://community.fly.io/t/high-redis-command-count-on-machine-suspected-keepalive-ping-issue/25281/1 "2025-07-03T07:22:01Z")

</div>

Hello [Fly.io](http://Fly.io) Community,

We’re encountering an issue with our Redis instance where the total\_commands\_processed metric is exceptionally high (3.1 million) despite low perceived activity and no active users. This is causing concern regarding costs and performance.

**Context & Problem:**

- **Observation:** The total\_commands\_processed metric on our Redis machine is abnormally high (3.1 million). We have minimal active users and do not expect such heavy Redis operations.

- **Setup:** The application (QReply.ai worker and chat services) connects to this Redis instance. We’ve observed socket\_keepalive and socket\_timeout configurations in our worker code that might be related.

- **Diagnostic Attempts:**

- **Timeline:** This issue has been observed since [**PLEASE INSERT DATE OR PERIOD WHEN THE ISSUE STARTED, e.g., ‘yesterday evening’ or ‘since the last deployment’**].

**Specific Questions for [Fly.io](http://Fly.io) Support / Community:**

1. **Impact of socket\_keepalive:** Could the socket\_keepalive options in our code (like TCP\_KEEPIDLE, TCP\_KEEPINTVL, TCP\_KEEPCNT) be causing a high total\_commands\_processed count in [Fly.io](http://Fly.io) metrics, even if they are just pings?

2. **[Fly.io](http://Fly.io) Redis Metrics:**

- Is total\_commands\_processed the most relevant metric for this issue?

- How can we access more detailed Redis metrics in [Fly.io](http://Fly.io) (e.g., instantaneous\_ops\_per\_sec, connected\_clients, used\_memory vs. maxmemory)? Specifically, how do we effectively use the “Metrics” section or the Grafana link for deep-dive analysis?

- Are there default [Fly.io](http://Fly.io) configurations for Redis that might influence command counts irrespective of our client settings?

1. **Log Analysis:** Are there specific log filters or CLI commands (fly logs) that can help us trace Redis communication (pings, connections, errors) more effectively at the network level?

2. **High Command Count without Activity:** What are the common reasons for an extremely high total\_commands\_processed on a Redis instance with seemingly low application traffic?

We are seeking to understand if this is a configuration issue on our end, a behavior of [Fly.io](http://Fly.io)’s managed Redis, or something else entirely.

Thank you for your assistance!

Best regards, Michiel

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/fly1/original/3X/6/e/6e8955d00cb218e186ebbe3a6ab06fefdce15290.svg) [@system](https://community.fly.io/u/system)\
**Post date:** [July 10, 2025, 3:29pm UTC](https://community.fly.io/t/high-redis-command-count-on-machine-suspected-keepalive-ping-issue/25281/4 "2025-07-10T15:29:57Z")

</div>

Closed on July 10, 2025, 3:29pm UTC

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.
