[Digikam-devel] [digikam] [Bug 337737] New: Settings and installation windows freeze when valid mariadb/mysql db connection is available

Christian buitk14 at A1.net
Wed Jul 23 19:41:02 BST 2014


https://bugs.kde.org/show_bug.cgi?id=337737

            Bug ID: 337737
           Summary: Settings and installation windows freeze when valid
                    mariadb/mysql db connection is available
           Product: digikam
           Version: 4.1.0
          Platform: openSUSE RPMs
                OS: Linux
            Status: UNCONFIRMED
          Severity: grave
          Priority: NOR
         Component: setup
          Assignee: digikam-devel at kde.org
          Reporter: buitk14 at A1.net

Symptom:
'''''''''
The digikam 4.x settings window and the collection setup window at installation
will freeze after apr. 3 seconds once a mariadb/mysql connection was setup
successfully with latest mariadb and mysql libs (at least in OpenSuse 12.3 and
13.1. - dont know about other distros)

Installed 64Bit Libraries:
''''''''''''''''''''''''''
digikam 4.1.0-11.8
kipi-plugins 4.1.0-11.8
kipi-plugins-lang 4.1.0-11.8
libgkgeomap-lang 4.1.0-11.8
libkipi11 4.11.5-298.1
mariadb 5.5.33-2.2
mariadb-client 5.5.33-2.2
libmysql18 5.5.33-2.2
libmysqlclient18 5.5.33-2.2
libqt4-sql-mysql
libmysqlcppconn 1.1.2-4.1.3
ibvsqlitepp 0.3.12-7.7

and more ...

from Standard OpenSuse 13.1 Repositorys and from:
http://download.opensuse.org/repositories/KDE:/Current/openSUSE_13.1/ 
http://download.opensuse.org/repositories/KDE:/Extra/KDE_Current_openSUSE_13.1/
http://download.opensuse.org/repositories/server:/database/openSUSE_13.1/ (only
for ibvsqlitepp 0.3.12-7.7) 

Rating of the Bug:

This bug is severe, because it blocks installation of digikam on top of a MySQl
database. MySQL is a must for large asset collections - so digikam 4.* cannot
be used for semiprofessional workflows (at least using OpenSuse).

The installation is blocked, because the wizard opens the collections setup
window once a mysql database was set up successfully. The collections setup
window will freeze after apr. 3 seconds. If you are quick enough you can finish
the setup - see 'workarounds" later on.

Analysis:

The freeze is not restricted to db settings and collections settings, any tab
of the settings windows will freeze after 3 seconds, once mysql was set up
successfully. There are workarounds to change settings without that windows -
see below.

-------------------------------------------------
Reproducable - see attachments:
-------------------------------------------------

1. Install OpenSuse 13.1 from online repository.
-------------------------------------------------

The latest digikam 4.1.0 build right now ist 11.8 for KDE 4.13, but the bug
blocks any 4.* release of digikam for OpenSuse.

2. Create user "benutzer1" in OpenSuse and login
-------------------------------------------------

Copy some images to folder /home/benutzer1/.

3. Test setup files in attachment, create MysqlDB :
-------------------------------------------------

a. settings-file "digikamrc_settingswork"
**********************************************

These are default settings, with the sqlite db in /home/benutzer1/. 

Rename the file to "digikamrc" and copy it to /home/benutzer1/.kde4/share/
Start digikam and everything works fine. Check the "settings"-window: it does
not freeze.

b. settings-file "digikamrc_settingsdonotwork"
**********************************************

This is exactly the same settings file - but the section [Database Settings]
was replaced with a connection to a valid mysql database "digikamdb" for user
"digikamuser" with password "**". A short description of mariadb/mysql setup is
given below.

Create the mysql db and user as described in the next section.
Rename the file to "digikamrc" and copy it to /home/benutzer1/.kde4/share/

Start digikam and the freeze of the "settings"-windows will block your further
installation when you are asked to define the filepath to the main collection.
Note: If you receive database errors, the db was not set up in the right way -
in this case the window might or might not freeze.

The settings-window will also freeze when you setup the database settings and
collections with the workarounds I will describe later on. You have to chance
all settings in the "digikamrc"file using a text editor (not that bad ...)

4. Set up mariadb/mysql for the test:
-------------------------------------------------

 a. set mariadb/mysql root password - it is empty

 #Check if service is running:
 >systemctl status  mysql.service
 # open mysql client on the console:
 >mysql --host=127.0.0.1 --user=root --port=3306

 and type:

use mysql;set password for root at localhost = password('rootpw');
flush privileges;

 b. change mariadb configuration for digikam before creating databases

  Adapt /etc/my.cnf  BEFORE you create the databases for digikam:

  [mysqld]
  ...
  innodb_file_per_table=ON

  Find a line that reads "log_bin" and remove or comment it as follows:
  #log_bin = ...
  # binlog_format=mixed

 c. restart mysql db, check server status and open mysql console:

   >systemctl restart mysql.service
   >systemctl status  mysql.service
   >mysql --host=127.0.0.1 --user=root --password=rootpw --port=3306

  On the mysql prompt type:

CREATE DATABASE digikamdb;GRANT ALL PRIVILEGES ON digikamdb.* TO   
'digikamuser'@'localhost' IDENTIFIED BY '**'; FLUSH PRIVILEGES;
GRANT SUPER ON *.* TO 'digikamuser'@'localhost'; FLUSH PRIVILEGES;


-------------------------------------------------
5. Workaround for this bug till there is a fix:
-------------------------------------------------

This bug should not stop you working with digikam and mysql to manage a large
collection of media assets (that would kill Adobe Lightroom.)

After opening the window with digikam settings the digikam GUI will freeze
under KDE 4.* within 3 seconds after a mysql connection was setup successfully.
Without a valid mysql conncetion digikam settings window will NOT freeze.

Workaround to set default collection:
 There is no freeze of the settings windows at the first start.
 Choose any folder with no images, because it will be changed again.
 Then open Settings Windows and Select "MySQL" in the database section.

Workaround to set first mysql database settings and collection:  
  Dialog will not freeze during database setup, it will freeze later
  on when the collection path is chosen: Set default path before you
  start digikam in ~/.kde4/share/config/digikamrc:
   change section "[KFileDialog Settings]" Recent URLs, Recent Files
  Then be quick, just press return to select this path.

Workaround to add one ore more collections to the database:

Use mysql console or workbench to add new rows in table 'AlbumRoots':

USE digikamdb;
INSERT INTO `AlbumRoots`
(`id`,`label`,`status`,`type`,`identifier`,`specificPath`) VALUES
(1,'multimedia_fotosdb1',0,1,'volumeid:?uuid=d3b29d62-d3d8-48ca-8499-b9631abeee11','/home/your_filepath1');
INSERT INTO `AlbumRoots`
(`id`,`label`,`status`,`type`,`identifier`,`specificPath`) VALUES
(2,'multimedia_fotosdb2',0,1,'volumeid:?uuid=5656c923-dab2-4ccd-b6bf-8590a23d9338','/home/your_filepath2');

Workaround: to change mysql database settings, edit section in
~/.kde4/share/config/digikamrc

[Database Settings]
Database Connectoptions=
Database Hostname=localhost
Database Name=digikamdb
Database Name Thumbnails=digikamdb
Database Password=**
Database Port=3306
Database Type=QMYSQL
Database Username=digikamuser
Internal Database Server=false

Workaround: to change other settings, edit the relate section in
~/.kde4/share/config/digikamrc

Example for Color Profiles:
...

[Color Management]
BPCAlgorithm=true
DefaultMismatchBehavior=1048576
DefaultMissingProfileBehavior=1048576
DefaultPath=/knowhow/consulting_framework/02_projects_local/08_ci_layout_design/0000_buitk_designvorgaben/farbmanagement_linux
DefaultUncalibratedBehavior=1048576
DoGamutCheck=0
EnableCM=true
GamutCheckMaskColor=126,255,255
InProfileFile[$e]=/usr/share/color/icc/Argyll/lab2lab.icm
LastMismatchBehavior=2049
LastMissingProfileBehavior=2050
LastSpecifiedAssignProfile=
LastSpecifiedInputProfile=
LastUncalibratedBehavior=2080
ManagedPreviews=true
ManagedView=true
ProofingRenderingIntent=3
RenderingIntent=0
WorkProfileFile[$e]=/usr/share/color/icc/Adobe ICC Profiles/RGB
Profiles/AdobeRGB1998.icc

-- 
You are receiving this mail because:
You are the assignee for the bug.



More information about the Digikam-devel mailing list