[Dovecot] dbox - how to awaken the monster
Hello people,
Since the invention of this storage called dbox, I have never quite gotten round to understanding it, nor getting to use it. It seems so strange to me and I must ask a few stupid questions about it. I use the MTA to deliver mail to Maildir, either in ~/Maildir or /some/path/%d/%n/Maildir. It has always beat me how dbox comes into play under such circumstances. From the wiki, I see the following: "dbox supports a quick migration from Maildir format" - now this leaves me hanging. How? Suppose I migrate from Maildir to dbox, what changes do I make to the MTA to understand that I use dbox? Ok, I use Exim as my MTA.
I hope someone can explain to me what I need to do to Exim and what to do th Dovecot so that I can test this dbox thing. And suppose I want to transfer userA's mail to UserB, what do I do? With Maildir, I can simply do something like
mv ~A/Maildir ~B/Maildir chown -R B ~b/Maildir
Suppose I am using dbox, howdy?
Thank you in advance. I know those sound dumb, but I simply haven't understood dbox.
-- Best regards, Odhiambo WASHINGTON, Nairobi,KE +254733744121/+254722743223
"The only time a woman really succeeds in changing a man is when he is a baby." - Natalie Wood
Odhiambo Washington wrote:
Hello people,
Since the invention of this storage called dbox, I have never quite gotten round to understanding it, nor getting to use it. It seems so strange to me and I must ask a few stupid questions about it. I use the MTA to deliver mail to Maildir, either in ~/Maildir or /some/path/%d/%n/Maildir. It has always beat me how dbox comes into play under such circumstances. From the wiki, I see the following: "dbox supports a quick migration from Maildir format" - now this leaves me hanging. How? Suppose I migrate from Maildir to dbox, what changes do I make to the MTA to understand that I use dbox? Ok, I use Exim as my MTA.
I hope someone can explain to me what I need to do to Exim and what to do th Dovecot so that I can test this dbox thing. And suppose I want to transfer userA's mail to UserB, what do I do? With Maildir, I can simply do something like
exim does not know about dbox (it's a dovecot-specific format). You'd need to configure exim to use dovecot's deliver as LDA. There are instructions for that in the Wiki.
-- <Endy> taniwha: Quote material :) <taniwha> Endy: :) <knghtbrd> Endy: I already snipped it
Eduardo M KALINOWSKI eduardo@kalinowski.com.br
On Tue, Mar 31, 2009 at 10:17 PM, Eduardo M KALINOWSKI < eduardo@kalinowski.com.br> wrote:
Hello people,
Since the invention of this storage called dbox, I have never quite gotten round to understanding it, nor getting to use it. It seems so strange to me and I must ask a few stupid questions about it. I use the MTA to deliver mail to Maildir, either in ~/Maildir or /some/path/%d/%n/Maildir. It has always beat me how dbox comes into play under such circumstances. From the wiki, I see the following: "dbox supports a quick migration from Maildir format" - now this leaves me hanging. How? Suppose I migrate from Maildir to dbox, what changes do I make to the MTA to understand that I use dbox? Ok, I use Exim as my MTA.
I hope someone can explain to me what I need to do to Exim and what to do
Odhiambo Washington wrote: th
Dovecot so that I can test this dbox thing. And suppose I want to transfer userA's mail to UserB, what do I do? With Maildir, I can simply do something like
exim does not know about dbox (it's a dovecot-specific format). You'd need to configure exim to use dovecot's deliver as LDA. There are instructions for that in the Wiki.
I thought so. Now I have seen, read and understood (so far) http://wiki.dovecot.org/LDA/Exim. However I do not see any examples for configuring dovecot for dbox. Is it as easy as s/maildir/dbox/g in the following:
mail_location = maildir:/var/spool/virtual/%d/%n/Maildir:INDEX=/var/dovecot/%u:CONTROL=/var/dovecot/%u
And suppose I wanted to redeliver mail stored in dbox, using the MTA?? For example, I have used the following script to redeliver mail stored in Maildir:
#!/bin/sh # email=$(find $*) # { for x in ${email}; do sendmail odhiambo@gmail.com < ${x}; done }
I'd invoke this as /path/to/script /dir/to/list
(/path/to/script
Maidir/new for instance)
Ok. Sorry it looks like I have unending questions:(
-- Best regards, Odhiambo WASHINGTON, Nairobi,KE +254733744121/+254722743223
"The only time a woman really succeeds in changing a man is when he is a baby." - Natalie Wood
Odhiambo Washington wrote:
I thought so. Now I have seen, read and understood (so far) http://wiki.dovecot.org/LDA/Exim. However I do not see any examples for configuring dovecot for dbox. Is it as easy as s/maildir/dbox/g in the following:
mail_location = maildir:/var/spool/virtual/%d/%n/Maildir:INDEX=/var/dovecot/%u:CONTROL=/var/dovecot/%u
Not quite. And "configuration" is not "migration" - keep that in mind if you're trying to change an existing system.
Given the above, I'd do: mail_location = dbox:/var/spool/virtual/%d/%n/dbox
Keep in mind dbox is 100% proprietary to Dovecot. While indexes are supplemental - even optional - for the other formats, part of what makes dbox special is that the mails are stored in the indexes. So your configuration that has the indexes split off to different folders probably isn't a good idea if you're going to dbox.
And suppose I wanted to redeliver mail stored in dbox, using the MTA?? For example, I have used the following script to redeliver mail stored in Maildir:
I don't think this would be an option anymore. Maildir stores the raw message in a simple file - which makes such manipulation easy. Dbox will store it in a proprietary format. Unless a utility is provided that would accept a dbox message-id and return a raw message (haven't seen one advertised) you would have to use some kind of IMAP interface to accomplish this. If such access is important to you - stick with maildir.
Ok. Sorry it looks like I have unending questions:(
Never apologize for seeking knowledge.
Daniel
On Wed, Apr 1, 2009 at 4:06 AM, Daniel L. Miller <dmiller@amfes.com> wrote:
Odhiambo Washington wrote:
I thought so. Now I have seen, read and understood (so far) http://wiki.dovecot.org/LDA/Exim. However I do not see any examples for configuring dovecot for dbox. Is it as easy as s/maildir/dbox/g in the following:
mail_location =
maildir:/var/spool/virtual/%d/%n/Maildir:INDEX=/var/dovecot/%u:CONTROL=/var/dovecot/%u
Not quite. And "configuration" is not "migration" - keep that in mind if you're trying to change an existing system.
Given the above, I'd do: mail_location = dbox:/var/spool/virtual/%d/%n/dbox
Keep in mind dbox is 100% proprietary to Dovecot. While indexes are supplemental - even optional - for the other formats, part of what makes dbox special is that the mails are stored in the indexes. So your configuration that has the indexes split off to different folders probably isn't a good idea if you're going to dbox.
And suppose I wanted to redeliver mail stored in dbox, using the MTA?? For example, I have used the following script to redeliver mail stored in Maildir:
I don't think this would be an option anymore. Maildir stores the raw message in a simple file - which makes such manipulation easy. Dbox will store it in a proprietary format. Unless a utility is provided that would accept a dbox message-id and return a raw message (haven't seen one advertised) you would have to use some kind of IMAP interface to accomplish this. If such access is important to you - stick with maildir.
Ok. Sorry it looks like I have unending questions:(
Never apologize for seeking knowledge.
Thanks Daniel.
One last question: There was a mention of a script to migrate from Maildir to dbox. Where is it?
-- Best regards, Odhiambo WASHINGTON, Nairobi,KE +254733744121/+254722743223
"The only time a woman really succeeds in changing a man is when he is a baby." - Natalie Wood
On Wed, Apr 1, 2009 at 4:06 AM, Daniel L. Miller <dmiller@amfes.com> wrote:
Odhiambo Washington wrote:
I thought so. Now I have seen, read and understood (so far) http://wiki.dovecot.org/LDA/Exim. However I do not see any examples for configuring dovecot for dbox. Is it as easy as s/maildir/dbox/g in the following:
mail_location =
maildir:/var/spool/virtual/%d/%n/Maildir:INDEX=/var/dovecot/%u:CONTROL=/var/dovecot/%u
Not quite. And "configuration" is not "migration" - keep that in mind if you're trying to change an existing system.
Given the above, I'd do: mail_location = dbox:/var/spool/virtual/%d/%n/dbox
Keep in mind dbox is 100% proprietary to Dovecot. While indexes are supplemental - even optional - for the other formats, part of what makes dbox special is that the mails are stored in the indexes. So your configuration that has the indexes split off to different folders probably isn't a good idea if you're going to dbox.
And suppose I wanted to redeliver mail stored in dbox, using the MTA?? For example, I have used the following script to redeliver mail stored in Maildir:
I don't think this would be an option anymore. Maildir stores the raw message in a simple file - which makes such manipulation easy. Dbox will store it in a proprietary format. Unless a utility is provided that would accept a dbox message-id and return a raw message (haven't seen one advertised) you would have to use some kind of IMAP interface to accomplish this. If such access is important to you - stick with maildir.
Ok. Sorry it looks like I have unending questions:(
Never apologize for seeking knowledge.
Thanks Daniel. Your explanation is clear enough.
One last question: Can dbox co-exist with Maildir? And finally, there was a mention of a script to migrate from Maildir to dbox. Where is it?
-- Best regards, Odhiambo WASHINGTON, Nairobi,KE +254733744121/+254722743223
"The only time a woman really succeeds in changing a man is when he is a baby." - Natalie Wood
Odhiambo Washington wrote:
One last question: Can dbox co-exist with Maildir?
Depends on what you mean by "co-exist". It is possible to define per-user mail storage within the userdb. It is also possible (I believe) to have multiple namespaces, and the mailstorage can be different for each namespace (I don't understand namespaces myself yet, so can't help much there).
And finally, there was a mention of a script to migrate from Maildir to dbox. Where is it?
I'm trying to use the convert plugin myself. It seemed very simple to implement. My difficulty is I previously had home=mail - which is a Bad Thing. After I've finished splitting those out, I'll try the covert again.
My suggestion, if you want to try it, is: port, using the test mailbox - NOT YOUR OWN!! I recommend telnet - less
- Setup a test mailbox, and send a couple of mails to it.
- Make sure no users are currently connected.
- Stop ALL mail services (including your MTA - otherwise delivery will mess things up)
- Backup your dovecot.conf file.
- Re-configure Dovecot to listen on a non-standard port, like 10143, to prevent other clients from re-connecting.
- Configure the covert plugin and your target mailstorage
- Have a mail client - or even telnet - connect to Dovecot on that new
likely to have a problem. 8. Examine the mailbox folder - did the conversion complete successfully?
If it worked, take a deep breath, cross your fingers...and reconfigure dovecot to listen on the standard ports again and allow users to connect.
Daniel
participants (3)
-
Daniel L. Miller
-
Eduardo M KALINOWSKI
-
Odhiambo Washington