BUSY Redis is busy running a script Redis Origin: Data OSI layer 7 · Application Last updated 5 Nov 2026

Redis: (error) BUSY Redis is busy running a script. You can only call SCRIPT KILL or SHUTDOWN NOSAVE

A long-running Lua script (or function) blocks the single-threaded server, so other commands are rejected.

Exact message you may see BUSY Redis is busy running a script. You can only call SCRIPT KILL or SHUTDOWN NOSAVE(error) BUSY Redis is busy running a scriptReplyError: BUSY Redis is busy running a scriptBUSY Redis is busy running a script. You can only call FUNCTION KILL or SHUTDOWN NOSAVE
Seen on: Redis Linux

Meaning

After lua-time-limit (5 s default, busy-reply-threshold) Redis answers BUSY to other clients. Run SCRIPT KILL (only works if the script hasn't written) or SHUTDOWN NOSAVE as a last resort. Fix the script: remove loops over big keyspaces, avoid KEYS, batch with SCAN, and keep scripts short.

Common causes

  • Infinite or long loop in Lua
  • Scripts iterating large collections
  • KEYS * in script
  • Heavy EVALSHA on big data
  • Deadlock-like logic waiting in script

⚡ Quick fix

  1. redis-cli SCRIPT KILL
  2. If it wrote data: SHUTDOWN NOSAVE (loses unsaved data)
  3. Rewrite scripts to be O(1)/bounded

Detailed fix by platform

Linux

  1. redis-cli SCRIPT KILL; redis-cli CONFIG GET busy-reply-threshold

How to diagnose

  1. Script — Long?
  2. Kill — Possible?
  3. Fix — Bounded work?

🔧 Still not fixed?

Many errors look alike. If the steps above didn’t solve it, one of these is probably what you’re facing:

Where this error sits

Origin: Data. Errors that are often confused with or caused by this one (click to open):

BullMQ: Missing lock for job / job stalled more than allowable limit — BullMQ: Error: Missing lock for job 42. moveToFinished / job stalled more than allowable limit (Redis)BullMQ: Missing lock …Celery with Redis: tasks run twice (visibility_timeout) — Celery: Task executed twice / Restoring unacked messages — Redis broker visibility_timeout shorter than task ETA (Redis)Celery with Redis: ta…Client output buffer limit reached (scheduled to be closed) — Redis: Client id=12 addr=10.0.0.5:51234 scheduled to be closed ASAP for overcoming of output buffer limits (Redis)Client output buffer …ClientClosedError: The client is closed (node-redis v4) — node-redis: ClientClosedError: The client is closed (Redis)ClientClosedError: Th…CLUSTERDOWN Hash slot not served — Redis Cluster: (error) CLUSTERDOWN Hash slot not served / The cluster is down (Redis)CLUSTERDOWN Hash slot…CROSSSLOT Keys in request don't hash to the same slot — Redis Cluster: (error) CROSSSLOT Keys in request don't hash to the same slot (Redis)CROSSSLOT Keys in req…DENIED Redis is running in protected mode — Redis: DENIED Redis is running in protected mode because protected mode is enabled and no password is set for the default user (Redis)DENIED Redis is runni…ECONNRESET / Connection reset by peer on idle Redis connection — Redis: Error: read ECONNRESET / redis.exceptions.ConnectionError: Connection reset by peer after idle time (Redis)ECONNRESET / Connecti…BUSY Redi…

Explore the map of this error Full error map →

🧠 Still stuck? Analyze your error

Paste the full message, response headers or stack trace — we'll detect the platform and point to the most likely cause.

💬 What worked for others

No tips yet — did something else fix this for you?

Share what worked for you

Tips are checked by an editor before they appear. Links are removed.