[Dovecot] Separate access to different "folders" of the same mailbox?
Hello Timo and everyone,
I think on such an idea that may save me a bit of space and time:
in my company we have a mailbox that holds a copy of every message that our SMTP processed. While it eats a lot of space, it saved us several times when, you may imaging, user "suddenly" deleted the most important message in his life and call our IT guys for help. The mailbox contains "folders" for each day (like 2011-02-10), which keeps mailings for that day only.
Even with this, it is sometime hard to work with that "keep all" box (basically, it is slow as the size is huge). What I'd like to add is some kind of "virtual folders" (for each of our internal users) that list messages from and to his address. And I'd like to permit every user to see (that is, read only mode) only "his" such a virtual folder in our "keep all" box, so user can see his old messages on his own.
Looks like that is defined as search over 1000 folders will be not that fast).
- I need an ACL to limit user access to "their" folders and somehow hide other folders at all
- Have such virtual folders work with huge ammount of mailings (kind of 300 Gb), separated in maybe 1000 folders (per days). I really afraid it will be slo-o-o-ow search, even with indexes (I mean, virtual folder
The mailbox is maildir by nature. How can I archive these goals with smallest load possible, and if it is possible at all?
Thank you, Alexander Chekalin
On Thu, 10 Feb 2011 09:15:18 +0200 Alexander Chekalin achekalin@lazurit.com wrote:
in my company we have a mailbox that holds a copy of every message that our SMTP processed. While it eats a lot of space, it saved us several times when, you may imaging, user "suddenly" deleted the most important message in his life and call our IT guys for help. The mailbox contains "folders" for each day (like 2011-02-10), which keeps mailings for that day only. [...]
What you are describing is basically a standard mail archiving service. Instead of building this yourself you could look at existing software tools that include the features you describe and offer additional functionality like attachment indexing, signed archives etc. For example Mailarchiva (mailarchiva.com) - There is an open source version as well ( http://sourceforge.net/projects/openmailarchiva/ ) Google lists various other alternatives.
HTH
Regards, Oli
~user/.procmailrc-backup or /etc/procmailrc-backup
MDIR="${HOME}/.maildir"
TODAY_YEAR=date +%Y
TODAY_MONTH=date +%m
TODAY_DAY=date +%d
# prepare the archive
:0
{
dummy=(p="${MDIR}/.archive.$TODAY_YEAR.$TODAY_MONTH.$TODAY_DAY"; if [ ! -d $p ]; then mkdir -p $p; fi;) 2>/dev/null
dummy=`if [ ! $(grep $(date '+archive.%Y.%m.%d')
$HOME/.maildir/subscriptions) ]; then echo $(date '+archive.%Y.%m.%d')
$HOME/.maildir/subscriptions; fi`
:0c
${MDIR}/.archive.$TODAY_YEAR.$TODAY_MONTH.$TODAY_DAY/
}
On 02/10/2011 02:41 AM, Oli Schacher wrote:
On Thu, 10 Feb 2011 09:15:18 +0200 Alexander Chekalin achekalin@lazurit.com wrote:
in my company we have a mailbox that holds a copy of every message that our SMTP processed. While it eats a lot of space, it saved us several times when, you may imaging, user "suddenly" deleted the most important message in his life and call our IT guys for help. The mailbox contains "folders" for each day (like 2011-02-10), which keeps mailings for that day only. [...]
What you are describing is basically a standard mail archiving service. Instead of building this yourself you could look at existing software tools that include the features you describe and offer additional functionality like attachment indexing, signed archives etc. For example Mailarchiva (mailarchiva.com) - There is an open source version as well ( http://sourceforge.net/projects/openmailarchiva/ ) Google lists various other alternatives.
HTH
Regards, Oli
Am 10.02.2011 08:15, schrieb Alexander Chekalin:
Hello Timo and everyone,
I think on such an idea that may save me a bit of space and time:
in my company we have a mailbox that holds a copy of every message that our SMTP processed. While it eats a lot of space, it saved us several times when, you may imaging, user "suddenly" deleted the most important message in his life and call our IT guys for help. The mailbox contains "folders" for each day (like 2011-02-10), which keeps mailings for that day only.
Even with this, it is sometime hard to work with that "keep all" box (basically, it is slow as the size is huge). What I'd like to add is some kind of "virtual folders" (for each of our internal users) that list messages from and to his address. And I'd like to permit every user to see (that is, read only mode) only "his" such a virtual folder in our "keep all" box, so user can see his old messages on his own.
Looks like
- I need an ACL to limit user access to "their" folders and somehow hide other folders at all
you could use a hidden namesspace perhaps
- Have such virtual folders work with huge ammount of mailings (kind of 300 Gb), separated in maybe 1000 folders (per days). I really afraid it will be slo-o-o-ow search, even with indexes (I mean, virtual folder that is defined as search over 1000 folders will be not that fast).
The mailbox is maildir by nature. How can I archive these goals with smallest load possible, and if it is possible at all?
Thank you, Alexander Chekalin
i think you need mail archive system seperated from you daily mail store ( cause of your large archives ) and for that there many solutions possible, in germany for business you have to keep business relevant mails by law for 10 years, with fast search and not changeable, so in real world this law is such nonsense, its not wide implemented yet but as times goes by ,companies want/must implement this ( but who knows what is business relevant mail so they simply store every mail), so whatever you dont have to care about german laws, but you could use one of this archive systems, some of them are open source styled, a few of them go into private clouds you may choose one which fits best to your infrastucture
Best Regards
MfG Robert Schetterer
Germany/Munich/Bavaria
On Thu, 2011-02-10 at 09:15 +0200, Alexander Chekalin wrote:
in my company we have a mailbox that holds a copy of every message that our SMTP processed. While it eats a lot of space, it saved us several times when, you may imaging, user "suddenly" deleted the most important message in his life and call our IT guys for help. The mailbox contains "folders" for each day (like 2011-02-10), which keeps mailings for that day only.
Besides the archiving options others mentioned, there's http://wiki2.dovecot.org/Plugins/Lazyexpunge
participants (5)
-
Alexander Chekalin
-
David Ford
-
Oli Schacher
-
Robert Schetterer
-
Timo Sirainen