Email - Mailbox

About

A mailbox is a file where the emails message are stored.

It can be real or virtual.

Management

Modification

Remotely (POP, IMAP)

You can modify a remote mailbox via the remote protocol POP and IMAP

FetchMail can also retrieve the email via POP and IMAP and stores them locally

Locally

You can modify local mail box With mail client utility

Example on how to to delete the mail 1 to 15 with mailx

mail
d 1-15
quit

Linux

Path

The default in post fix is /var/mail or /var/spool/mail. See postconf.5.html

sudo ls /var/mail
  • Two mailbox
root  user

Set the path with the MAIL environment variable

The MAIL environment variable set the path of the mailbox.

Example:

MAIL=/var/spool/mail/nico

Content

UNIX mailboxes: A mailbox file is just a collection of text mail separated by --multipart-boundary--

(See also Mbox format (JavaMail can read them))

Example:

--multipart-boundary--

From [email protected]  Wed Jun 10 03:10:08 2020
Return-Path: <[email protected]>
Received: from example.com (localhost [127.0.0.1])
	by example.com (8.14.7/8.14.7) with ESMTP id 05A1A7A9005523
	for <[email protected]>; Wed, 10 Jun 2020 03:10:07 +0200
Received: (from root@localhost)
	by example.com (8.14.7/8.14.7/Submit) id 05A1A7dG005522
	for root; Wed, 10 Jun 2020 03:10:07 +0200
Date: Wed, 10 Jun 2020 03:10:07 +0200
Message-Id: <[email protected]>
From: Anacron <[email protected]>
To: [email protected]
Content-Type: text/plain; charset="UTF-8"
Subject: Anacron job 'cron.daily' on example.com

/etc/cron.daily/logrotate:

error: skipping "/var/log/php-fpm/error.log" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" directive in config file to tell logrotate which user/group should be used for rotation.
error: skipping "/var/log/php-fpm/www-error.log" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" directive in config file to tell logrotate which user/group should be used for rotation.






Discover More
Email - Mille and one way to send an email (professional and user)

This article shows you Mille and one way to send an email. submission port Before continuing, you need to know the basics of email and how it works with SMTP. If you don't check this page: . Advanced...
Email - Monitoring

Email monitoring is done by sending an email and looking up the mailbox. Example: Mail exporter prometheus
Email - mail delivery agent (MDA | LDA)

A mail delivery agent (MDA) is a SMTP server that is responsible for the local delivery of e-mail messages to a local recipient's mailbox It's also known as: message delivery agent (MDA) or local...
Email - on Linux

Linux runs a “locally configured” mailer daemon that doesn't route messages by default through the Internet but only copies messages to other users spool directories It is real SMTP-compliant email,...
Email server - The server that sends, received and process email

What is an SMTP server and how to implement it
How does the email system work? SMTP, POP, IMAP explained

This page gives you the foundations of the email system. At the end, you should be able to understand why when you configure your email client, you need to set up: The SMTP configuration And the...
POP3 and IMAP

pop3 and imap are email protocol used to connect to a remote mailbox (ie a remote server). You can then read, delete your email An Email Client (MUA) may use them to read/delete email remotely ...
The receiving part of the SMTP protocol: when you want to receive email

SMTP has two sides, sending and receiving, this article is all about how to receive
Gmail Show Original Email
What is a Email Message ? known as Internet Message or RFC822

An email is a document that is composed of the following structure * one or more headers * followed at the end by a body that may be composed of multiparts It's a network message known as: * MimeMessage *...



Share this page:
Follow us:
Task Runner