Table of Contents
If you want to send us your comments, please do so. Thanks
More on comments
exim4 local e-mail
How to make local mail work with exim4?
Run as root
dpkg-reconfigure exim4-config
Now enter in the screens. They all have the title “Exim4 Mail Server configuration”:
When finished the exim4_listener will be restarted:
[ ok ] Stopping MTA for restart: exim4_listener. [ ok ] Restarting MTA: exim4.
Testing
Run from cron
Make a script and run it from cron.
#! /bin/bash # cron mail test echo "Begin of script `date +%y%m%d.%H%M`"
Save it in
$HOME/crontest.sh
Do
chmod 740 $HOME/crontest.sh
Do
crontab -e
Add a line
* * * * * /home/user/crontest.sh
Close the editor Wait 3 minutes. Do
Look for a line like
U 76 Cron Daemon Tue Jul 07 23:46 25/781 Cron <user@hostname> $HOME/crontest.sh
Enter
76 (the number of the mail to be displayed)
and press enter. Now you should see something like
Message 76: From user@localhost Tue Jul 07 23:46:01 2015 Return-path: <user@localhost> Envelope-to: user@localhost Delivery-date: Tue, 07 Jul 2015 23:46:01 +0000 From: root@localhost (Cron Daemon) To: user@localhost Subject: Cron <user@hostname> /home/user/crontest.sh Content-Type: text/plain; charset=UTF-8 X-Cron-Env: <SHELL=/bin/bash> X-Cron-Env: <MAILTO=user> X-Cron-Env: <HOME=/home/user> X-Cron-Env: <PATH=/usr/bin:/bin> X-Cron-Env: <LOGNAME=user> Date: Tue, 07 Jul 2015 23:46:01 +0000 Status: RO Content-Length: 28 Lines: 1 Begin of script 150707.2346
Close with
q ENTER
Manual e-mail
echo "a test" | mail -s "the subject" user
Reuslts from
tail /var/log/exim4/mainlog
should be something like
2015-07-07 23:41:01 emailID <= user@localhost U=user P=local S=595 2015-07-07 23:41:01 emailID => user <user@localhost> R=local_user T=mail_spool 2015-07-07 23:41:01 emailID Completed
When the mail does not arrive
echo "a test" | mail -s "the subject" user
From $ tail -f /var/log/exim4/mainlog
2015-07-07 21:14:38 firstemailID <= user@empty U=user P=local S=445 2015-07-07 21:14:38 firstemailID ** user@empty R=nonlocal: Mailing to remote domains not supported 2015-07-07 21:14:38 secondemailID <= <> R=firstemailID U=Debian-exim P=local S=1217 2015-07-07 21:14:38 secondemailID ** userm@empty R=nonlocal: Mailing to remote domains not supported 2015-07-07 21:14:38 secondemailID Frozen (delivery error message) 2015-07-07 21:14:38 firstemailID Completed
An other attempt
echo "my test" | mail -s "test message" user@localhost
From $ tail -f /var/log/exim4/mainlog
2015-07-07 21:16:30 thirdemailID <= user@empty U=user P=local S=453 2015-07-07 21:16:30 thirdemailID => user <user@localhost> R=local_user T=maildir_home 2015-07-07 21:16:30 thirdemailID Completed
But the mail can not be found anywhere
Usefull items for debugging
Documentation
file:///usr/share/doc/exim4-doc-html
On the command line
Install eximon4 and run it as eximon exim4 -bp # Display the list of frozen messages exim4 -Mvl emailID # Displays information about this e-mail ps -e | grep exim result: 104 2705 1 0 21:45 ? 00:00:00 /usr/sbin/exim4 -bd -q30m -q30m means run every 30 minutes less /var/mail/user\\ sendmail -bv user\\ dpkg-reconfigure exim4-config\\ nano /etc/exim4/update-exim4.conf.conf\\ service exim4 restart\\ ls /var/spool/exim4/input/ \\ tail -f /var/log/exim4/mainlog\\ invoke-rc.d exim4 reload\\ less $HOME/dead.letter\\ echo "a test" | mail -s "the subject" use\\ less var/lib/exim4/config.autogenerate\\ less /etc/exim4/conf.d/main/02_exim4-config_options\\ ls -l /etc/exim4/conf.d/main/ \\
Issues
paniclog not zero
When “The exim paniclog has non zero size” appears in the mail check less /var/log/exim4/paniclog
rm /var/log/exim4/paniclog if the contents is not relevant or needed anymore
Main subjects on this wiki: Linux, Debian, HTML, Microcontrollers, Privacy
RSS
Disclaimer
Privacy statement
Bugs statement
Cookies
Copyright © : 2014 - 2024 Webevaluation.nl and the authors
Changes reserved.