Mailserver installation

Hello to all
I wanted to install a mail server following this wiki page: https://wiki.ipfire.org/addons/mailserver
But I can’t find the required mysql package in pakfire!
Yes I’m aware that you shouldn’t install a mailserver in a firewall, but I just wanted to test this!
Regards
Markus

have a look at “gocart’s” work https://forum.ipfire.org/viewtopic.php?f=17&t=15328#p92212 in the old forum unfortunately only in german

automatic translation:

Mail server for IPFire with Roundcube Dovecot and Postfixadmin
This is an independent extension for IPFire. The mail server works so far and is constantly being developed. It uses Postfix as MTA and Amavsid and Spamassassin for mail filtering. Roundcube is used as frontend (website) and MariaDB as database server. For administration Postfixadmin is used (creating domains and mailboxes). This mail server is multi-domain as well as domain and mailbox quota capable. Mailbox rules (Sieve / Pigonhole) are supported. Apache 2.4 is HTTP2 capable.
Minimum system requirements:
Min 2GB Ram better 3 to 4GB
Min 4GB space for mails in /var partition (depending on estimated mailbox and mail volume also much more)
No SD card system! Even if that would work in principle. Intel i586 or x64 system. ARM systems are not supported even if there is IPFire for ARM. It might be useful to run this mail server in a separate VM or installation, since it scales quite well due to the software components used. (can manage more than just three mailboxes)
Installation:
The installation is done via a command line installer. Before installing the mail server components, this installer will necessarily update PHP to version 7.2 and Perl to 5.28 with the complete module package available in IPFire. (most of it newer anyway) If you don’t want to install the mail server, you can’t. These updates are no official IPFire updates! There is the possibility to cancel the installation with “CTRL+C” at this point.
With the Perl update the installation of Perl modules from the Pakfire is ineffective. All necessary modules and all modules from the Pakfire are included in this package. The mysql will be replaced by MariaDB 10.2.x if not installed. InnoDB is the default DB engine. It is always recommended to uninstall the old MySQL first! The DB directory is moved from /srv/mysql to /var/mysql if MariaDB is used. The IPfire partition is simply too small with 2GB.
The necessary setup steps in the firewall are identical to the mail proxy. Port 25 to the outside (send and receive mail), for Razor2 port 2703 to the outside and if Roundcube should go on the internet then of course port 443. Sometimes ClamAV takes forever to activate its signatures. It is better to install it manually before.
Please follow the instructions in the installer end text, as final setup steps are necessary. Have fun testing and I am looking forward to any constructive feedback. It should also be mentioned again that all this is under development, but as far as I have tested it works without problems.
usage:
After creating the domains and the mailboxes with Postfixadmin you can call Roundcube with https:// [IPfire IP address] and login. In the Dovecot configuration POP3 and IMAP are enabled (with TLS). So the mail server can also be used normally with e.g. Outlook and Thunderbird. (Roundcube also uses IMAP to access Dovecot) The login data is the same as for Roundcube. Do not forget the firewall adjustments for POP3/S and IMAP/S.
Attention:
Updating this mail server is always done by updating the installer. Currently only outdated packages are provided via Pakfire. If the old Postfix and Amavisd are installed from Pakfire, the configuration of the mail server installation will be destroyed. However, this can be easily repaired by running the installer again completely. This mail server has also nothing to do with the Cyrus-IMAP based mail server from the IPFire Wiki. It is a completely independent project!
development log:
2019-11-17 Version 26 Installation from Core 135
Changes:

  • PHP 7.3.12
  • postfix 3.4.7
  • roundcube 1.3.10
  • dovecot 2.3.8
  • dehydrated 0.6.5
    Plus a nice letsencrypt script. Remains after the installation under /var/tmp…
    Port 80 has to be released as webserver for the key chellenge to the outside.
    28.06.2019 Version 25 Installation from Core 133
    Changes:
  • PHP 7.3.6
  • postfix 3.4.5
  • roundcube 1.3.9
  • dovecot 2.3.6
    The Postfix configuration is identical to the Mail Gateway and Heinlein-support SA databases,
    Regex filter lists and the other changes to the main.cf
    viewtopic.php?f=17&t=17360&p=101233#p101233

Before the update please check if “mysql -u root” can be started without errors!
If not, the MariaDB update will fail! A backup of the SQL databases is created.

  • Installation *
    Connect to IPfire via ssh or putty and copy the following skipt or text to /tmp or /var/tmp in a file named install.sh Make the file executable with chmod +x install.sh and start it.
    The start script for the installation: Mail server for IPFire with Roundcube Dovecot and Postfixadmin
    This is an independent extension for IPFire. The mail server works so far and is constantly being developed. It uses Postfix as MTA and Amavsid and Spamassassin for mail filtering. Roundcube is used as frontend (website) and MariaDB as database server. For administration Postfixadmin is used (creating domains and mailboxes). This mail server is multi-domain as well as domain and mailbox quota capable. Mailbox rules (Sieve / Pigonhole) are supported. Apache 2.4 is HTTP2 capable.
    Minimum system requirements:
    Min 2GB Ram better 3 to 4GB
    Min 4GB space for mails in /var partition (depending on estimated mailbox and mail volume also much more)
    No SD card system! Even if that would work in principle. Intel i586 or x64 system. ARM systems are not supported even if there is IPFire for ARM. It might be useful to run this mail server in a separate VM or installation, since it scales quite well due to the software components used. (can manage more than just three mailboxes)
    Installation:
    The installation is done via a command line installer. Before installing the mail server components, this installer will necessarily update PHP to version 7.2 and Perl to 5.28 with the complete module package available in IPFire. (most of it newer anyway) If you don’t want to install the mail server, you can’t. These updates are no official IPFire updates! There is the possibility to cancel the installation with “CTRL+C” at this point.
    With the Perl update the installation of Perl modules from the Pakfire is ineffective. All necessary modules and all modules from the Pakfire are included in this package. The mysql will be replaced by MariaDB 10.2.x if not installed. InnoDB is the default DB engine. It is always recommended to uninstall the old MySQL first! The DB directory is moved from /srv/mysql to /var/mysql if MariaDB is used. The IPfire partition is simply too small with 2GB.
    The necessary setup steps in the firewall are identical to the mail proxy. Port 25 to the outside (send and receive mail), for Razor2 port 2703 to the outside and if Roundcube should go on the internet then of course port 443. Sometimes ClamAV takes forever to activate its signatures. It is better to install it manually before.
    Please follow the instructions in the installer end text, as final setup steps are necessary. Have fun testing and I am looking forward to any constructive feedback. It should also be mentioned again that all this is under development, but as far as I have tested it works without problems.
    usage:
    After creating the domains and the mailboxes with Postfixadmin you can call Roundcube with https:// [IPfire IP address] and login. In the Dovecot configuration POP3 and IMAP are enabled (with TLS). So the mail server can also be used normally with e.g. Outlook and Thunderbird. (Roundcube also uses IMAP to access Dovecot) The login data is the same as for Roundcube. Do not forget the firewall adjustments for POP3/S and IMAP/S.
    Attention:
    Updating this mail server is always done by updating the installer. Currently only outdated packages are provided via Pakfire. If the old Postfix and Amavisd are installed from Pakfire, the configuration of the mail server installation will be destroyed. However, this can be easily repaired by running the installer again completely. This mail server has also nothing to do with the Cyrus-IMAP based mail server from the IPFire Wiki. It is a completely independent project!
    development log:
    2019-11-17 Version 26 Installation from Core 135
    Changes:
  • PHP 7.3.12
  • postfix 3.4.7
  • roundcube 1.3.10
  • dovecot 2.3.8
  • dehydrated 0.6.5
    Plus a nice letsencrypt script. Remains after the installation under /var/tmp…
    Port 80 has to be released as webserver for the key chellenge to the outside.
    28.06.2019 Version 25 Installation from Core 133
    Changes:
  • PHP 7.3.6
  • postfix 3.4.5
  • roundcube 1.3.9
  • dovecot 2.3.6
    The Postfix configuration is identical to the Mail Gateway and Heinlein-support SA databases,
    Regex filter lists and the other changes to the main.cf
    viewtopic.php?f=17&t=17360&p=101233#p101233

Before the update please check if “mysql -u root” can be started without errors!
If not, the MariaDB update will fail! A backup of the SQL databases is created.

  • Installation *
    Connect to IPfire via ssh or putty and copy the following skipt or text to /tmp or /var/tmp in a file named install.sh Make the file executable with chmod +x install.sh and start it.
    The start script for the installation: http://people.ipfire.org/~mlorenz/ms/install.txt
1 Like

Thanks @anon65703081
I tried this and didn’t get it to work! Mostly due to not be able to ask questions because the forum is locked
But thanks for your answer

I absolutely would not recommend to install any software on your firewall from random sources on the Internet that cannot be updated any more.

If you want to run a fully-fledged email server on IPFire, I would recommend installing it in a virtual machine. Preferably you would use extra hardware for it.

1 Like

@ms I totally agree! My intention was running the mailserver on a second machine running ipfire! Ich chose ipfire because so I only have to get used to one linux distribution!
My first test was getting mail with fetchmail and giving them to cyrus (both from the pakfire repository) but I couldn’t figure out how to do this! Sending would be done by the clients directly with the mailserver from my homepage provider.
I hope that was understandable, english is not my native language :slight_smile: