Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reopen: Sync with multiple Mailboxes in Outlook Cause App Crash (Z-Push/ActiveSync) #1205

Open
gmcpaul opened this issue Nov 21, 2024 · 9 comments

Comments

@gmcpaul
Copy link

gmcpaul commented Nov 21, 2024

Hi,
sorry to create a new case with this but i am still having trouble with keeping Outlook/Activesync stable when syncing multiple (large ~5-20gb) Mailboxes for an User.

*) I have updated the Outlook versions to current releases not older than Office 2019
*) I have uninstalled and reinstalled the Office edt with Office Scrub, so i can ensure the Versions are as clean as possible

Still i get the same error with them:

Office Sync works a few Days and all of a sudden the Outlook app disappears.
In the Applog of WIndows i can find that pstprx32.dll caused the App to crash.

All that helps is to close Outlook and delete the OST files and let it resync ... which works for a random number up to about 3 days.

Since then i work within the Webclient, which is a cool feature but i really want to get Outlook going
Android Sync is working fine by the way

please maybe you can put me on track how to further debug the problem, it must be something on the serverside which culprits the datastream and causes it to fail

thanks
paul

@gmcpaul
Copy link
Author

gmcpaul commented Nov 28, 2024

Ok i tried with one smaller Mailbox, which worked for a week now.
But when i add a few more the same problem reappeared.

So i assume that the zpush component is somehow on its limits.
Are there some recommondations or experiences with that issue?

By the way the server was migrated from kopano so the activesync worked there with the very same load and mailboxes.

@lonesomewalker
Copy link

Without further details about your environment... :-)

I have servers running with mailboxes over 15GB.
Sometimes they have to be deleted, because there is a loop detected and the resync takes too long.

So, what is your environment?

@gmcpaul
Copy link
Author

gmcpaul commented Dec 2, 2024

@lonesomewalker
Thanks for your reply.
OS is Ubuntu 24.04 LTS (upgraded from 20.04) (Mysql, Apache, Php8.3)

I tried to stick to the manual from the Groupoffice Site, the only difference is that the mailboxes, as well as the groupoffice files are located on another Partition within the /home/ structure (has historic reasons).

I migrated from Kopano to GroupOffice via Imapsync within this system.
So basically i kept the Kopano Install up, installed Groupoffice besides and synced all Mailboxes to GroupOffice/Dovecot, removed Kopano and its Addons..then Upgraded to os 22.04
There are is one Mailboxes, which are larger than 12Gib; others have basically not more than 1.5Gb each; which worked within the Kopano Solution flawlessly.

when i reset the ost files or delete the appdata office folder, where the ost files resist, the sync starts and works for a few days but then crashes and it results in the pstprx32.dll crash error.
so we tried to only sync one mailbox, which only widens the timespan before the outlook app crashes but it does.

i mean im aware that sometimes Outlook Ost files get bad but not all few 2-3 days.
personally i think that something is wrong within the z-push env but i cant seem to find the problem, also whith the debug switch turned on i do not really find a clue why this happens.

/etc/groupoffice/config.php

<?php

$config['db_name'] = 'groupoffice';
$config['db_host'] = 'localhost';
$config['db_user'] = 'groupoffice';
$config['db_pass'] = 'xxx';
$config['db_port'] = '3306';
$config['file_storage_path'] = '/home/groupoffice/groupoffice';
$config['vmail_path'] = '/home/groupoffice/mailboxes/vmail';
$config['post_max_size'] = '1G';
$config['tmpdir'] = '/tmp/groupoffice';
$config['debug'] = 'true';

/etc/groupoffice/globalconfig.inc.php

<?php
$config = [
        // GO will connect to this installation to add a mailbox. It is the full url to the Group-Office installation with the postfixadmin module installed.
        'serverclient_server_url' => 'http://localhost/groupoffice/',
        // A token to authenticate. The token has to be identical on the web and mail server. By default they are the same server so you can just set anything here.

        'serverclient_token' => '123',

        // Comma separated list of mailbox domains
        'serverclient_domains' => 'dom1.org,dom2.org,dom3.org',

        // The email account properties that will be added for the user
        'serverclient_mbroot' => '',
        'serverclient_use_ssl' => false,
        'serverclient_use_tls' => false,
        'serverclient_novalidate_cert' => '0',
        'serverclient_host' => 'localhost',
        'serverclient_port' => 143,
        'serverclient_smtp_host' => 'localhost',
        'serverclient_smtp_port' => 25,
        'serverclient_smtp_encryption' =>'',
        'serverclient_smtp_username' => '',
        'serverclient_smtp_password' => ''
];

apache, default.conf

<VirtualHost *:80>
    ServerName mail.dom1.org
    ServerAlias webmail.dom1.org
    RewriteEngine On
    RewriteRule ^/$ https://webmail.dom1.org/groupoffice [R=301,L]
</VirtualHost>

<VirtualHost *:443>
    ServerAdmin [email protected]
    ServerName mail.dom1.org
    ServerAlias webmail.dom1.org
    DocumentRoot /var/www/html
    SSLEngine on
    SSLCertificateFile /etc/letsencrypt/live/mail.dom1.org/cert.pem
    SSLCertificateKeyFile /etc/letsencrypt/live/mail.dom1.org/privkey.pem

    ErrorLog ${APACHE_LOG_DIR}/error.log
    CustomLog ${APACHE_LOG_DIR}/access.log combined
    Options FollowSymLinks
    RewriteEngine On
    RewriteRule ^/$ https://webmail.dom1.org/groupoffice [R=301,L]

ProxyPreserveHost       On
ProxyRequests           Off

SSLProxyVerify          None
SSLProxyCheckPeerCN     Off
SSLProxyCheckPeerName   Off
SSLProxyCheckPeerExpire Off

ProxyPass        /cp/          http://127.0.0.1:9090/cp/        upgrade=websocket
ProxyPassReverse /cp/          http://127.0.0.1:9090/cp/

</VirtualHost>

if you need some of the config details, please let me know.
i would be glad if the problem could be solved in time
<3

@lonesomewalker
Copy link

Okay...
You know that sync has a separate logfile on the server... what does this say?
Also, is the same mailbox synced to more than one user?

And, i can't see the htaccess/redirects for ms paths in your config :)

@gmcpaul
Copy link
Author

gmcpaul commented Dec 3, 2024

HI @lonesomewalker ,

so in regards of the redirects, im using the default groupoffice.conf file enabled in /etc/apache/enabled-configs:

Define GROUPOFFICE_PATH /usr/share/groupoffice

#Main web applications
Alias /groupoffice ${GROUPOFFICE_PATH}

#For site manager
Alias /public ${GROUPOFFICE_PATH}/public.php

Alias /Microsoft-Server-ActiveSync ${GROUPOFFICE_PATH}/modules/z-push/index.php

#For CalDAV support
Alias /caldav ${GROUPOFFICE_PATH}/modules/caldav/calendar.php

#For CardDAV support
Alias /carddav ${GROUPOFFICE_PATH}/modules/carddav/addressbook.php

#For WebDAV support
Alias /webdav ${GROUPOFFICE_PATH}/modules/dav/files.php

#For WOPI support
Alias /wopi ${GROUPOFFICE_PATH}/go/modules/business/wopi/wopi.php

#For Google Oauth2 support
Alias /gauth ${GROUPOFFICE_PATH}/go/modules/community/googleoauth2/gauth.php

#For OnlyOffice support
Alias /onlyoffice ${GROUPOFFICE_PATH}/go/modules/business/onlyoffice/connector.php

#DAV Service discovery. At least required for iOS7 support
Redirect 301 /.well-known/carddav /carddav
Redirect 301 /.well-known/caldav /caldav

#openID service discovery
Alias /.well-known/openid-configuration ${GROUPOFFICE_PATH}/api/oauth.php/.well-known/openid-configuration


#autoconfig
Alias /mail/config-v1.1.xml ${GROUPOFFICE_PATH}/go/modules/community/autoconfig/autoconfig.php
Alias /v1.1/mail/config-v1.1.xml ${GROUPOFFICE_PATH}/go/modules/community/autoconfig/autoconfig.php
Alias /.well-known/autoconfig/mail/config-v1.1.xml ${GROUPOFFICE_PATH}/go/modules/community/autoconfig/autoconfig.php

#autodiscover
Alias /autodiscover/autodiscover.json ${GROUPOFFICE_PATH}/go/modules/community/autoconfig/autodiscover-json.php
Alias /Autodiscover/Autodiscover.xml ${GROUPOFFICE_PATH}/go/modules/community/autoconfig/autodiscover.php
Alias /autodiscover/autodiscover.xml ${GROUPOFFICE_PATH}/go/modules/community/autoconfig/autodiscover.php

<Directory ${GROUPOFFICE_PATH}>
        Options -Indexes +FollowSymLinks
        AllowOverride None
        Require all granted
</Directory>

# Optionally disallow /install. Upgrade via command line only.
#<Directory ${GROUPOFFICE_PATH}/install>
#               Require local
#</Directory>

when parsing the z-push.log, i find:

a few of these
09/11/2024 10:04:22 [210324] [ERROR] [[email protected]] ImportChangesCombined->Config() icc not configured

that user seems to have a problem with auth on on of his devices (had to delete him anyway)

14/11/2024 21:23:50 [2445955] [ERROR] [[email protected]] Failed to recreate mime source. Falling back to original mime. Subject: asdf samples Exception: Invalid address: (From):user1
14/11/2024 21:23:50 [2445955] [WARN] [[email protected]] SyncObject->Check(): object from type SyncMail: parameter 'from' contains an invalid email address 'user1'. Address is removed.
30/10/2024 17:54:31 [485724] [WARN] [[email protected]] Not possible to determine class of request. Request did not contain class and apparently there is an issue with the HierarchyCache.

so not really anything which points to zpush problems rather than encoding issues

@lonesomewalker
Copy link

Looks normal...
What does your php.ini say about limits?

As you wrote, the z-push.log seems to be normal.
Either there might be ressource limits on your server, or... Outlook s*cks (the same way as Thunderbird does...)

@gmcpaul
Copy link
Author

gmcpaul commented Dec 3, 2024

Hi, so these are the current php memory limits:

php limit :
apache/php.ini
memory_limit = 512M

cli/php.ini
memory_limit = 256M

fpm/php.ini
memory_limit = 1G

please tell me if you want to know other values there... or how to check if these get exhausted

many thanks und vielen dank

@lonesomewalker
Copy link

Erm...
You should only have 2 relevant php.ini
One for CLI and one EITHER apache2 or fpm.
So, what are you running? fpm or mod_php?

@gmcpaul
Copy link
Author

gmcpaul commented Dec 4, 2024

hi,
this is the conf enabled
it seems i the fpm was disabled tho... so i reenabled it ... maybe that came from messin around with that system..

lrwxrwxrwx 1 root root   30 Jun 29  2021 charset.conf -> ../conf-available/charset.conf
lrwxrwxrwx 1 root root   34 Dec  2 15:07 groupoffice.conf -> ../conf-available/groupoffice.conf
lrwxrwxrwx 1 root root   40 Sep 29 18:11 javascript-common.conf -> ../conf-available/javascript-common.conf
lrwxrwxrwx 1 root root   44 Jun 29  2021 localized-error-pages.conf -> ../conf-available/localized-error-pages.conf
lrwxrwxrwx 1 root root   46 Jun 29  2021 other-vhosts-access-log.conf -> ../conf-available/other-vhosts-access-log.conf
lrwxrwxrwx 1 root root   33 Dec  4 15:15 php8.3-fpm.conf -> ../conf-available/php8.3-fpm.conf
lrwxrwxrwx 1 root root   29 Sep 29 11:46 rspamd.conf -> ../conf-available/rspamd.conf
lrwxrwxrwx 1 root root   31 Jun 29  2021 security.conf -> ../conf-available/security.conf
lrwxrwxrwx 1 root root   36 Jun 29  2021 serve-cgi-bin.conf -> ../conf-available/serve-cgi-bin.conf

and the mods

lrwxrwxrwx 1 root root   36 Jun 29  2021 access_compat.load -> ../mods-available/access_compat.load
lrwxrwxrwx 1 root root   28 Jun 29  2021 alias.conf -> ../mods-available/alias.conf
lrwxrwxrwx 1 root root   28 Jun 29  2021 alias.load -> ../mods-available/alias.load
lrwxrwxrwx 1 root root   33 Jun 29  2021 auth_basic.load -> ../mods-available/auth_basic.load
lrwxrwxrwx 1 root root   33 Jun 29  2021 authn_core.load -> ../mods-available/authn_core.load
lrwxrwxrwx 1 root root   33 Jun 29  2021 authn_file.load -> ../mods-available/authn_file.load
lrwxrwxrwx 1 root root   33 Jun 29  2021 authz_core.load -> ../mods-available/authz_core.load
lrwxrwxrwx 1 root root   33 Jun 29  2021 authz_host.load -> ../mods-available/authz_host.load
lrwxrwxrwx 1 root root   33 Jun 29  2021 authz_user.load -> ../mods-available/authz_user.load
lrwxrwxrwx 1 root root   32 Jun 29  2021 autoindex.conf -> ../mods-available/autoindex.conf
lrwxrwxrwx 1 root root   32 Jun 29  2021 autoindex.load -> ../mods-available/autoindex.load
lrwxrwxrwx 1 root root   30 Jun 29  2021 deflate.conf -> ../mods-available/deflate.conf
lrwxrwxrwx 1 root root   30 Jun 29  2021 deflate.load -> ../mods-available/deflate.load
lrwxrwxrwx 1 root root   26 Jun 29  2021 dir.conf -> ../mods-available/dir.conf
lrwxrwxrwx 1 root root   26 Jun 29  2021 dir.load -> ../mods-available/dir.load
lrwxrwxrwx 1 root root   26 Jun 29  2021 env.load -> ../mods-available/env.load
lrwxrwxrwx 1 root root   30 Jun 30  2021 expires.load -> ../mods-available/expires.load
lrwxrwxrwx 1 root root   29 Jun 29  2021 filter.load -> ../mods-available/filter.load
lrwxrwxrwx 1 root root   30 Jun 30  2021 headers.load -> ../mods-available/headers.load
lrwxrwxrwx 1 root root   27 Jun 29  2021 mime.conf -> ../mods-available/mime.conf
lrwxrwxrwx 1 root root   27 Jun 29  2021 mime.load -> ../mods-available/mime.load
lrwxrwxrwx 1 root root   34 Jun 29  2021 mpm_prefork.conf -> ../mods-available/mpm_prefork.conf
lrwxrwxrwx 1 root root   34 Jun 29  2021 mpm_prefork.load -> ../mods-available/mpm_prefork.load
lrwxrwxrwx 1 root root   34 Jun 29  2021 negotiation.conf -> ../mods-available/negotiation.conf
lrwxrwxrwx 1 root root   34 Jun 29  2021 negotiation.load -> ../mods-available/negotiation.load
lrwxrwxrwx 1 root root   29 Sep 30 21:27 php8.3.conf -> ../mods-available/php8.3.conf
lrwxrwxrwx 1 root root   29 Sep 30 21:27 php8.3.load -> ../mods-available/php8.3.load
lrwxrwxrwx 1 root root   28 Jul 17  2021 proxy.conf -> ../mods-available/proxy.conf
lrwxrwxrwx 1 root root   33 Dec  4 15:17 proxy_fcgi.load -> ../mods-available/proxy_fcgi.load
lrwxrwxrwx 1 root root   33 Jul 17  2021 proxy_http.load -> ../mods-available/proxy_http.load
lrwxrwxrwx 1 root root   28 Jul 17  2021 proxy.load -> ../mods-available/proxy.load
lrwxrwxrwx 1 root root   37 Oct  3 14:53 proxy_wstunnel.load -> ../mods-available/proxy_wstunnel.load
lrwxrwxrwx 1 root root   30 Jun 30  2021 rewrite.load -> ../mods-available/rewrite.load
lrwxrwxrwx 1 root root   31 Jun 29  2021 setenvif.conf -> ../mods-available/setenvif.conf
lrwxrwxrwx 1 root root   31 Jun 29  2021 setenvif.load -> ../mods-available/setenvif.load
lrwxrwxrwx 1 root root   36 Jun 30  2021 socache_shmcb.load -> ../mods-available/socache_shmcb.load
lrwxrwxrwx 1 root root   26 Jun 30  2021 ssl.conf -> ../mods-available/ssl.conf
lrwxrwxrwx 1 root root   26 Jun 30  2021 ssl.load -> ../mods-available/ssl.load
lrwxrwxrwx 1 root root   29 Jun 29  2021 status.conf -> ../mods-available/status.conf
lrwxrwxrwx 1 root root   29 Jun 29  2021 status.load -> ../mods-available/status.load

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants