HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials

HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials (http://www.howtoforge.com/forums/index.php)
-   Installation/Configuration (http://www.howtoforge.com/forums/forumdisplay.php?f=16)
-   -   Changing from mbox to maildir after installing ISPConfig (http://www.howtoforge.com/forums/showthread.php?t=4162)

Rustin 9th May 2006 00:22

Changing from mbox to maildir after installing ISPConfig
 
Hello everyone,

I've configured Debian 3.1 to Falko's 'perfect' spec with mbox style mail using popd for pop3 access. ISPConfig has been working great with no problems, I've even done two upgrades without a single issue (2.2.0 to 2.2.1 to 2.2.2 I think.). For some reason I wasn't thinking when I set the mail system up. What I really want is Courier with Maildirs. Currently there are no working mail accounts on the new server (I'm moving all my clients from an old server to ISPConfig setup); the only accounts I've created for each web is one for ftp access so I could transfer the websites. I've pretty much moved and configured everything except the mail.
My old setup is a running qmail with vpopmail which makes me more comfortable with maildirs. However, I've been wanting to switch to postfix for some time now.

Would this work (#1 and 2 taken from the howto):

1)
apt-get install courier-imap courier-imap-ssl courier-pop courier-pop-ssl

postconf -e 'home_mailbox = Maildir/'
postconf -e 'mailbox_command ='

/etc/init.d/postfix restart


2)
Change the the ispconfig setup under Management for maildirs.

3)
Remove the user accounts I created for ftp access and re-adding them. (will this create ownership issues of the existing /var/www/... files I ftp'ed with the old accounts?)

thanks,
rustin

falko 9th May 2006 00:43

Quote:

Originally Posted by Rustin
1)
apt-get install courier-imap courier-imap-ssl courier-pop courier-pop-ssl

Yes.

Quote:

Originally Posted by Rustin
postconf -e 'home_mailbox = Maildir/'
postconf -e 'mailbox_command ='

/etc/init.d/postfix restart

You don't need this if you use ISPConfig.


Quote:

Originally Posted by Rustin
2)
Change the the ispconfig setup under Management for maildirs.

Correct.

Quote:

Originally Posted by Rustin
3)
Remove the user accounts I created for ftp access and re-adding them. (will this create ownership issues of the existing /var/www/... files I ftp'ed with the old accounts?)

Don't remove them. Just change something in the ISPConfig interface for these users, e.g. enable Mailscan and then disable it again later on. This will make ISPConfig rewrite the mail configuration for the users.

MvincM 9th May 2006 07:56

Hi,

If you have old mails in mbox (not downloaded by clients) you can convert them to Maildir by "mb2md" program.

Best regards,
MvincM

HardyHarvey 10th April 2008 21:04

Hi guys glad to find a thread with a similar query to my own.

My situation is that I neglected to install courier-pop & etc before installing ISPConfig. I guess the install didn't check for it? I had installed postfix in advance though. Now we've got a dozen sites published and a customer that wants to have serious email support.. so we have to get email working after all.

Check out this code and tell me how screwed up my installation is:

Code:


harvey@ubuntu:~$ telnet localhost 25
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
220 mail.domain.ca ESMTP Postfix (Ubuntu)
helo someotherdomain.ca
250 mail.domain.ca
mail from:harvey@domain.ca
250 Ok
rcpt to: info@someotherdomain.ca
250 Ok
data
354 End data with <CR><LF>.<CR><LF>
To: info@someotherdomain.ca
From: harvey@domain.ca
Subject: test only
test onlyi

.
250 Ok: queued as 88F5F480CBD
quit
221 Bye
Connection closed by foreign host.
You have mail in /var/mail/harvey

:confused: :confused: :confused: :confused:

Code:

harvey@ubuntu:~$ cd /var/mail
harvey@ubuntu:/var/mail$ ls -la
total 12
drwxrwsr-x  2 root                mail 4096 2008-04-10 11:54 .
drwxr-xr-x 15 root                root 4096 2008-03-16 20:10 ..
-rw-------  1 someotherdomain  mail    0 2008-03-28 15:17 someotherdomain
-rw-------  1 harvey              mail 2391 2008-04-10 11:54 harvey
-rw-------  1 riccardo            mail    0 2008-04-08 08:03 riccardo
-rw-------  1 web2_testuser      mail    0 2008-03-26 07:22 web2_testuser
harvey@ubuntu:/var/mail$ cat harvey
From MAILER-DAEMON  Thu Apr 10 11:54:59 2008
Return-Path: <>
X-Original-To: harvey@domain.ca
Delivered-To: harvey@domain.ca
Received: by mail.domain.ca (Postfix)
        id 98534480CC1; Thu, 10 Apr 2008 11:54:59 -0700 (PDT)
Date: Thu, 10 Apr 2008 11:54:59 -0700 (PDT)
From: MAILER-DAEMON@ubuntu.domain.ca (Mail Delivery System)
Subject: Undelivered Mail Returned to Sender
To: harvey@domain.ca
MIME-Version: 1.0
Content-Type: multipart/report; report-type=delivery-status;
        boundary="88F5F480CBD.1207853699/mail.domain.ca"
Message-Id: <20080410185459.98534480CC1@mail.domain.ca>

This is a MIME-encapsulated message.

--88F5F480CBD.1207853699/mail.domain.ca
Content-Description: Notification
Content-Type: text/plain

This is the Postfix program at host mail.domain.ca.

I'm sorry to have to inform you that your message could not
be delivered to one or more recipients. It's attached below.

For further assistance, please send mail to <postmaster>

If you do so, please include this problem report. You can
delete your own text from the attached returned message.

                        The Postfix program

<info@ubuntu.domain.ca> (expanded from <info@someotherdomain.ca>): Host
    or domain name not found. Name service error for name=ubuntu.domain.ca
    type=A: Host not found

--88F5F480CBD.1207853699/mail.domain.ca
Content-Description: Delivery report
Content-Type: message/delivery-status

Reporting-MTA: dns; mail.domain.ca
X-Postfix-Queue-ID: 88F5F480CBD
X-Postfix-Sender: rfc822; harvey@domain.ca
Arrival-Date: Thu, 10 Apr 2008 11:54:06 -0700 (PDT)

Final-Recipient: rfc822; info@ubuntu.domain.ca
Original-Recipient: rfc822; info@someotherdomain.ca
Action: failed
Status: 5.0.0
Diagnostic-Code: X-Postfix; Host or domain name not found. Name service error
    for name=ubuntu.domain.ca type=A: Host not found

--88F5F480CBD.1207853699/mail.domain.ca
Content-Description: Undelivered Message
Content-Type: message/rfc822

Received: from someotherdomain.ca (localhost [127.0.0.1])
        by mail.domain.ca (Postfix) with SMTP id 88F5F480CBD
        for <info@someotherdomain.ca>; Thu, 10 Apr 2008 11:54:06 -0700 (PDT)
To: info@someotherdomain.ca
From: harvey@domain.ca
Subject: test only
Message-Id: <20080410185424.88F5F480CBD@mail.domain.ca>
Date: Thu, 10 Apr 2008 11:54:06 -0700 (PDT)

test onlyi


--88F5F480CBD.1207853699/mail.domain.ca--

harvey@ubuntu:/var/mail$

Why would I get the mail in my maildir? it's clearly to another email address.

till 10th April 2008 21:53

If you want to get a stable email system, use maildir and not mbox for mail storage. Just redo all steps for the mail configuration from the perfect setup guide for your linux distribution and enable maildir support in ispconfig.

HardyHarvey 10th April 2008 23:52

holy cow i think i missed a bunch of the pages to the ultimate install, or maybe just skipped over some? anyways was a while back that i installed it originally.

It seems to be working for me now. My last concern is that the pop3 session takes only the username and not the domain, but i remember coming across a fix for this in one of the forums.

IE i would like to have an info@domain.com for each domain, each with it's own mailbox. 'telnet localhost pop3' requires that i don't use the trailing @domain.com so i'm concerned that there would actually be more than one mailbox. for anyone named info at any of the domains we host..

anyways THANKS! :)

Cheers
Harvey

till 11th April 2008 09:53

The part in front of the @ sign is not the username. Please do not mix up usernames and email addresses, this are 2 different fields in the user settings. Also ISPConfig uses a username prefix to avaoid the problem.

blocker 4th June 2008 11:16

Hi,

is there a way to get ispconfig to "force-rewrite" the .procmailrc of every user on the system?

Regards

blocker 4th June 2008 12:55

maildir mailbox problem after server move
 
i have moved a complete ispconfig server to another machine, everything is working perfect except that the old server uses mbox and i want the new to use Maildir

i have made everything needed for the maildir but users that was moved from the old server still receive their mails in /var/mail/username

example .procmailrc of such user:

Code:

MAILDIR=$HOME/Maildir/
DEFAULT=$MAILDIR
ORGMAIL=$MAILDIR

INCLUDERC=/var/www/web47/user/username/.mailsize.rc
## INCLUDERC=/var/www/web47/user/username/.quota.rc
INCLUDERC=/var/www/web47/user/username/.antivirus.rc
INCLUDERC=/var/www/web47/user/username/.local-rules.rc
INCLUDERC=/var/www/web47/user/username/.html-trap.rc
INCLUDERC=/var/www/web47/user/username/.spamassassin.rc
INCLUDERC=/var/www/web47/user/username/.autoresponder.rc

anybody has an ide whats going on...

falko 5th June 2008 17:02

You can try this:
Code:

postconf -e 'home_mailbox = Maildir/'
postconf -e 'mailbox_command ='
/etc/init.d/postfix restart



All times are GMT +2. The time now is 13:25.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.