Bug 478375 - Cannot update database with digikam mysql executables. Brew mysql executables work partially.
Summary: Cannot update database with digikam mysql executables. Brew mysql executables...
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Applications
Component: Database-Mysql (show other bugs)
Version: 8.2.0
Platform: macOS (DMG) macOS
: NOR normal
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-12-10 22:38 UTC by Robert Garrigós
Modified: 2024-05-29 18:08 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In: 8.4.0
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Robert Garrigós 2023-12-10 22:38:26 UTC
SUMMARY
Cannot update database if I use the digikam mysql executables. If I use the brew mysql executables, I cannot create new tags because of an "unexpected error".


STEPS TO REPRODUCE
1. open digikam after upgrade
2. digikam mysql executables not working.

OBSERVED RESULT
this is the error shown (in Catalan):
No s'ha pogut actualitzar la base de dades.<p>Executable: /Applications/digiKam.org/digikam.app/Contents/lib/mariadb/bin/mysql_upgrade</p><p>Arguments: --socket=/Users/robert/Library/Application Support/digikam/digikam/db_misc/mysql.socket</p><p>Error del procés: Error desconegut</p

EXPECTED RESULT


SOFTWARE/OS VERSIONS
macOS: 14.1


ADDITIONAL INFORMATION

I updated digikam to the latest versions. I had set the internal mysql server in my previous version. Now, it keeps saying that the internal server cannot be started. I'm using mysql installed by brew, not the one that comes with the macosx system. If I set the mysql executables to the ones that come with brew (except mysql_install_db, which is missing in brew), digikam opens with my previous database, __but cannot add any tag__.

If I use the executables that come with digikam, it complains that it cannot start the internal server. Besides, any time I open the internal mysql server configuration window, even if I had already selected the brew executables before, I have to look for them again, as digikam doesn't remember my previous setting.
Comment 1 Maik Qualmann 2023-12-11 06:53:44 UTC
If mysql_install_db is missing, you are probably using Oracle MySQL. You cannot mix MariaDB (shipped with digiKam) with Oracle MySQL. The database is probably defective now. We only support MariaDB for the internal server. Oracle MySQL can also be used for an external server.
You have to start with a new database.

Maik
Comment 2 Robert Garrigós 2023-12-11 11:31:26 UTC
Understood. However, trying to config an external mysql server gives me this error:

L'error és: Authentication plugin 'caching_sha2_password' cannot be loaded: dlopen(/opt/digikam.org.x86_64/lib/mariadb/plugin/caching_sha2_password.so, 0x0002): tried: '/opt/digikam.org.x86_64/lib/mariadb/plugin/caching_sha2_password.so' (no such file), '/System/Volumes/Preboot/Cryptexes/OS/opt/digikam.org.x86_64/lib/mariadb/plugin/caching_sha2_password.so' (no such file), '/opt/digikam.org.x86_64/lib/mariadb/plugin/caching_sha2_password.so' (no such file) QMYSQL: No s'ha pogut connectar
Comment 3 Maik Qualmann 2023-12-11 12:30:55 UTC
This is related to this Bug 474472. We have to deactivate the SHA2 password for the internal server.

Maik
Comment 4 Maik Qualmann 2023-12-11 19:58:47 UTC
Git commit 263e4c2bcd2a7da41c8a7ae31d2b02d5fd0be025 by Maik Qualmann.
Committed on 11/12/2023 at 20:57.
Pushed by mqualmann into branch 'master'.

for internal MySQL only MariaDB supported

M  +4    -37   core/libs/database/engine/dbengineparameters.cpp

https://invent.kde.org/graphics/digikam/-/commit/263e4c2bcd2a7da41c8a7ae31d2b02d5fd0be025
Comment 5 Maik Qualmann 2023-12-11 20:17:25 UTC
Git commit 15a9beb0da4d6dd57862101cf1126bc7a058350a by Maik Qualmann.
Committed on 11/12/2023 at 21:15.
Pushed by mqualmann into branch 'master'.

disable SHA2 password for the internat MySQL server
Related: bug 474472

M  +1    -1    NEWS
M  +6    -1    core/data/database/mysql-global.conf

https://invent.kde.org/graphics/digikam/-/commit/15a9beb0da4d6dd57862101cf1126bc7a058350a