1UNEXPUNGE(8) Cyrus IMAP UNEXPUNGE(8)
2
3
4
6 unexpunge - Cyrus IMAP documentation
7
8 Recover messages the user has (accidentally) deleted.
9
11 unexpunge [ -C config-file ] -l mailbox
12 unexpunge [ -C config-file ] -t time-interval [ -d ] [ -v ] [ -f flagname ] mailbox
13 unexpunge [ -C config-file ] -a [ -d ] [ -v ] [ -f flagname ] mailbox
14 unexpunge [ -C config-file ] -u [ -d ] [ -v ] [ -f flagname ] mailbox uid...
15
17 The unexpunge program is used to list or restore messages which have
18 been deleted from a mailbox, but still reside in the Cyrus IMAP mail
19 spool.
20
21 This utility is only useful when the server is configured with ex‐
22 punge_mode set to delayed in its configuration file.
23
24 unexpunge reads its configuration options out of the imapd.conf(5) file
25 unless specified otherwise by -C.
26
28 -C config-file
29 Use the specified configuration file config-file rather than the
30 default imapd.conf(5).
31
32 -l List the expunged messages in the specified mailbox which are
33 available for restoration.
34
35 -t time-interval
36 Unexpunge messages which where expunged within the last time-in‐
37 terval seconds. Use one of the trailing modifiers – m (min‐
38 utes), h (hours), d (days) or w (weeks) – to specify a different
39 time unit.
40
41 -a Restore all of the expunged messages in the specified mailbox.
42
43 -u Restore only messages matching the UIDs, in a space-separated
44 list at the end of the command invocation, in the specified
45 mailbox.
46
47 -d Unset the \Deleted flag on any restored messages.
48
49 -f flagname
50 Set the user flag \flagname on the messages restored, making it
51 easier for the user(s) to find the restored messages and operate
52 on them (in a batch).
53
54 -v Enable verbose output/logging.
55
57 unexpunge -l user/john@example.org
58 List the messages that are expunged and could be restored for mail‐
59 box user/john@example.org.
60
61 unexpunge -u user/john@example.org 278787 278788
62 Unexpunge two of these messages.
63
64 mbexamine user/john@example.org
65 Examine the mailbox for the two restored messages.
66
67 unexpunge -u -d user.johnsmith 46908
68 Unexpunge a select message based on its UID, clearing the \Deleted
69 flag.
70
71 unexpunge -a user.johnsmit.Trash
72 Unexpunge all messages in a user’s Trash, but leave them flagged
73 \Deleted.
74
75 unexpunge -a -f Flagged user.johnsmith.Trash
76 The same, but setting user flag \Flagged to facilitate later bulk
77 operations.
78
79 unexpunge -t 24h -d -f Flagged user.johnsmith
80 Unexpunge messages matching only a given time period.
81
82 unexpunge -t 24h -d -f Flagged user/johnsmith
83 The same command, supporting the unixhierarchysep: yes option in
84 imapd.conf(5).
85
87 /etc/imapd.conf
88
90 imapd.conf(5)
91
93 The Cyrus Team, Nic Bernstein (Onlight), Jeroen van Meeuwen (Kolab Sys‐
94 tems)
95
97 1993-2018, The Cyrus Team
98
99
100
101
1023.2.8 September 01, 2021 UNEXPUNGE(8)