| Linode Forum https://forum.linode.com/ |
|
| Postfix+courier - IMAP working but nothing arrives https://forum.linode.com/viewtopic.php?f=11&t=4843 |
Page 1 of 1 |
| Author: | Daveo [ Sun Nov 15, 2009 5:04 pm ] |
| Post subject: | Postfix+courier - IMAP working but nothing arrives |
Hi everyone, I'm nearly there with setting up all the services I want, but I haven't got email working yet. I followed the guide in the library for postfix+courier on debian. The only thing I did wrong was say "yes" to "create directories for web based administration", which I doubt would cause a problem (please let me know if you think I should disable that..and how I've double checked that all the steps were completed properly, as much as I was able to (database and config files look ok to me, matching what the guide says to do). I've run both the telnet checks that guide recommends, and have sent an email from mailx on localhost. Also sent email from my home pc. I can see those emails in /var/mail/user. I've set up IMAP successfully as far as I can tell (thunderbird complained until I had all the addresses, usernames and passwords set up right, and now it seems to be happily logging in to courier). I can see my inbox in thunderbird, but no email arrives in my inbox. Any idea what I might be doing wrong or what I can look for? BTW one little complexity that I don't expect will make any difference: I have iptables only allowing input on port 25 on eth0 and am connecting to courier-imap over my VPN (i.e. courier-imap-ssl is blocked at the firewall and is only listening on a VPN address anyway). As I said though, the connection to courier from my client doesn't seem to be the problem. I've also stopped courier-pop, courier-pop-ssl and courier-imap because I'm not using them - I think that's fine? Restarting them doesn't seem to help anyway. Many thanks for any help! Dave. |
|
| Author: | saman007uk [ Sun Nov 15, 2009 6:25 pm ] |
| Post subject: | |
Courier uses Maildir to store the emails, and not mbox (which you are currently using). See http://en.wikipedia.org/wiki/Maildir Do, as root: Code: echo "home_mailbox = Maildir/" >> /etc/postfix/main.cf Then send an e-mail to yourself, you should see it appear in /home/user/Maildir/new and also in Thunderbird. |
|
| Author: | Daveo [ Sun Nov 15, 2009 7:02 pm ] |
| Post subject: | |
saman007uk wrote: Courier uses Maildir to store the emails, and not mbox (which you are currently using). See http://en.wikipedia.org/wiki/Maildir
Do, as root: Code: echo "home_mailbox = Maildir/" >> /etc/postfix/main.cf Then send an e-mail to yourself, you should see it appear in /home/user/Maildir/new and also in Thunderbird. Thanks for looking Saman. I did that, and the email did then arrive in /home/user/Maildir, but no luck still with getting it delivered. I've connected by pop3 too and no sign that courier has picked the email up. Has this got something to do with virtual mailboxes? The configuration specified in the guide doesn't mention home_mailbox, just the following settings: myhostname = server.yourdomain.com mydestination = server.yourdomain.com, localhost, localhost.localdomain' mynetworks = 127.0.0.0/8 message_size_limit = 30720000 virtual_alias_domains = virtual_alias_maps = proxy:mysql:/etc/postfix/mysql-virtual_forwardings.cf, mysql:/etc/postfix/mysql-virtual_email2email.cf virtual_mailbox_domains = proxy:mysql:/etc/postfix/mysql-virtual_domains.cf virtual_mailbox_maps = proxy:mysql:/etc/postfix/mysql-virtual_mailboxes.cf virtual_mailbox_base = /home/vmail virtual_uid_maps = static:5000 virtual_gid_maps = static:5000 smtpd_sasl_auth_enable = yes broken_sasl_auth_clients = yes smtpd_sasl_authenticated_header = yes smtpd_recipient_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_unauth_destination smtpd_use_tls = yes smtpd_tls_cert_file = /etc/postfix/smtpd.cert smtpd_tls_key_file = /etc/postfix/smtpd.key virtual_create_maildirsize = yes virtual_maildir_extended = yes proxy_read_maps = $local_recipient_maps mydestination $virtual_alias_maps $virtual_alias_domains $virtual_mailbox_maps $virtual_mailbox_domains $relay_recipient_maps $relay_domains $canonical_maps $sender_canonical_maps $recipient_canonical_maps $relocated_maps $transport_maps $mynetworks $virtual_mailbox_limit_maps' Any other ideas please? Is there a way I can interrogate courier to see if it's seen these messages? Cheers, Dave |
|
| Author: | saman007uk [ Mon Nov 16, 2009 4:26 am ] |
| Post subject: | |
Can you post Courier-Imaps config? |
|
| Author: | Daveo [ Mon Nov 16, 2009 5:59 pm ] |
| Post subject: | |
The files you requested are below, but I think I may have just spotted something: in /var/log/mail.info.1 I have the error message: imapd-ssl: chdir mydomain.com/user/: No such file or directory ... well duh! Also: postfix/trivial-rewrite[10716]: warning: do not list domain mydomain.com in BOTH mydestination and virtual_mailbox_domains I think the first one may well be my problem (and I suppose maybe it's caused by the second one?).. haven't a clue how right now, but I'll have some spare time tomorrow to scratch my head... Any hints very welcome! Here are those files anyway > imapd-ssl SSLPORT=993 SSLADDRESS=10.8.0.1 SSLPIDFILE=/var/run/courier/imapd-ssl.pid SSLLOGGEROPTS="-name=imapd-ssl" IMAPDSSLSTART=YES IMAPDSTARTTLS=YES IMAP_TLS_REQUIRED=0 COURIERTLS=/usr/bin/couriertls TLS_KX_LIST=ALL TLS_COMPRESSION=ALL TLS_CERTS=X509 TLS_CERTFILE=/etc/courier/imapd.pem TLS_TRUSTCERTS=/etc/ssl/certs TLS_VERIFYPEER=NONE TLS_CACHEFILE=/var/lib/courier/couriersslcache TLS_CACHESIZE=524288 MAILDIRPATH=Maildir > imapd ADDRESS=10.8.0.1 PORT=143 MAXDAEMONS=40 MAXPERIP=20 PIDFILE=/var/run/courier/imapd.pid TCPDOPTS="-nodnslookup -noidentlookup" LOGGEROPTS="-name=imapd" IMAP_CAPABILITY="IMAP4rev1 UIDPLUS CHILDREN NAMESPACE THREAD=ORDEREDSUBJECT THREAD=REFERENCES SORT QUOTA IDLE" IMAP_KEYWORDS=1 IMAP_ACL=1 IMAP_CAPABILITY_ORIG="IMAP4rev1 UIDPLUS CHILDREN NAMESPACE THREAD=ORDEREDSUBJECT THREAD=REFERENCES SORT QUOTA AUTH=CRAM-MD5 AUTH=CRAM-SHA1 AUTH=CRAM-SHA256 IDLE" IMAP_PROXY=0 IMAP_PROXY_FOREIGN=0 IMAP_IDLE_TIMEOUT=60 IMAP_MAILBOX_SANITY_CHECK=1 IMAP_CAPABILITY_TLS="$IMAP_CAPABILITY AUTH=PLAIN" IMAP_CAPABILITY_TLS_ORIG="$IMAP_CAPABILITY_ORIG AUTH=PLAIN" IMAP_DISABLETHREADSORT=0 IMAP_CHECK_ALL_FOLDERS=0 IMAP_OBSOLETE_CLIENT=0 IMAP_UMASK=022 IMAP_ULIMITD=65536 IMAP_USELOCKS=1 IMAP_SHAREDINDEXFILE=/etc/courier/shared/index IMAP_ENHANCEDIDLE=0 IMAP_TRASHFOLDERNAME=Trash IMAP_EMPTYTRASH=Trash:7 IMAP_MOVE_EXPUNGE_TO_TRASH=0 SENDMAIL=/usr/sbin/sendmail HEADERFROM=X-IMAP-Sender IMAPDSTART=YES MAILDIRPATH=Maildir Cheers, Dave |
|
| Author: | Daveo [ Tue Nov 17, 2009 6:17 am ] |
| Post subject: | |
Ok I figured it out I don't need the "home_mailbox = Maildir/" line sama recommended, because this is a virtual mail setup, and we (courier) want the emails to appear in /home/vmail/mydomain.com. The linode debian postfix tutorial says to: "Issue the following commands to complete the remaining steps required for Postfix configuration. Please be sure to replace "server.yourdomain.com" with the fully qualified domain name you used for your system mail name. [...] postconf -e 'mydestination = server.yourdomain.com, localhost, localhost.localdomain' " BUT - our domain mydomain.com MUST NOT be in the mydestination list because it's a virtual mailbox domain: (from this tutorial) "NEVER list a virtual MAILBOX domain name as a mydestination domain!" Glad to have it working, but IMO the linode tutorial needs clarification on this point. |
|
| Page 1 of 1 | All times are UTC-04:00 |
| Powered by phpBB® Forum Software © phpBB Group http://www.phpbb.com/ |
|