1 (edited by Nuraeil 2015-05-21 20:27:12)

Topic: Installation on Banana Pi

==== Required information ====
- iRedMail version: ///
- Store mail accounts in which backend (LDAP/MySQL/PGSQL):  ///
- Web server (Apache or Nginx): Apache
- Linux/BSD distribution name and version: Bananian
- Related log if you're reporting an issue:  ///
====

Hello iRedMail Support/Forum,

first off this is my first post on this board and I also used Google to search for an answer, but I didn't find one.

I found out about iRedMail because I got stuck with manually installing a mail server. When I tried installing it on my Banana Pi with Bananian as a OS I get the error:

Your architecture is not supported yet: armv7l.
Both i386 and x86_64 are supported by iRedMail.

I read somewhere that the ARM architecture is supported.

Does this mean that generally I cannot install it on a Banana Pi or does that mean that I have to install a other OS for it to work and if so, what OS would you suggest?

Best regards

Yannick/Nuraeil

----

Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.

2

Re: Installation on Banana Pi

Try this patch for iRedMail-0.9.1:

diff -r a093829b7eb2 iRedMail/conf/global
--- a/iRedMail/conf/global    Thu May 21 16:14:04 2015 +0800
+++ b/iRedMail/conf/global    Thu May 21 20:46:55 2015 +0800
@@ -202,7 +202,7 @@
 case $arch in
     i[3456]86) export OS_ARCH='i386' ;;
     x86_64|amd64) export OS_ARCH='x86_64' ;;
-    armv6l|arm7l)
+    armv6l|arm7l|armv7l)
         # Debian ARM platform and Raspberry Pi.
         export OS_ARCH='armhf' ;;
     *)

3 (edited by Nuraeil 2015-05-21 21:41:56)

Re: Installation on Banana Pi

In which file should I put that?

€: My bad, I'm blind...

4

Re: Installation on Banana Pi

OK, looks like you're not familiar with patch. Let's explain:

*) Open file iRedMail-0.9.1/conf/global, find below line:

    armv6l|arm7l)

*) Update above line to below one:

    armv6l|arm7l|armv7l)

*) Save your change and quit text editor.

Now run iRedMail installer again:

# bash iRedMail.sh

5 (edited by Nuraeil 2015-05-21 21:59:19)

Re: Installation on Banana Pi

Sorry, I was blind. I'm currently also working on setting up aFirefox Sync Server as well but because I'm at work (internship) I can't check if that works and was trying around and somewhat overread the path to the where I should change it...

The installer is running now, will comment if anything happens.

6 (edited by Nuraeil 2015-05-21 22:51:33)

Re: Installation on Banana Pi

Okay, it works.

But I've got a question.. now my mail has an mx before the Domain, is it possible to change that?

It also sends no emails...

€: Need to check some stuff.

€: Okay, can't receive nor send mails currently and I've got no idea where to set up the MX/etc. stuff.. On my server or my Domain provider?

It also Redirects to me Mailbox instantly when I open my homepage. How can I change that?

€: Also can't seem to Access /iredadmin even though it is installed.

Sorry to bother you so much with this but never installed a mail server before and the tutorials I found weren't helping me.

€: Can I change the URL from mx.WEBSITE/Folder for mail and ireadmin to WEBSITE/Folder for mail and ireadmin ? Because I can't access it otherwise

7

Re: Installation on Banana Pi

Nuraeil wrote:

€: Okay, can't receive nor send mails currently and I've got no idea where to set up the MX/etc. stuff.. On my server or my Domain provider?

Your DNS service provider.

Nuraeil wrote:

It also Redirects to me Mailbox instantly when I open my homepage. How can I change that?

i suppose Banana Pi runs Debian, right? if so, you can move /var/www/index.html (or /var/www/html/index.html). Web files are stored under /var/www/ (or /var/www/html/) on Debian by default.

Nuraeil wrote:

€: Also can't seem to Access /iredadmin even though it is installed.

Any error message in Apache log file (/var/log/apache2/error_log) or uwsgi log file (/var/log/uwsgi/*) if you run Nginx as web server)?

Nuraeil wrote:

€: Can I change the URL from mx.WEBSITE/Folder for mail and ireadmin to WEBSITE/Folder for mail and ireadmin ? Because I can't access it otherwise

Then please point DNS A record of WEBSITE domain to this server, and use WEBSITE domain name as a virtual web host (or an alias name of existing web host.)

8 (edited by Nuraeil 2015-05-21 23:38:11)

Re: Installation on Banana Pi

1. My DNS service provider is no-ip.org and my domain is hosted at strato. I have two websites with which I can access my page.

2. Fixed it.

3. Reason I can't access it is because it runs on mx.DOMAIN/iredadmin and I don't have a sub domain which I should need, correct me if I'm wrong.

4. My domain at strato points to my external IP which redirects all requests on the ports to my Banana Pi. Same goes for no-ip.

This is my current hosts:

127.0.0.1    mx.DOMAIN mx localhost localhost.localdomain

and this my current hostname:

mx

Is there an error already ? Or should I point it to DOMAIN/mx or my INTERNAL-IP/mx ? If so I'll re-install the system and start anew.

So, to summarize the A-Adress of my domain is my external Adress and I've got the options to set a MX, SPF/TXT and SRV-Record.

Really sorry to bother you such much with it but I'm really new to this sad

9

Re: Installation on Banana Pi

Another question is, do i need a subdomain registered at my provider?

10

Re: Installation on Banana Pi

Okay, I re-installed everything.

I can access all pages but I keep getting this error when sending test mails:

<postmaster@*******>: Host or domain name not found. Name service error for
    name=mail.*******.** type=A: Host found but no data record of requested type

11 (edited by Nuraeil 2015-05-22 05:19:36)

Re: Installation on Banana Pi

Other update, only getting a error message from hotmail:

host mx2.hotmail.com[65.55.33.135] said: 550 OU-002
    (COL004-MC6F7) Unfortunately, messages from***.***.***.*** weren't sent.
    Please contact your Internet service provider since part of their network
    is on our block list. You can also refer your provider to
    http://mail.live.com/mail/troubleshooting.aspx#errors. (in reply to MAIL
    FROM command)

What do I need to change so that my emails get delivered and also received faster?

€: Gonna contact my hoster to get the Reverse DNS set-up, hopefully it'll fix the issue that I'm not receiving mails.

€2: Will I need to contact my ISP or my domain hoster for this due? Or is there another method to get the mails delivered?

12

Re: Installation on Banana Pi

Nuraeil wrote:

Other update, only getting a error message from hotmail:

host mx2.hotmail.com[65.55.33.135] said: 550 OU-002
    (COL004-MC6F7) Unfortunately, messages from***.***.***.*** weren't sent.
    Please contact your Internet service provider since part of their network
    is on our block list. You can also refer your provider to
    http://mail.live.com/mail/troubleshooting.aspx#errors. (in reply to MAIL
    FROM command)

It's clear that your IP address is blocked by Outlook. Please open the link and read carefully.

Also check your IP address with http://mxtoolbox.com/ make sure your server ip address is not blocked by DNSBL services.

By the way, you run Banana Pi, i guess your server is using a dynamic IP address, right? if so, you should consider using a static IP address, because too many mail servers block emails sent from dynamic IP address.

13 (edited by Nuraeil 2015-05-22 15:00:16)

Re: Installation on Banana Pi

The issue there is, that my IP changes after a long period of time (once a month, even less frequently,never checked that). And because of my ISP I'd need to be registered as a business person to get a static IP and as it seems also to the get a Reverse DNS. Will still get into contact them to see if it's possible even for a privat person.

And for the test, these are the error reports:

smtp ****.**    Reverse DNS does not match SMTP Banner
blacklist    ******.**    Blacklisted by Spamhaus ZEN

And the internal IP is the same, always. The outside IP is the same for all of my devices.

€: fixed some spelling mistakes.

14

Re: Installation on Banana Pi

Nuraeil - they don't track your IP through changes, basically - big Mail Service Companies like Hotmail get huge lists of Dynamic IPs from the ISPs, and if your IP is within one of the ranges they just simply treat it as Spam or even Reject it. You could look into getting a Smarthost or a VPS or something else than Business Broarband, as that will most likely cost more.

15 (edited by Nuraeil 2015-05-22 15:48:10)

Re: Installation on Banana Pi

Orignally I wanted to get away from having to host everything on a provider and go to having everything installed locally and configurable to my desires.

I had a VPS before but paying 10€ and more per month isn't really what I want because I have a Banana Pi, why not use it?

And what do you exactly mean with the Smarthost?

Will see what my ISP says concering static IP and Reverse DNS and if it's not possible then we'll see what I'll do.

Would it be possible if I had the option to set-up a Reverse DNS in my provider settings where I have my domain?

16

Re: Installation on Banana Pi

Nuraeil wrote:

blacklist    ******.**    Blacklisted by Spamhaus ZEN

Spamhaus is used by many many mail servers, you should request to remove your IP from its web site: http://spamhaus.org/

17 (edited by Nuraeil 2015-05-22 16:16:17)

Re: Installation on Banana Pi

ZhangHuangbin wrote:
Nuraeil wrote:

blacklist    ******.**    Blacklisted by Spamhaus ZEN

Spamhaus is used by many many mail servers, you should request to remove your IP from its web site: http://spamhaus.org/

You should only remove an IP address from the PBL if (A) the IP address is Static and has proper Reverse DNS assigned to your mail server, and (B) if you have a specific technical reason for needing to run a 'direct-to-MX' email service, such as a mail server appliance, off the Static IP address. In all other cases you should NOT remove an IP address from the PBL.

The DNS is probably not static and has no proper Reverse DNS assigned as far as I know. So using that wouldn't do anything, would it?

I'm going to put the things I asked in my last post here in again:

And what do you exactly mean with the Smarthost?

Would it be possible if I had the option to set-up a Reverse DNS in my provider settings where I have my domain?

18 (edited by Nuraeil 2015-05-22 18:48:37)

Re: Installation on Banana Pi

Okay, I unblocked it and it is still not sending messages...

I even activated the Relay using this guide: http://www.gtkdb.de/index_36_2312.html (it is German) the second method with multiple servers/hosts ( gmail,hotmail, t-online...)

Should I post any config files?

I also tried using this: http://seasonofcode.com/posts/setting-u … stfix.html

Didn't work either and the second thing blocked every incoming mail.

19

Re: Installation on Banana Pi

# See /usr/share/postfix/main.cf.dist for a commented, more complete version


# Debian specific:  Specifying a file name will cause the first
# line of that file to be used as the name.  The Debian default
# is /etc/mailname.
#myorigin = /etc/mailname

smtpd_banner = $myhostname ESMTP $mail_name (Debian/GNU)
biff = no

# appending .domain is the MUA's job.
append_dot_mydomain = no

# Uncomment the next line to generate "delayed mail" warnings
#delay_warning_time = 4h

readme_directory = no

# TLS parameters
smtpd_tls_cert_file = /etc/ssl/certs/iRedMail.crt
smtpd_tls_key_file = /etc/ssl/private/iRedMail.key
smtpd_use_tls=yes
smtpd_tls_session_cache_database = btree:${data_directory}/smtpd_scache
smtp_tls_session_cache_database = btree:${data_directory}/smtp_scache

# See /usr/share/doc/postfix/TLS_README.gz in the postfix-doc package for
# information on enabling SSL in the smtp client.

myhostname = mail.****.**
alias_maps = hash:/etc/postfix/aliases
alias_database = hash:/etc/postfix/aliases
myorigin = mail.****.**
mydestination = $myhostname, localhost, localhost.localdomain
relayhost =
mynetworks = 127.0.0.1
mailbox_size_limit = 0
recipient_delimiter = +
inet_interfaces = all
inet_protocols = ipv4
virtual_alias_domains =
mydomain = mail.****.**
allow_percent_hack = no
swap_bangpath = no
mynetworks_style = host
smtpd_data_restrictions = reject_unauth_pipelining
smtpd_reject_unlisted_recipient = yes
smtpd_reject_unlisted_sender = yes
smtpd_tls_protocols = !SSLv2 !SSLv3
smtp_tls_protocols = !SSLv2 !SSLv3
lmtp_tls_protocols = !SSLv2 !SSLv3
smtpd_tls_mandatory_protocols = !SSLv2 !SSLv3
smtp_tls_mandatory_protocols = !SSLv2 !SSLv3
lmtp_tls_mandatory_protocols = !SSLv2 !SSLv3
smtp_tls_security_level = may
smtp_tls_CAfile = $smtpd_tls_CAfile
smtp_tls_loglevel = 0
smtp_tls_note_starttls_offer = yes
smtpd_sender_restrictions = reject_unknown_sender_domain, reject_non_fqdn_sender, reject_unlisted_sender, permit_mynetworks, reject_sender_login_mismatch, permit_sasl_authenticated
delay_warning_time = 0h
maximal_queue_lifetime = 4h
bounce_queue_lifetime = 4h
proxy_read_maps = $canonical_maps $lmtp_generic_maps $local_recipient_maps $mydestination $mynetworks $recipient_bcc_maps $recipient_canonical_maps $relay_domains $relay_recipient_maps $relocated_maps $sender_bcc_maps $sender_canonical_maps $smtp_generic_maps $smtpd_sender_login_maps $transport_maps $virtual_alias_domains $virtual_alias_maps $virtual_mailbox_domains $virtual_mailbox_maps $smtpd_sender_restrictions
smtp_data_init_timeout = 240s
smtp_data_xfer_timeout = 600s
smtpd_helo_required = yes
smtpd_helo_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_non_fqdn_helo_hostname, reject_invalid_helo_hostname, check_helo_access pcre:/etc/postfix/helo_access.pcre
queue_run_delay = 300s
minimal_backoff_time = 300s
maximal_backoff_time = 4000s
enable_original_recipient = no
disable_vrfy_command = yes
home_mailbox = Maildir/
allow_min_user = no
message_size_limit = 15728640
virtual_minimum_uid = 2000
virtual_uid_maps = static:2000
virtual_gid_maps = static:2000
virtual_mailbox_base = /var/vmail
transport_maps = proxy:mysql:/etc/postfix/mysql/transport_maps_user.cf, proxy:mysql:/etc/postfix/mysql/transport_maps_domain.cf
virtual_mailbox_domains = proxy:mysql:/etc/postfix/mysql/virtual_mailbox_domains.cf
virtual_mailbox_maps = proxy:mysql:/etc/postfix/mysql/virtual_mailbox_maps.cf
virtual_alias_maps = proxy:mysql:/etc/postfix/mysql/virtual_alias_maps.cf, proxy:mysql:/etc/postfix/mysql/domain_alias_maps.cf, proxy:mysql:/etc/postfix/mysql/catchall_maps.cf, proxy:mysql:/etc/postfix/mysql/domain_alias_catchall_maps.cf
sender_bcc_maps = proxy:mysql:/etc/postfix/mysql/sender_bcc_maps_user.cf, proxy:mysql:/etc/postfix/mysql/sender_bcc_maps_domain.cf
recipient_bcc_maps = proxy:mysql:/etc/postfix/mysql/recipient_bcc_maps_user.cf, proxy:mysql:/etc/postfix/mysql/recipient_bcc_maps_domain.cf
relay_domains = $mydestination, proxy:mysql:/etc/postfix/mysql/relay_domains.cf
smtpd_sender_login_maps = proxy:mysql:/etc/postfix/mysql/sender_login_maps.cf
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain =
broken_sasl_auth_clients = yes
smtpd_sasl_security_options = noanonymous
smtpd_tls_auth_only = yes
smtpd_recipient_restrictions = reject_unknown_recipient_domain, reject_non_fqdn_recipient, reject_unlisted_recipient, check_policy_service inet:127.0.0.1:7777, check_policy_service inet:127.0.0.1:10031, permit_mynetworks, permit_sasl_authenticated, reject_unauth_destination
smtpd_end_of_data_restrictions = check_policy_service inet:127.0.0.1:7777, check_policy_service inet:127.0.0.1:10031,
smtpd_tls_security_level = may
smtpd_tls_loglevel = 0
smtpd_tls_CAfile = /etc/ssl/certs/iRedMail.crt
tls_random_source = dev:/dev/urandom
mailbox_command = /usr/lib/dovecot/deliver
virtual_transport = dovecot
dovecot_destination_recipient_limit = 1
smtpd_sasl_type = dovecot
smtpd_sasl_path = private/dovecot-auth
content_filter = smtp-amavis:[127.0.0.1]:10024
smtp-amavis_destination_recipient_limit = 1
sender_canonical_maps = hash:/etc/postfix/sender_canonical
smtp_sasl_auth_enable = yes
smtp_sasl_security_options = noanonymous
smtp_connection_cache_on_demand = no
smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd
smtp_sender_dependent_authentication = yes
sender_dependent_relayhost_maps = hash:/etc/postfix/sender_dependent_relayhost

20

Re: Installation on Banana Pi

*) If you cannot send email, please check Postfix log file. You can find log file in this tutorial:
http://www.iredmail.org/docs/file.locat … ml#postfix

*) Why do you enable relay? what is it used for in your case?

21

Re: Installation on Banana Pi

ZhangHuangbin wrote:

*) If you cannot send email, please check Postfix log file. You can find log file in this tutorial:
http://www.iredmail.org/docs/file.locat … ml#postfix

*) Why do you enable relay? what is it used for in your case?

Hey,

t3chguy helped me with the issue. And I can't send mails directly due to me having a dynamic IP and also not having a Reverse DNS so he suggested using a Relay Server, which is now working and I can send mails through my server currently with another mail but that will be changed soon as well.

22

Re: Installation on Banana Pi

You can get around having a dynamic ip address by using a DDNS (dynamic dns) service like dyndns.com. I did this for a number of years before migrating to a vps with a static ip address. I can personally recommend Dyndns, but there are other services. Just bear in mind that you may be violating your ISP's terms of service by running a mail server, so this advice comes with the usual caveat emptor (let the buyer beware)

23

Re: Installation on Banana Pi

iperkins wrote:

You can get around having a dynamic ip address by using a DDNS (dynamic dns) service like dyndns.com. I did this for a number of years before migrating to a vps with a static ip address. I can personally recommend Dyndns, but there are other services. Just bear in mind that you may be violating your ISP's terms of service by running a mail server, so this advice comes with the usual caveat emptor (let the buyer beware)

Currently I'm more then open for suggestions...

Because apparently I can only have a nameserver on my subdomains and have no idea how to set cloudflare up to use the subdomain....

24 (edited by camel1cz 2015-05-23 21:39:19)

Re: Installation on Banana Pi

- I don't think running mailserver on arm is good idea,
- I don't think running mailserver for single domain and few emails per day is a good idea,
- I don't think running mailserver on personal grade  Internet connection is a good idea,

It's easy to find dozens of reasons for above statements.

If you still want to run your own mailserver, get a vps. There are very cheap ones available. Just Google for it. Else I see it like wasting your time.