Hi Ben, Indeed, the mailq command shows my test messages sitting there with "mail transport unavailable".
┌─[11:48:22/hypership/root/~] └─╼ mailq -Queue ID- --Size-- ----Arrival Time---- -Sender/Recipient------- 2DCCB580C01 1901 Mon Nov 26 11:45:02 trusktr@gmail.com (mail transport unavailable) trusktr@bettafootwear.com
B1449580C03 1895 Mon Nov 26 11:48:41 trusktr@gmail.com (mail transport unavailable) trusktr@bettafootwear.com
-- 5 Kbytes in 2 Requests.
I checked in /etc/syslog-ng/syslog-ng.conf and it shows destination d_mail { file("/var/log/mail.log"); }; but there is no such mail.log file so I created one.
I logged in as mailman by doing su -s /bin/bash mailman then ran
/usr/lib/dovecot/dovecot-lda -f trusktr@gmail.com -d trusktr@bettafootwear.com </home/mailman/test_msg.txt
where /home/mailman/test_msg.txt contains a plain text sentence. After doing that, mailq shows the new messages, but with the same "mail transport unavailable" message. However, in Roundcube I see a new blank message with no subject for each attempt of the dovecot-lda command.
Also, the after running the dovecot-lda command a few times, I noticed it was saying that the log files weren't writable (permission denied), so I fixed that... However, that doesn't seem to have fixed the problem as test emails from gmail still don't appear in Roundcube, but I see them with mailq with "mail transport unavailable".
I'll skip setting up LMTP until I get it working with LDA so I know what I'm doing before getting into more complications.
*/#!/*JoePea
On Mon, Nov 26, 2012 at 3:52 AM, Ben Morrow <ben@morrow.me.uk> wrote:
At 2AM -0800 on 26/11/12 you (/#!/JoePea) wrote:
Hi, thanks for the reply. I'm new to all this. How can I tell if postfix is deferring messages, or if it thinks they've been delieverd? Where is the postfix log?
You can tell if a message is still in the queue with 'mailq'. You can find out why by reading the log. If messages are being deferred they will eventually start bouncing, once Postfix decides they've spent too long in the queue.
Postfix normally logs through the 'mail' facility of syslog.
How do I feed a message to dovecot-lda manually, as mailman?
Something along the lines of
sudo -u mailman /usr/lib/dovecot/dovecot-lda -f some@user -d some@user </some/mail/message
as root should work, depending on your sudo setup. Otherwise you will need to use su, which can be more awkward.
How do I use LMTP instead of LDA?
Read the wiki for the Dovecot end, and use
virtual_transport = lmtp:unix:/path/to/lmtp/socket
on the Postfix end. You will want to test the LMTP server is working manually (with nc -U or something) before trying to get Postfix to deliver to it.
Ben