21

Mail spools are typically under here: /var/spool/mail/$USER Where $USER is your username. For example on my Fedora Linux system: $ ls -l /var/spool/mail/ total 1908 -rw-------. 1 root root 1943163 Jul 13 12:00 root -rw-rw----. 1 rpc mail 0 Dec 18 2010 rpc -rw-rw----. 1 saml mail 689 Jul 12 19:38 saml Mail spools however are not necessarily ...


14

No, you will get a "delivered" notice or an "error" notice. Once the mail is accepted by the remote end, you don't get to know where it goes after that. At least not on the MTA side of things. One of the errors may be "rejected cause of spam" or "rejected because of SPF" or the like, but if your email is accepted, even to the spam folder, you will not get ...


10

No, what happens at the destination is visible only there (unless it bounces your email back to you).


9

Unless explicitly configured otherwise, mail will be transmitted over port 25. You can route mail using other ports, or even other protocols than SMTP but that will typically only work within your own network. The mailservers from your intended recipients will most likely only accept incoming email via SMTP on port 25. For instance when I configure ...


7

Since I could not find an existing, small program, I decided to write my own one. Originally, I came up with: #!/bin/bash # Simple sendmail # filename per spec at http://cr.yp.to/proto/maildir.html rand=$((RANDOM % 1000)) msgname=$(date +%s).P$$R$rand.$(hostname | tr '/:' '\057\072') # Safety measure: do not overwrite existing mail set -o noclobber cat &...


7

Unless your machine is misconfigured, the command mail (or other mail programs such as mutt) will access your local mailbox. Usually the local mailbox is either /var/spool/mail/$USER or /var/mail/$USER. If the mailbox is in a non-standard location, the system administrator may have configured the system to set the MAIL environment variable to the location of ...


6

You should find it in either /var/spool/mail/ (the traditional location) or /var/mail (new recommended location). Note that one may be a symbolic link to the other, so it's best to go to the one that is an actual directory (and not just a link). Here you should find a file called the same as your username, that is your mailbox. It should be owned by you, ...


6

The setting you want to put in main.cf to enable opportunistic encryption is smtp_tls_security_level = may


5

No, what happens after your email leaves your system cannot be traced unless you have access to the receiving computer, or if there is some spam filter program that gives feedback. Such feedback programs would sent an email back asking for confirmation, so that automatic spam could be distinguished from real message sent by humans, but once bots were smart ...


5

The basic mail command is only a mail reader and composer, it doesn't know how to talk to a server over the network (with the SMTP protocol). Talking SMTP is the job of a MTA (message transfer agent). The default MTA on Ubuntu is Postfix. To configure Postfix, run sudo dpkg-reconfigure postfix If you only want to send mail and not receive any, choose “...


4

There are several TLS related settings you can use in the access map: try_tls is used when sendmail is a client (i.e. sending email) tls_srv applies to servers, when sendmail is a client (i.e. sending email) tls_clt applies to clients, when sendmail is a server (i.e. accepting email) srv_features is used when sendmail is a server (i.e. accepting email), ...


4

(This was answered on AskUbuntu by Pasi Suominen, a big thanks to him!) This can be accomplished via virtual regexp (/etc/postfix/virtual-regexp) /.+@.+/ someone@somewhere.com then in main.cf: virtual_maps = hash:/etc/postfix/virtual, regexp:/etc/postfix/virtual-regexp and the mapfile: postmap /etc/postfix/virtual-regexp That should do the trick for ...


4

Unfortunately, msmtp does nothing to help you with the To: field that mail clients display. It only uses the addresses you provide to communicate with the mail server -- for whatever reason, it does nothing to include those addresses within the message body. This behavior is different from its handling of the From: and Date: fields, which will be ...


3

There is no functionality that will tell you which folder your mail was delivered to. Even the tricks that tell you if the message was read, don't tell you where it was read from. However, you can get a good idea from the major providers, gmail, yahoo, and microsoft, if you configure DMARC. This builds on your DKIM and SPF configuration, and can report ...


3

I had the same problem and found the solution by using strace on the nullmailer daemon process. It tried to execute /usr/lib/nullmailer/--starttls which lead me to double-check the remotes file format and have a look at that directory. The solution is to add smtp to your remotes line: smtp-relay.gmail.com smtp --port=587 --starttls


3

TL;DR: PHP doesn't care about what MTA you're using. Longer explanation: this goes way back almost as far as the POSIX standards themselves, but every properly written MTA will provide a binary named sendmail that will behave exactly as the "official" sendmail program would be expected to behave. As a result, every unix program or daemon that, for one ...


3

Any user can potentially run cron jobs. The man user might purge the catman cache. The bin user might do library and package management. The www-data user might purge caches. If any of these cron jobs give output (often to indicate a problem) it is nice to let someone know, and cron does this by default by mailing the running user. Now the simple thing to ...


3

MTA is a part of SMTP server, it's responsible for receiving emails from MSA(https://en.m.wikipedia.org/wiki/Message_submission_agent) and then forwarding them to MDA (if the destination of these mails is local) or to another SMTP server. Some people call MTA a SMTP server.


2

I use fail2ban. You can edit /etc/fail2ban/filter.d/postfix.conf to catch any further attempts. I monitor my /var/log/mail.log files to look for suspicious behaviour and add to postfix.conf as required. Here is my postfix.conf which does catch the line you mention above. [INCLUDES] before = common.conf [Definition] _daemon = postfix/smtpd failregex = ^%(...


2

If nullmailer is failing with smtp.gmail.com try using IPv4 address directly: 74.125.206.109 my /etc/nullmailer/remotes looks like this: 74.125.206.108 smtp --port=465 --auth-login --ssl --user=USER@gmail.com --pass=PASS --insecure


2

ACL line could be the next: deny condition = ${lookup{$localpart}nwildlsearch{/path/to/the/black.list}{yes}{no}} While black.list contains PCRE regexes one per line like that: ^.*[0-9].* ^.*[!@#$%^&*()_+].* ^.*sales.*


2

Here's the tls section of my config for postfix, gmail recognizes messages as being sent encrypted. I'm using a letsencrypt cert on a Debian system smtpd_use_tls = yes smtpd_tls_key_file = /etc/letsencrypt/live/my.domain/privkey.pem smtpd_tls_cert_file = /etc/letsencrypt/live/my.domain/fullchain.pem smtpd_tls_received_header = yes ...


2

how do I find out what MTA/MDA my system is using? Use your system's package manager. Look for packages for qmail, Postfix, exim, smail, ZMailer, MMDF, or Sendmail being installed. There are a few less common packages. You might have a very cut down system that passes everything along to a smarthost, such as mini-qmail or ssmtp for example. Of course, ...


2

On cron and MUA-MTA connection Practical Answers I generally create an postfix alias for my cron users. This way all cron job mails are delivered to the aliased address in my lookup table. So, a practical answer is: Cron messages can be sent off server/domain/machine to any arbitrary Internet wide email address. Furthermore, cron itself can be ...


1

The standard ports for normal (in-the-clear) and secure/encrypted communications, by protocol: IMAP: normal 143, secure 993 POP: normal 110, secure 995 SMTP: normal 25, secure 465/587 Confusingingly SMTP has two secure ports. You're supposed to use 465 for SSL/TLS and 587 STARTTLS (see the last section of this page) though it's not mandated. Addressing ...


1

To add to the solution by Andrzej, you can set a lock for a wider region than just a single recipe if you need to with the LOCKFILE special variable. # Only one instance of Procmail can enter this region LOCKFILE=.procmail-critical-region.lock :0 * condition | action value=`program` :0 * another condition | another action # We are done now; okay for ...


1

You may use procmail's locking to make multiple instances execute one instance of the perl script at given time. See man procmailrc and man procmailex :0 w: script.lock | /.../script.pl O course there are other ways but How many messages per hour do you expect to process in peak and average hour?


1

Use one of Debian's standard configuration packages such as exim4 or postfix. (I think the default is now postfix but it certainly used to be exim4.) During installation you'll be asked for the scenario you require, and one of the options will either match you requirements or get very close: "Locally generated mail to local users is forwarded to some ...


1

The links below provides all the MTA choices you can choose, according to your Ubuntu version: MTA - Ubuntu 12.04 MTA - Ubuntu 14.04 You can also check the Archwiki page on Setting up ssmtp to use port 25. SSMTP and MSMTP still are not full fledged MTA's. This unix.se provides details for a comprehensive lists of MTA's available and they as well are ...


Only top voted, non community-wiki answers of a minimum length are eligible