Bug 517251 - MariaSQL Migration
Summary: MariaSQL Migration
Status: RESOLVED NOT A BUG
Alias: None
Product: digikam
Classification: Applications
Component: Database-Migration (other bugs)
Version First Reported In: 9.0.0
Platform: Microsoft Windows Microsoft Windows
: NOR wishlist
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2026-03-07 18:36 UTC by Andy
Modified: 2026-03-07 21:31 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed/Implemented In: 9.1.0
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Andy 2026-03-07 18:36:36 UTC
Hi!

I've been experimenting a bit.
I wanted to set up a MariaDB database on my Synology NAS again (without Docker).

DigiKam's migration process includes an SQL example under "Prerequisites" showing how to create the user and database in phpMyAdmin. The hostname of the SQL server is simply copied from the previous tab.
CREATE USER 'digikam'@'synology' IDENTIFIED BY 'password';
GRANT ALL ON *.* TO 'digikam'@'synology' IDENTIFIED BY 'password';
CREATE DATABASE `digikam`;
GRANT ALL PRIVILEGES ON `digikam`.* TO 'digikam'@'synology';
FLUSH PRIVILEGES;

Unfortunately, this doesn't work in my case, as it only allows local access to the database from the Synology NAS. To allow external connections, a % symbol needs to be used.

Here's the SQL command that appears when I create it manually.
CREATE USER 'digikam'@'%' IDENTIFIED BY 'password';GRANT ALL PRIVILEGES ON *.* TO 'digikam'@'%' REQUIRE NONE WITH MAX_QUERIES_PER_HOUR 0 MAX_CONNECTIONS_PER_HOUR 0 MAX_UPDATES_PER_HOUR 0 MAX_USER_CONNECTIONS 0;CREATE DATABASE IF NOT EXISTS `digikam`;GRANT ALL PRIVILEGES ON `digikam`.* TO 'digikam'@'%';

Should this be noted in the description in the migration window?

Andy
Comment 1 Maik Qualmann 2026-03-07 20:35:52 UTC
Not really, it's just a suggestion; there are many ways to access a MySQL server. The % sign is a wildcard for any connection. And it shouldn't be used for security reasons, though it might be okay for a home user. You could also use the IP address.

Only use MySQL if you plan to use digiKam on multiple computers.
SQLite on an SSD is faster, fully supports UTF-8, etc., and is easier for the user to manage.

A NAS is not often a good MySQL server because it performs resource management and allocates limited storage and performance to services.

Maik
Comment 2 Andy 2026-03-07 20:50:18 UTC
I also tried using the IP address. That didn't work either. I only managed to access the database successfully using %.

I'm aware of the speed reduction. The local SQLite database is really very fast.

The migration is also very slow. I hope it will be finished by tomorrow morning. 96,000 files

Andy
Comment 3 Maik Qualmann 2026-03-07 21:10:51 UTC
If the migration takes this long, something is wrong with your configuration.

Maik
Comment 4 Andy 2026-03-07 21:31:37 UTC
Everything's fine :-)

I've already tried so many settings to speed up the MySQL server. I haven't found any good settings from other users online yet. Maybe I'll still find the perfect combination.

Oh look! The % symbol for the remote MySQL server is also mentioned in the "docs.digikam.org".

Andy