clpctl db:import fails when using mariadb 11.4 #124

Closed
opened 2026-04-05 20:25:31 +02:00 by MrUnknownDE · 0 comments
Owner

Originally created by @arnelap on 2/13/2025

CloudPanel version(s) affected

v2.5.0

Description

clpctl db:import --databaseName=thedatabase --file=import.sql.zip

Command " : /usr/bin/sudo /usr/bin/setfacl -m u:www-data:--- /usr/bin/sh;/usr/bin/sudo chown www-data:www-data '/tmp/.xxxxxxxxxx;/usr/bin/sudo /bin/bash -c "/usr/bin/cat '/home/xxxxx/import.sql.zip'" | /usr/bin/sudo -u www-data /bin/bash -c "/usr/bin/mysql --defaults-extra-file='/tmp/.xxxxx' -f -h'127.0.0.1' -u'root' -P'3306' 'thedatabase'"" failed, error message: /usr/bin/mysql: Deprecated program name. It will be removed in a future release, use '/usr/bin/mariadb' instead

ERROR: ASCII '\0' appeared in the statement, but this is not allowed unless option --binary-mode is enabled and mysql is run in non-interactive mode. Set --binary-mode to 1 if ASCII '\0' is expected. Query: 'PK'.
/usr/bin/cat: write error: Broken pipe

Operating System
Ubuntu 24.04

How to reproduce

Install CloudPanel with latest MariaDB 11.4

curl -sS https://installer.cloudpanel.io/ce/v2/install.sh -o install.sh;
echo "a3ba69a8102345127b4ae0e28cfe89daca675cbc63cd39225133cdd2fa02ad36 install.sh" |
sha256sum -c && sudo CLOUD=hetzner DB_ENGINE=MARIADB_11.4 bash install.sh

create a site
create a database for the site
login to ssh and run clpctl db:import --databaseName=... --file=...

Possible Solution

change command to use /usr/bin/mariadb ?

Additional Context

No response

*Originally created by @arnelap on 2/13/2025* ### CloudPanel version(s) affected v2.5.0 ### Description clpctl db:import --databaseName=thedatabase --file=import.sql.zip Command " : /usr/bin/sudo /usr/bin/setfacl -m u:www-data:--- /usr/bin/sh;/usr/bin/sudo chown www-data:www-data '/tmp/.xxxxxxxxxx;/usr/bin/sudo /bin/bash -c "/usr/bin/cat '/home/xxxxx/import.sql.zip'" | /usr/bin/sudo -u www-data /bin/bash -c "/usr/bin/mysql --defaults-extra-file='/tmp/.xxxxx' -f -h'127.0.0.1' -u'root' -P'3306' 'thedatabase'"" failed, error message: /usr/bin/mysql: Deprecated program name. It will be removed in a future release, use '/usr/bin/mariadb' instead ERROR: ASCII '\0' appeared in the statement, but this is not allowed unless option --binary-mode is enabled and mysql is run in non-interactive mode. Set --binary-mode to 1 if ASCII '\0' is expected. Query: 'PK'. /usr/bin/cat: write error: Broken pipe Operating System Ubuntu 24.04 ### How to reproduce Install CloudPanel with latest MariaDB 11.4 curl -sS https://installer.cloudpanel.io/ce/v2/install.sh -o install.sh; \ echo "a3ba69a8102345127b4ae0e28cfe89daca675cbc63cd39225133cdd2fa02ad36 install.sh" | \ sha256sum -c && sudo CLOUD=hetzner DB_ENGINE=MARIADB_11.4 bash install.sh create a site create a database for the site login to ssh and run clpctl db:import --databaseName=... --file=... ### Possible Solution change command to use /usr/bin/mariadb ? ### Additional Context _No response_
Sign in to join this conversation.