1 (edited by aris.dizdarevic 2022-12-30 19:42:59)

Topic: SOGo webmail, exchange problems after SOGo upgrade to 5.7.1 (YTNEF)

====================================
iRedMail 1.4.0
Downloadable installer
CentOS7
MySQL
Nginx
Manage mail accounts with iRedAdmin-Pro? Yes
====================================

This situation is not a problem of iRedMail or iRedAdminPRO, but a problem of outdated YTNEF and LIYBTNEF libraries - SOGo uses ytnef to decrypt winmail.dat TNEF attachments in mail and seems latest compiled version found in EPEL is outdated.

On some occasions sogo-webmail can not show mail - we get "Gateway error". On this occasion sogo-exchange client on mobile phone does not show inbox items any more. The problem is solved when user deletes that mail from inbox.

In /var/log/messages we can see the error:
sogod[13272]: segfault at 56498f326000 ip 00007f8038dc1b6d sp 00007ffe5474e630 error 4 in libytnef.so.0.0.0[7f8038dbf000+7000]

I believe anyone with older versions of SOGo will have similar probles when they do yum upgrade sogo so I'm hoping someone can find out the solution or that my solution is good enough.

Installed version of ytnef in our system is (latest available in EPEL repo and by default installed upon iRedMail installation):
2.6 (epel repo) http://sourceforge.net/projects/ytnef/

I found newer ytnef compiled in SOGo repo:
2.0.0 (SOGo repo) https://github.com/Yeraze/ytnef

Since the author of YTNEF changed versions and no newer compilation resides in EPEL repo I can not upgrade ytnef and libytnef.

I tried different options, but first thing I did:
/etc/yum.repos.d/epel.repo ADDED: exclude=gnustep* ytnef*

1.
yum downgrade ytnef-2.0.0

Transaction check error:
  file /usr/lib64/libytnef.so.0.0.0 from install of ytnef-2.0.0-1.x86_64 conflicts with file from package libytnef-1.5-14.el7.x86_64

2.
yum downgrade --skip-broken ytnef-2.0.0

Transaction check error:
  file /usr/lib64/libytnef.so.0.0.0 from install of ytnef-2.0.0-1.x86_64 conflicts with file from package libytnef-1.5-14.el7.x86_64
 
3.
yumdownloader ytnef-2.0.0
rpm -i ytnef-2.0.0-1.x86_64.rpm

package ytnef-2.6-12.el7.x86_64 (which is newer than ytnef-2.0.0-1.x86_64) is already installed
file /usr/lib64/libytnef.so.0.0.0 from install of ytnef-2.0.0-1.x86_64 conflicts with file from package libytnef-1.5-14.el7.x86_64
file /usr/bin/ytnef from install of ytnef-2.0.0-1.x86_64 conflicts with file from package ytnef-2.6-12.el7.x86_64
file /usr/bin/ytnefprint from install of ytnef-2.0.0-1.x86_64 conflicts with file from package ytnef-2.6-12.el7.x86_64

4. WORKING SOLUTION... But is it the right choice?
yumdownloader ytnef-2.0.0
rpm -i ytnef-2.0.0-1.x86_64.rpm --force

It upgraded and also solved the problem, but looks like there will be YUM warnings regarding duplicate (or manual) installation of YTNEF.

yum list --showduplicate ytnef

Installed Packages
ytnef.x86_64     2.0.0-1           installed
ytnef.x86_64     2.6-12.el7      @epel

Problem solved:
Old system:
[root@****** tmp]# ytnef winmail.dat
Segmentation fault

Upgraded YTNEF (NEW) - no more Segmentation faults:
[root@****** tmp]# ytnef winmail.dat
[root@****** tmp]#

So is there any other better solution and is this option even good one? Any thoughts on this one @ZhangHuangbin?

Thanks,
Aris.

----

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

2

Re: SOGo webmail, exchange problems after SOGo upgrade to 5.7.1 (YTNEF)

CentOS7 isn't supported, only supported releases are:

CentOS Stream 8, 9

Whereas SOGo Groupware is not available on CentOS Stream 9 (at least yet)

Aswell, iRedMail 1.4.0 is a really outdated release

So to your question about better solutions, migrate to a supported distribution and keep your system up to date when there are any new versions available