# ERR Stream 'mystream' has too many entries, old entries will be dropped due to MAXLEN

- **ID:** `redis/stream-entries-maxlen-dropped`
- **Domain:** redis
- **Category:** data_error
- **Error Code:** `ERR`
- **Verification:** ai_generated
- **Fix Rate:** 88%

## Root Cause

Stream reached its configured MAXLEN limit, causing automatic eviction of oldest entries.

## Version Compatibility

| Version | Status | Introduced | Deprecated |
|---------|--------|------------|------------|
| 7.2.0 | active | — | — |
| 7.4.0 | active | — | — |
| 8.0.0 | active | — | — |

## Workarounds

1. **Increase MAXLEN to a higher value: XTRIM mystream MAXLEN ~ 1000000. Use the ~ (tilde) for approximate trimming to reduce overhead.** (85% success)
   ```
   Increase MAXLEN to a higher value: XTRIM mystream MAXLEN ~ 1000000. Use the ~ (tilde) for approximate trimming to reduce overhead.
   ```
2. **Set a time-based retention policy using MINID: XTRIM mystream MINID ~ 1715000000 (Unix timestamp).** (75% success)
   ```
   Set a time-based retention policy using MINID: XTRIM mystream MINID ~ 1715000000 (Unix timestamp).
   ```

## Dead Ends

- **** — Setting MAXLEN to 0 disables the limit entirely, but may cause unbounded memory growth and eventual OOM. (40% fail)
- **** — Manually deleting entries with XDEL does not reduce the stream length counter; only XTRIM works. (60% fail)
