Z-push error: Call to undefined function mb_detect_encoding()

Hi there,

I’ve setup Kopano Core then added Z-push, but sync is not working.
Looking at the z-push-error.log:

#0 /usr/share/z-push/lib/request/request.php(286): Utils::ConvertAuthorizationToUTF8('test-usr')
#1 /usr/share/z-push/index.php(61): Request::ProcessHeaders()
#2 {main}
  thrown (1)
12/07/2018 22:09:14 [26291] [FATAL] [test-usr] Fatal error: /usr/share/z-push/lib/utils/utils.php:1152 - Uncaught Error: Call to undefined function mb_detect_encoding() in /usr/share/z-push/lib/utils/utils.php:1152
Stack trace:
#0 /usr/share/z-push/lib/request/request.php(286): Utils::ConvertAuthorizationToUTF8('test-usr')
#1 /usr/share/z-push/index.php(61): Request::ProcessHeaders()
#2 {main}
  thrown (1)

Someone got an idea what could be wrong?

Hi @jester,

it seems you are missing the package php-mbstring.

Which version of Univention are you using? is it a fresh install or an upgrade from a previous version? which version of core and z-push are installed?

Without looking into the package dependencies of WebApp my guess would be that installing webapp (which you want to do anyways) will probably pull in this missing dependency of z-push as well.

As z-push is independent of the WebApp, z-push-common should really depend on everything it needs. It already depends on php-soap, so why not add php-mbstring as well?

No, of course it is not dependend on WebApp. but my “sitting at the breakfast table”-guess was that this did not come up before because php-mbstring is also a dependency of webapp and therefore the issue did not yet surface.

In the end this of course needs fixing in Z-Push and a ticket for that has already been created https://jira.z-hub.io/browse/ZP-1447

Hi Felix,
I’m on the latest version UCS (4.3-1) upgraded from 4.2. Fresh Kopano Core 8.6.2.1 install, Z-push 2.4.2. WebApp is installed on an other UCS (4.3.1) server in DMZ.

@jester as Felix has said: install php-mbstring, restart Apache and you should be good to go.

1 Like

Moritz you are to quick :wink:

Yep, for posterity: did a

apt-get install php-mbstring
service apache2 restart

Log looks clean now, sync is working.

Thanx guys!

1 Like
Mastodon