5.1.2.37. mbpath

Translate mailbox names to filesystem paths

5.1.2.37.1. Synopsis

mbpath [ -C config-file ] [ -l ] [ -m ] [ -q ] [ -s ] [ -u ] [ -a | -A | -M | -S | -U ] [ mailbox-names... ]

5.1.2.37.2. Description

Given a mailbox name or a space separated list of mailbox names, mbpath outputs the filesystem path(s) of the mailbox. By default, the mailboxes’ data partition paths are shown (same as -D). See Selectors for selecting which filesystem path(s) to output.

mbpath reads its configuration options out of the imapd.conf(5) file unless specified otherwise by -C. It uses <configdirectory>/mailboxes.db to locate the mailboxes on disk.

5.1.2.37.3. Options

-C config-file

Use the specified configuration file config-file rather than the default imapd.conf(5).

-l

Local mailboxes only (exits with error for remote or nonexistent mailboxes)

-m

Output the path to the metadata files (if different from the message files). Legacy, use -M.

-q

Suppress any error output.

-s

If any error occurs, stop processing the list of mailboxes and exit.

-u

The specified mailbox-names are users, not mailboxes.

5.1.2.37.4. Selectors

-A

Show the mailbox archive path

-D

Show the mailbox data path (default)

-M

Show the mailbox metadata path (same as -m)

-S

Show the user sieve scripts path

-U

Show the user files path (seen, sub, etc)

-a

Show all paths, as if all selectors were specified

5.1.2.37.5. Examples

mbpath user.jsmith
Display the data path for mailbox user.jsmith.
/var/spool/cyrus/user/jsmith
mbpath -M user.jsmith
Display the metadata path for mailbox user.jsmith.
/var/spool/meta/imap/user/jsmith
mbpath -u -S jsmith
Display the sieve scripts path for user jsmith.
/var/spool/sieve/j/jsmith

5.1.2.37.6. Files

/etc/imapd.conf, <configdirectory>/mailboxes.db

5.1.2.37.7. See Also

imapd.conf(5)