1 (edited by benzis 2015-05-15 22:02:56)

Topic: Update Postfix to 3.0.1

User kysil posted this question a couple of months ago but never got an answer, and the topic is closed (so I can't reply to it).

I am also looking to update the Postfix version included in iRedMail. Specifically, I'm looking for SMTPUTF8 support (as specified in RFC 6531), which is only available starting in v3.

Is there a way to do this?

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

----

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

2

Re: Update Postfix to 3.0.1

You'd have to build Postfix 3 yourself since it is not available in any Trusty Tahr Repos for your Ubuntu version. (This isn't an iRedMail Restriction but one imposed on your system by Ubuntu repo maintainers)

3 (edited by benzis 2015-05-15 22:03:55)

Re: Update Postfix to 3.0.1

Thanks, good to know. Actually, I haven't set anything up yet - I was planning on using Ubuntu because it's the distribution that I'm most familiar with, but Debian or CentOS would equally fit my needs. So I'll just use one of those to make things a tad easier.

(I edited the original post just so that this doesn't become the focus)

4

Re: Update Postfix to 3.0.1

Debian too does not have Postfix 3 in Repos - would require building from sources
http://www.prosinger.net/index.php/upgr … entos-6-x/ gives you enough information on how to build from sources (applies to Postfix 3 also)

5

Re: Update Postfix to 3.0.1

iRedMail tries to use most (binary) packages from software repo provided by Linux/BSD venders, this way we reduce the workload (building/packing/distributing packages) and users get trustable package upgrade from Linux/BSD venders.

So you have to consider building it yourself.

6 (edited by benzis 2015-06-22 18:32:11)

Re: Update Postfix to 3.0.1

I didn't have luck with this so far. If anybody has ideas on how to improve, I'd appreciate it. Here is what I've done to try and upgrade Postfix:

First I download and extract the file within /root:

wget http://de.postfix.org/ftpmirror/officia … 0.1.tar.gz
tar xzf postfix-3.0.1.tar.gz

If I try and go into the postfix-3.0.1 folder now and run 'make upgrade', I get an error that says "Please review the INSTALL instructions first." And so I found a recommendation elsewhere to try this (starting in the root):

sudo apt-get build-dep postfix
cd /root/postfix-3.0.1
make update

Until this point, email works fine. Now I can run the update command from within the postfix-3.0.1 directory:

cd /root/postfix-3.0.1
make upgrade

Once I've done that, however, I can no longer send mail. I can login to Roundcube, but when I try to send mail the error says:

SMTP Error (-1): Connection to server failed.

I've been through various configuration files and I don't see any changes that jump out at me as being the reason why. Any ideas?

7

Re: Update Postfix to 3.0.1

Check the status of your postfix service? If it can't connect to it, it suggests its not running properly.

8

Re: Update Postfix to 3.0.1

Before running the upgrade, when I say "postfix status" this is the response:

postfix/postfix-script: the Postfix mail system is running: PID: 1894

After the upgrade, "postfix status" returns:

postfix: Postfix is running with backwards-compatible default settings
postfix: See http://www.postfix.org/COMPATIBILITY_README.html for details
postfix: To disable backwards compatibility use "postconf compatibility_level=2" and "postfix reload"
postfix/postfix-script: the Postfix mail system is running: PID: 2318

However, when I try to send mail from Roundcube, I now get a different error actually:

SMTP Error (250): Authentication failed.

I tried creating a new user within the iRedMail admin panel, and still get this error.

Up to now is the first problem, but I've discovered a second problem as well. In order to address the backwards compatibility (I don't want that - I need to get full SMTPUTF8 support), I ran the commands recommended by the postfix reply previously:

postconf compatibility_level=2
postfix reload

and the system responds:

postfix: warning: smtputf8_enable is true, but EAI support is not compiled in

A couple of other people had this issue but I don't understand their solutions. I tried installing the libicu-dev package listed on on postfix.org SMTPUTF8_README.html (sudo apt-get install libicu-dev) but that doesn't solve the issue.

So in summary, two issues:
1. After upgrading to postfix-3.0.1, I can login in Roundcube and create new users that can login to Roundcube, but I get an SMTP Authentication Error when attempting to send mail
2. After disabling backwards compatibility, I get an error that EAI support is not compiled in

Any suggestions?

9

Re: Update Postfix to 3.0.1

You'll have to recompile your Postfix 3 with EAI, probably a compilation flag

10

Re: Update Postfix to 3.0.1

That might take care of the second problem, but the first one is more pressing for time time being...

11

Re: Update Postfix to 3.0.1

Did you try to contact Debian/Ubuntu package maintainer to update Postfix?

12

Re: Update Postfix to 3.0.1

Someone actually did submit such a request back in April, and I just backed him up:

https://bugs.debian.org/cgi-bin/bugrepo … bug=783572

I doubt it will be fulfilled in the near future. But in the mean time, do you have any ideas about why I'm getting this Authentication error when I upgrade the package myself? I can use the iRedmail admin panel to create a new user who can login to Roundcube. I assume some link is broken between different databases - is there a way to restore that?

13

Re: Update Postfix to 3.0.1

Try this:

*) List your webmail IP address in Postfix 'debug_peer_list' (main.cf), reload postfix.
*) Send a testing email with webmail again.

Postfix will log debug message, let's see why it failed.

14

Re: Update Postfix to 3.0.1

Thanks for your help. I know it's been a while - I took a break from this project but now I'm coming back to it.

I added the IP address to the debug_peer_list in main.cf but I don't see a log file anywhere. Where is the log file? Or do I have to also specify that within the main.cf, and if so - how?

15

Re: Update Postfix to 3.0.1

Path of Postfix log file:
http://www.iredmail.org/docs/file.locat … ml#postfix

16

Re: Update Postfix to 3.0.1

Here are the lines that are produced each time I try to send a message from Roundcube:

Sep 22 12:05:03 mail postfix/smtpd[2510]: warning: smtputf8_enable is true, but EAI support is not compiled in
Sep 22 12:05:03 mail postfix/proxymap[2511]: warning: smtputf8_enable is true, but EAI support is not compiled in
Sep 22 12:05:03 mail postfix/proxymap[2511]: error: unsupported dictionary type: mysql
Sep 22 12:05:03 mail postfix/smtpd[2510]: warning: smtpd_sasl_auth_enable is true, but SASL support is not compiled in
Sep 22 12:05:03 mail postfix/smtpd[2510]: warning: TLS has been selected, but TLS support is not compiled in
Sep 22 12:05:03 mail postfix/smtpd[2510]: connect from mail.xn--pebalb.com[127.0.0.1]
Sep 22 12:05:03 mail roundcube: ERROR: SMTP server does not support authentication ()
Sep 22 12:05:03 mail postfix/smtpd[2510]: disconnect from mail.xn--pebalb.com[127.0.0.1] ehlo=1 rset=1 quit=1 commands=3
Sep 22 12:05:03 mail roundcube: <2fhkh4ma> SMTP Error: Authentication failure: SMTP server does not support authentication (Code: ) in /opt/www/roundcubemail-1.1.1/program/lib/Roundcube/rcube.php on line 1714 (POST /mail/?_task=mail&_unlock=loading1442937903134&_lang=en_US&_framed=1?_task=mail&_action=send)

17

Re: Update Postfix to 3.0.1

benzis wrote:

Sep 22 12:05:03 mail postfix/smtpd[2510]: warning: smtpd_sasl_auth_enable is true, but SASL support is not compiled in

As you can see here, your Postfix doesn't have SASL support, so no smtp authentication at all. You need to recompile Postfix 3.

18

Re: Update Postfix to 3.0.1

OK great that indeed worked. Thanks. I think that this fixes all of my issues, but in order to fully test it, I need to create a username using international characters.

Question: Is there a way to create a new email (virtual) user from the command line?

I'm fine with punnycode as the domain: if a gmail user sends mail to @פרפר.קום it is automatically converted to @xn--pebalb.xn--9dbq2a, and similarly when gmail receives and email from @xn--pebalb.xn--9dbq2a, it automatically displays it as @פרפר.קום. However, the username is not automatically converted in this way, and therefore I need Postfix to send mail using foreign characters in the username (and similarly, Dovecot should recognize foreign characters in the username). However, I can only type punnycode into the iRedAdmin - which is fine for the domain, but for the username it's not gonna work. So I'd like to give it a shot from the command line.

19

Re: Update Postfix to 3.0.1

benzis wrote:

However, I can only type punnycode into the iRedAdmin - which is fine for the domain, but for the username it's not gonna work.

I will try to reproduce this issue and fix it.

20

Re: Update Postfix to 3.0.1

Did you have any luck with it?
Thanks a bunch.

21

Re: Update Postfix to 3.0.1

Sorry, didn't have time to try it yet.