All writing

Sending Email from non-email Ubuntu Server

I have a couple of scripts that use the linux “mail” command to send results of cron jobs, backups, and such. The problem is I don’t want to setup more overhead than I need, nor do I want to setup non-secure services. So after asking the guys on the #uphpu channel, they recommended postfix. So for a Ubuntu 10.04 server, just run the following commands:

aptitude install postfix #when prompted, select Internet Site aptitude install mailutils

Then bingo, the mail command should work. You can test it by doing:

mail justin@example.com

It will ask for any Cc addresses, and a subject. Then, type your message, and when you are done hit “Ctrl-D” for done.

Sheet
A-3 · Detail
Drawn
Utah
Scale
1:1
Rev
2026