Bug 440458

Summary: Failed to update database
Product: [Applications] digikam Reporter: Dave <compdave7681>
Component: Database-MysqlAssignee: Digikam Developers <digikam-bugs-null>
Status: RESOLVED WORKSFORME    
Severity: normal CC: metzpinguin
Priority: NOR    
Version: 7.3.0   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In: 7.4.0
Sentry Crash Report:

Description Dave 2021-07-31 19:15:21 UTC
SUMMARY


STEPS TO REPRODUCE
1. Download appimage
2. Run
3. Fail to update database
4. Either update user privilege or add "log_bin_trust_function_creators = 1" in mysql config and restart mysql then run digikam

OBSERVED RESULT
-- digiKam Linux AppImage Bundle
-- Use 'help' as CLI argument to know all available options for digiKam application.
-- Notes: to integrate this bundle to your desktop, use AppImageLauncher.
--        to enable all debug messages on the console, use 'export QT_LOGGING_RULES="digikam*=true"'.
libudev.so.0 
libxcb-dri3.so.0 
-- Preloading shared libs: :/usr/lib64/libxcb-dri3.so.0
Digikam::DXmlGuiWindow::setupIconTheme: Breeze icons resource file found
Digikam::DXmlGuiWindow::setupIconTheme: Breeze-dark icons resource file found
unknown: Qt translations path: "/home/brown/Digikam/digiKam-7.3.0-x86-64/usr/share/digikam/translations"
unknown: Loaded locale: "en_US" from catalog: "qt"
unknown: Loaded locale: "en_US" from catalog: "qtbase"
unknown: Loaded locale: "en_US" from catalog: "qt_help"
Digikam::ApplicationSettings::setApplicationFont: Switch to application font:  QFont(Sans Serif,8,-1,5,50,0,0,0,0,0)
Digikam::AlbumWatch::AlbumWatch: AlbumWatch is disabled
Digikam::AlbumManager::setDatabase: Database Parameters:
   Type:                      "QMYSQL"
   DB Core Name:              "digikam6"
   DB Thumbs Name:            "digikam6"
   DB Face Name:              "digikam6"
   DB Similarity Name:        "digikam6"
   Connect Options:           "UNIX_SOCKET=/var/run/mysqld/mysqld.sock"
   Host Name:                 "localhost"
   Host port:                 3306
   Internal Server:           false
   Internal Server Path:      ""
   Internal Server Admin Cmd: "mysqladmin"
   Internal Server Serv Cmd:  ""
   Internal Server Init Cmd:  ""
   Username:                  "digikam"
   Password:                  "XXXXXXXXX"

Digikam::DbEngineConfigSettingsLoader::readConfig: Loading SQL code from config file "/home/brown/Digikam/digiKam-7.3.0-x86-64/usr/share/digikam/database/dbconfig.xml"
Digikam::DbEngineConfigSettingsLoader::readConfig: Checking XML version ID => expected:  3  found:  3
Digikam::CoreDbSchemaUpdater::update: Core database: running schema update
Digikam::CoreDbSchemaUpdater::startUpdates: Core database: have a structure version  10
Digikam::CoreDbSchemaUpdater::makeUpdates: Core database: makeUpdates  10  to  13
Digikam::BdEngineBackendPrivate::debugOutputFailedQuery: Failure executing query:
 "" 
Error messages: "QMYSQL: Unable to execute query" "You do not have the SUPER privilege and binary logging is enabled (you *might* want to use the less safe log_bin_trust_function_creators variable)" "1419" 2 
Bound values:  ()
Digikam::BdEngineBackend::execDBAction: Error while executing DBAction [ "UpdateSchemaFromV10ToV11" ] Statement [ "DROP TRIGGER IF EXISTS temp_insert_tagstree;" ]
Digikam::CoreDbSchemaUpdater::performUpdateToVersion: Core database: schema update to V 11 failed!
Digikam::CoreDbAccess::checkReadyForUse: Core database: cannot process schema initialization
Digikam::KMemoryInfo::update: KMemoryInfo: Platform identified :  "LINUX"
Digikam::KMemoryInfo::bytes: KMemoryInfo: TotalRam:  4028268544
Digikam::LoadingCache::setCacheSize: Allowing a cache size of 192 MB

EXPECTED RESULT


SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: Linux 5.4.0-80-generic #90~18.04.1-Ubuntu SMP Tue Jul 13 19:40:02 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux
(available in About System)
KDE Plasma Version: 
KDE Frameworks Version: 
Qt Version: 

ADDITIONAL INFORMATION
Comment 1 Maik Qualmann 2021-07-31 19:20:23 UTC
https://bugs.kde.org/show_bug.cgi?id=435065#c8

set global log_bin_trust_function_creators=1;

Use global...

Maik
Comment 2 Maik Qualmann 2021-09-26 18:58:37 UTC
Was the problem resolved?

Maik
Comment 3 Dave 2021-09-27 19:52:05 UTC
After I changed "log_bin_trust_function_creators = 1" and restarted mysql then restarted digikam it updated.