summaryrefslogtreecommitdiffstats
path: root/iredis/data/commands/flushall.md
blob: ff454c1b7775147747012b6a0d66fae59bb66aab (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
Delete all the keys of all the existing databases, not just the currently
selected one. This command never fails.

By default, `FLUSHALL` will synchronously flush all the databases. Starting with
Redis 6.2, setting the **lazyfree-lazy-user-flush** configuration directive to
"yes" changes the default flush mode to asynchronous.

It is possible to use one of the following modifiers to dictate the flushing
mode explicitly:

- `ASYNC`: flushes the databases asynchronously
- `!SYNC`: flushes the databases synchronously

Note: an asynchronous `FLUSHALL` command only deletes keys that were present at
the time the command was invoked. Keys created during an asynchronous flush will
be unaffected.

@return

@simple-string-reply

@history

- `>= 4.0.0`: Added the `ASYNC` flushing mode modifier.
- `>= 6.2.0`: Added the `!SYNC` flushing mode modifier and the
  **lazyfree-lazy-user-flush** configuration directive.