Re: Mailbox hierarchy determination?

Simon Matter via Info-cyrus <[email protected]>
Newsgroups gmane.mail.imap.cyrus
Message-ID <[email protected]>
> The first couple of times I set up cyrus-imapd I used Debian packages
> which separated mailboxes in the default partition into folders based on
> the starting letter of the mailbox; i.e. something like:
>
>    /var/spool/cyrus/mail/{[A-Z,a-z,0-9]}/user
>
> Since I have fewer than 50 users and since I found myself frequently
> "going to the files" so to speak to definitely determine the presence or
> absence of some message a user was concerned about, this hierarchy was
> something of a annoyance, so during the last major upgrade I switched
> this to:
>
>     /srv/imap/{user1,user2,...,userN}
>
> i.e. flattening the folder structure and moving the default partition to
> a large non-system disk unaffected by /var volatility.
>
> Now for the life of me I can't figure out what setting in imapd.conf (if
> any) facilitated this structure (not the location of the default
> partition, but rather not using the [A-Z,a-z,0-9] subfolders.
>
> Last time I left the sieve folders divided by letter; in the next
> iteration I'd like to flatten that folder structure to.
>
> Looking at the Arch package post_install script, it pre-creates a ton of
> folders:
>
> --------------------------
>      # all kinds of directories needed for the IMAP spool
>      for subdir in imap/{,db,log,msg,proc,socket,sieve}
> spool/imap/{,stage.}; do
>          if [ ! -d /var/${subdir} ]; then
>              mkdir -m 0750 -p "/var/${subdir}"
>          fi
>      done
>      for subdir in imap/{user,quota,sieve} spool/imap; do
>          for i in a b c d e f g h i j k l m n o p q r s t v u w x y z \
>                   A B C D E F G H I J K L M N O P Q R S T U V W X Y Z \
>                   0 1 2 3 4 5 6 7 8 9; do
>              if [ ! -d /var/${subdir}/${i} ]; then
>                  mkdir -m 0750 -p "/var/${subdir}/${i}"
>              fi
>          done
> --------------------------
>
> I'm wondering how much or if any of this is really necessary. Will cyrus
> autocreate the necessary folders if missing?

Dirhashing is controlled by "fulldirhash" and "hashimapspool".

IIRC creating the dirs like above is not needed, they are created on demand.

Regards,
Simon

----
Cyrus Home Page: http://www.cyrusimap.org/
List Archives/Info: http://lists.andrew.cmu.edu/pipermail/info-cyrus/
To Unsubscribe:
https://lists.andrew.cmu.edu/mailman/listinfo/info-cyrus
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.