Unable to start Postfix in Plesk: /usr/sbin/postconf: libmysqlclient.so.18:

Started by senthil, May 10, 2025, 03:29 AM

Previous topic - Next topic

senthil

Symptoms
  • On a RHEL-based Linux server, domain creation in Plesk fails with an error that is similar to the following:
    Nothing of nonexisting mail features are not supported
  • Postfix cannot start due to an error that is similar to the following:
    /usr/sbin/postconf: error while loading shared libraries: libmysqlclient.so.18:
    cannot open shared object file: No such file or directory
  • The plesk repair mail command execution ends with an error that is similar to the following:
    #plesk repair mail
    Repairing the mail server configuration
    Reconfigure all domains and mailboxes? [Y/n]
    Reconfiguring all domains and mailboxes .........................
    ERR [util_exec] proc_close() failed
    ['/usr/local/psa/admin/bin/mchk'] with exit code [1]
    [FAILED]
    - mchk failed: ==> Checking for: mailsrv_conf_init... fail
    Error messages: 0; Warnings: 0; Errors resolved: 0
    exit status 1
  • The postfix check command shows the following error:
    postfix check
    postfix: error while loading shared libraries: libmysqlclient.so.18: cannot
    open shared object file: No such file or directory
  • The libmysqlclient.so.18 package cannot be found:
    rpm -qf /usr/lib64/mysql/libmysqlclient.so.18
    error: file /usr/lib64/mysql/libmysqlclient.so.18: No such file or directory
Cause
The libmysqlclient.so.18 package is missing on the server (which can sometimes happen due to a
MySQL/MariaDB version upgrade).

Resolution
1. Connect to the server via SSH

2. Install the missing package manually:
#yum install mysqlclient18-compat --enablerepo=mysqclient
3. Update the package version for Plesk:
#plesk sbin packagemng -sdf