Home » Mail Server
Tech Hacks and Solutions

Financial Technology Consulting, Statistics, Risk Models and Economics.

Mail Server
Advantages and difficulties of running an own mail server with an overview on related articles, scripts and utilities.

Technology Hacks and Solutions

Birthday Reminders from your Linux Server
Perl script sending birthday reminder emails from you Linux server using an Excel CSV file as birthday database.
Virtual Server Basic Setup for Email Service
Picking an operating system, dual IPv4 and IPv6 network interfaces, hostname and reverse DNS record for virtual server email setup.
Restore Hostname During Reboot
A custom system service to restore hostname settings during reboot on virtual servers overwriting network configuration files.

Mail Server

With Linux V-Server offers for under 5€ per month, running an own email server has become very affordable. If you own domain names, you might even decide to set up a virtual server for complete self-hosting. Typically, this includes domain name service, a web server and the topic of this section, an option to send and receive emails.

Linux V-Server running Ubuntu with Postifx processes
Linux V-Server running Ubuntu with Postfix mailer daemon processes

Why Run an Own Mail Server?

An own mail server allows you to have the name of your business in the domain part of your email address. For example, with an own mail server a company “Oh So Good Cake Inc” could use email addresses like “[email protected]”. Without, its email address might read like “[email protected]”. The second case, using the email service of some big internet company, has several downsides:

  • Big internet company in your email address and on business cards looks like you can’t afford quality IT services. You’ll advertise for them.
  • Big email providers sometimes promise 100% spam-free inboxes with a significant rate of legitimate messages ending up in the spam folder or worse, outright rejected.
  • A single mailbox for the company will be difficult to share between employees or functions like sales or service.
  • Changing providers you’ll have a hard time transferring contents of mail folders.

Looks of your email address aside, using the services of Big Internet Company you transfer ownership of essential business data to a third party. In all probability your emails will be scanned, which is a privacy issue. Expect Big Internet Company to place targeted ads relating to your mails.

Why not Use a Web Hosting Provider?

But why not just register your business name with a web hosting provider and use their mail service? On the upside, you get professional looking emails. Also, small hosting providers are less likely to evaluate your mails for personalized ads. However, you still put a third party in charge of your data. And consider the following new problems:

  • Hosting companies may sell your email addresses to online marketers and spammers. Check the small print of your hosting contract!
  • You risk down-time when changing hosting providers.
  • Hosting companies often require transferring domain registration to them. This is like handing the keys of your house to your plumber. Best to keep domain registrar, where you hold the keys, and hosting company or cloud service separate.
  • You may not want to trust small hosting providers with highly confidential business data.

How to Run an Own Mail Server

Mail server administration is relatively complex because software components from multiple sources need to be configured to work together. Furthermore, settings need to be right or outgoing emails may be flagged as spam. For good acceptance of your messages, your V-Server and mailer setup need to support the following:

  • static IPv4 and IPv6 addresses.
  • an open outgoing SMTP port 25.
  • an administrative function to specify a reverse DNS record.
  • a sender policy framework (SPF) DNS record.
  • a Domain-based Message Authentication Reporting and Conformance (DMARC) DNS record.
  • DomainKeys Identified Mail (DKIM) signatures, verification and respective DNS records.
  • TLS/SSL encryption for mail clients connecting to your server.

If your budget is small and you don’t want to afford an expensive IT service, these pages are for you. With a basic grasp of Unix / Debian Linux administration, you can successfully run your own server and gain valuable tech skills on the way.

Aside of features for acceptance of outgoing mail, your server should meet your privacy requirements. Since V-Server directories are mounted on the host computers’ file system, your email files will be accessible by the virtualization software. Therefore, you might consider more expensive dedicated servers or a private network with in-house servers. However, since virtually all external email traffic is unencrypted, a simple V-Server will suffice for most.

Mail Server Setup Steps

I hope the following explanations and instructions will be helpful setting up a Postfix mail server with Courier Imap, virtual mail boxes and DKIM signatures on Ubuntu or Debian servers.

V-Server Basic Installation for Mail Service

Some explanations on server installation, firewall, dual IPv4 and IPv6 network activation, reverse DNS records and hostname setup.

Related Articles

Friends upset about your forgetfulness on important birthdays? Receive birthday reminder emails from your Linux server or desktop.