1RECONSTRUCT(8)              System Manager's Manual             RECONSTRUCT(8)
2
3
4

NAME

6       reconstruct - reconstruct mailboxes
7

SYNOPSIS

9       reconstruct  [ -C config-file ] [ -p partition ] [ -x ] [ -r ] [ -f ] [
10       -k ] [ -s ]
11
12       mailbox...
13       reconstruct [ -C config-file ] -m
14

DESCRIPTION

16       Reconstruct rebuilds one or more IMAP mailboxes.  When invoked with the
17       -m  switch,  it  rebuilds the master mailboxes file.  It can be used to
18       recover from almost any sort of data corruption.
19
20       If Reconstruct can find existing header and index files, it attempts to
21       preserve  any data in them that is not derivable from the message files
22       themselves.  The state reconstruct attempts to  preserve  includes  the
23       flag  names,  flag  state,  and  internaldate.  Reconstruct derives all
24       other information from the message files.
25
26       Reconstruct reads its configuration options out  of  the  imapd.conf(5)
27       file  unless  specified  otherwise by -C.  Any mailbox directory under‐
28       neath the path specified in the partition-news configuration option  is
29       assumed to be in news format.
30
31       Reconstruct  does not adjust the quota usage recorded in any quota root
32       files.  After running reconstruct, it is advisable to run quota(8) with
33       the -f switch in order to fix the quota root files.
34

OPTIONS

36       -C config-file
37              Read configuration options from config-file.
38
39       -p partition
40              Search  for the listed (non-existant) mailboxes on the indicated
41              partition.  Create the mailboxes in the database in addition  to
42              reconstructing them.  (not compatible with the use of wildcards)
43
44       -x     When processing a mailbox which is not in the mailbox list (e.g.
45              via the -p or -f options), do not import the metadata  from  the
46              mailbox,  instead  create  it anew (this specifically affects at
47              least the mailbox's seen state unique  identifier,  user  flags,
48              and ACL).
49
50       -r     Recursively  reconstruct  all  sub-mailboxes of the mailboxes or
51              mailbox prefixes given as arguments.
52
53       -f     Examine the filesystem underneath mailbox, adding  all  directo‐
54              ries  with  a cyrus.header found there as new mailboxes.  Useful
55              for restoring mailboxes from backups.
56
57       -k     Preserve the cyrus.expunge file and  the  corresponding  message
58              files instead of deleting them.
59
60       -s     Adds  synchronization records to the log, so the synchronization
61              service can replicate the changes.
62
63       -m     NOTE: CURRENTLY UNAVAILABLE
64              Rebuild the mailboxes file.  Use whatever data in  the  existing
65              mailboxes file it can scavenge, then scans all partitions listed
66              in the imapd.conf(5) file for additional mailboxes.
67

EXAMPLES

69       You want to reconstruct the index files for a user, you have  recovered
70       a  deleted  mail  file  from  backup  and  given it a suitable name (eg
71       user/ben-lacy/33.), but it is not visible since it is not indexed:
72
73       reconstruct -r user.ben-lacy
74
75       If you have the unixhierarchysep:yes option set in /etc/imapd.conf  you
76       would need to run:
77
78       reconstruct -r user/ben.lacy
79
80

FILES

82       /etc/imapd.conf
83
84
85
86CMU                              Project Cyrus                  RECONSTRUCT(8)
Impressum