How to setup email in Ubuntu Linux

Good day. May I ask how to setup the server to send email? My test server is Ubuntu Linux 20.04 and I have setup Gibbon by installing the softwares below. What other softwares do I need to install and setup so that the Gibbon server can send email? I don't have access to Google G Suite integration but please let me know what other details I need to provide. Thank you

1. apt install apache2 php mariadb-server php-gd php-mysql php-zip php-curl

#unsure about this one because docs said php-gettext but apt's message is this doesn't exist
2. apt install gettext

3. apt install php-pdo

4. apt install unzip

5. apt install php-mbstring php-xml

Comments

  • Hi Richard,

    In order to dispatch your mail, Ubuntu needs to have a mail transfer agent (MTA) installed. Popular MTAs on Ubuntu include Postfix and Sendmail. If you search Google for these, in relation to Ubuntu, you should be able to find instructions on how to proceed.

    With a basic MTA setup I've found that mail is often flagged as spam, impacting on delivery. As such, we tend to use Admin > System Admin > Third Party Settings to enabled SMTP, which passes your mail to a third party server for dispatch. As a Google school, we use our Google-provided SMTP server/account for this...but there are many SMTP servers you could use.

    Hope this helps!

    Ross
  • Thank you Ross. May I ask for follow-on questions:
    1. If we will implement MTA, will that mean the actual mail will reside on our system, so that we will have to assign a computer to be our mail server?

    2. What are your thoughts on postfix and sendmail concerning ease of setup?
  • Hi Richard, no worries.

    1. The mail will reside on your system for as long as it takes to send, and according to whatever retention/logging policy the MTA has. The MTA can run on the same server as the rest of your server stack, so it does not need to be a seperate computer.

    2. I've used sendmail in the past, and it requires very little config. Ubuntu seems to be moving towards postfix as their main MTA, but I've not tried it as we now use a Google SMTP server.

    Cheers,

    Ross
  • Thank you Ross for the information.
Sign In or Register to comment.