Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Akonad fails after upgrade (Can't connect to local MySQL)
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
nagmat84
Tux's lil' helper
Tux's lil' helper


Joined: 27 Mar 2007
Posts: 123

PostPosted: Thu Apr 25, 2019 9:33 am    Post subject: Akonad fails after upgrade (Can't connect to local MySQL) Reply with quote

Error message when starting Kmail2, Kontact, Akonadi Console, etc.:
Quote:
Failed to connect to database:
Can't connect to local MySQL server through socket '/tmp/akonadi-matthias.sGANvK/mysql.socket' (2)
QMYSQL: Unable to connect
I upgraded KDE from 18.08.3 to 18.12.3 during a @world update. Maybe MySQL was upgraded, too. I am not sure update that as I did not pay attention. Currently installed software packages:
Quote:
dev-db/mysql-5.7.25:0/18
kde-apps/akonadi-18.12.3-r1:5
The content of the directory mentioned by the error message
Code:
$ ls -lh /tmp/akonadi-matthias.sGANvK/
insgesamt 0
srwxr-xr-x 1 matthias users 0 25. Apr 11:02 akonadiserver-cmd.socket
srwxr-xr-x 1 matthias users 0 25. Apr 11:02 akonadiserver-ntf.socket
Obviously, there is no socket file "mysql.socket". The log messages from my journal are
Code:
$ journalctl -b 0 -g '.*(akonadi|mysql).*'
-- Logs begin at Fri 2016-11-18 20:45:12 CET, end at Thu 2019-04-25 11:09:16 CEST. --
Apr 25 10:59:30 matthias-pc systemd-tmpfiles[1887]: [/usr/lib64/tmpfiles.d/mysql.conf:1] Line references path below legacy directory /var/run/, updating /var/run/mysqld → /run/mysqld; please update the tmpfiles.d/ drop-in file according>
Apr 25 10:59:30 matthias-pc systemd-tmpfiles[2022]: [/usr/lib64/tmpfiles.d/mysql.conf:1] Line references path below legacy directory /var/run/, updating /var/run/mysqld → /run/mysqld; please update the tmpfiles.d/ drop-in file according>
Apr 25 10:59:47 matthias-pc akonadiserver[2474]: org.kde.pim.akonadiserver: Starting up the Akonadi Server...
Apr 25 10:59:52 matthias-pc dbus-daemon[2237]: [session uid=1000 pid=2237] Activating service name='org.freedesktop.Akonadi.Control' requested by ':1.47' (uid=1000 pid=2557 comm="/usr/bin/kontact -session 1010213a138e700015561291")
Apr 25 10:59:52 matthias-pc akonadi_control[2699]: org.kde.pim.akonadicontrol: Unable to register service as "org.freedesktop.Akonadi.Control.lock" Maybe it's already running?
Apr 25 10:59:52 matthias-pc dbus-daemon[2237]: [session uid=1000 pid=2237] Activated service 'org.freedesktop.Akonadi.Control' failed: Process org.freedesktop.Akonadi.Control exited with status 255
Apr 25 10:59:52 matthias-pc dbus-daemon[2237]: [session uid=1000 pid=2237] Activating service name='org.freedesktop.Akonadi.Control' requested by ':1.47' (uid=1000 pid=2557 comm="/usr/bin/kontact -session 1010213a138e700015561291")
Apr 25 10:59:53 matthias-pc akonadi_control[2714]: org.kde.pim.akonadicontrol: Unable to register service as "org.freedesktop.Akonadi.Control.lock" Maybe it's already running?
Apr 25 10:59:53 matthias-pc dbus-daemon[2237]: [session uid=1000 pid=2237] Activated service 'org.freedesktop.Akonadi.Control' failed: Process org.freedesktop.Akonadi.Control exited with status 255
Apr 25 11:00:01 matthias-pc akonadiserver[2474]: org.kde.pim.akonadiserver: Running DB initializer
Apr 25 11:00:01 matthias-pc akonadiserver[2474]: org.kde.pim.akonadiserver: DB initializer done
Apr 25 11:00:07 matthias-pc akonadiserver[2474]: org.kde.pim.akonadiserver: Updating index failed: 
                                                 Sql error: Invalid default value for 'atime' QMYSQL: Unable to execute query
                                                 Query: CREATE  INDEX PimItemTable_mimeTypeIndex ON PimItemTable (mimeTypeId)
Apr 25 11:00:07 matthias-pc akonadiserver[2474]: org.kde.pim.akonadiserver: ""
Apr 25 11:00:07 matthias-pc akonadiserver[2474]: org.kde.pim.akonadiserver: Unable to initialize database.
Apr 25 11:00:10 matthias-pc akonadiserver[2474]: org.kde.pim.akonadiserver: Shutting down AkonadiServer...
Apr 25 11:00:10 matthias-pc akonadi_control[2468]: org.kde.pim.akonadicontrol: Application 'akonadiserver' exited normally...
Apr 25 11:00:10 matthias-pc korgac[2417]: org.kde.pim.akonadicore: Job error:  "" for collection: QVector()
Apr 25 11:00:10 matthias-pc kontact[2557]: org.kde.pim.akonadicore: Job error:  "" for collection: QVector()
Apr 25 11:00:10 matthias-pc kontact[2557]: org.kde.pim.akonadicore: Job error:  "" for collection: QVector()
Apr 25 11:02:18 matthias-pc akonadiserver[3023]: org.kde.pim.akonadiserver: Starting up the Akonadi Server...
Apr 25 11:02:20 matthias-pc akonadiserver[3023]: org.kde.pim.akonadiserver: Running DB initializer
Apr 25 11:02:20 matthias-pc akonadiserver[3023]: org.kde.pim.akonadiserver: DB initializer done
Apr 25 11:02:22 matthias-pc akonadiserver[3023]: org.kde.pim.akonadiserver: Updating index failed: 
                                                 Sql error: Invalid default value for 'atime' QMYSQL: Unable to execute query
                                                 Query: CREATE  INDEX PimItemTable_mimeTypeIndex ON PimItemTable (mimeTypeId)
Apr 25 11:02:22 matthias-pc akonadiserver[3023]: org.kde.pim.akonadiserver: ""
Apr 25 11:02:22 matthias-pc akonadiserver[3023]: org.kde.pim.akonadiserver: Unable to initialize database.
Apr 25 11:02:24 matthias-pc akonadiserver[3023]: org.kde.pim.akonadiserver: Shutting down AkonadiServer...
Apr 25 11:02:24 matthias-pc akonadi_control[3019]: org.kde.pim.akonadicontrol: Application 'akonadiserver' exited normally...
Apr 25 11:02:24 matthias-pc akonadiconsole[3001]: org.kde.pim.akonadicore: ""
Apr 25 11:02:24 matthias-pc akonadiconsole[3001]: org.kde.pim.akonadicore: Job error:  "" for collection: QVector()
And here the output of "mysql.err"
Code:
$ cat .local/share/akonadi/db_data/mysql.err

2019-04-25T13:36:07.574700Z 0 [Warning] The syntax '--log_warnings/-W' is deprecated and will be removed in a future release. Please use '--log_error_verbosity' instead.
2019-04-25T13:36:07.574759Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
2019-04-25T13:36:07.575163Z 0 [Note] --secure-file-priv is set to NULL. Operations related to importing and exporting data are disabled
2019-04-25T13:36:07.575568Z 0 [Note] /usr/sbin/mysqld (mysqld 5.7.25) starting as process 2584 ...
2019-04-25T13:36:07.583730Z 0 [Note] InnoDB: PUNCH HOLE support available
2019-04-25T13:36:07.583746Z 0 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2019-04-25T13:36:07.583749Z 0 [Note] InnoDB: Uses event mutexes
2019-04-25T13:36:07.583751Z 0 [Note] InnoDB: GCC builtin __atomic_thread_fence() is used for memory barrier
2019-04-25T13:36:07.583754Z 0 [Note] InnoDB: Compressed tables use zlib 1.2.11
2019-04-25T13:36:07.583756Z 0 [Note] InnoDB: Using Linux native AIO
2019-04-25T13:36:07.584304Z 0 [Note] InnoDB: Number of pools: 1
2019-04-25T13:36:07.585908Z 0 [Note] InnoDB: Using CPU crc32 instructions
2019-04-25T13:36:07.587725Z 0 [Note] InnoDB: Initializing buffer pool, total size = 128M, instances = 1, chunk size = 128M
2019-04-25T13:36:07.594907Z 0 [Note] InnoDB: Completed initialization of buffer pool
2019-04-25T13:36:07.596038Z 0 [Note] InnoDB: If the mysqld execution user is authorized, page cleaner thread priority can be changed. See the man page of setpriority().
2019-04-25T13:36:08.237339Z 0 [Note] InnoDB: Highest supported file format is Barracuda.
2019-04-25T13:36:10.786804Z 0 [Note] InnoDB: Creating shared tablespace for temporary tables
2019-04-25T13:36:10.786921Z 0 [Note] InnoDB: Setting file './ibtmp1' size to 12 MB. Physically writing the file full; Please wait ...
2019-04-25T13:36:11.373911Z 0 [Note] InnoDB: File './ibtmp1' size is now 12 MB.
2019-04-25T13:36:11.375012Z 0 [Note] InnoDB: 96 redo rollback segment(s) found. 96 redo rollback segment(s) are active.
2019-04-25T13:36:11.375034Z 0 [Note] InnoDB: 32 non-redo rollback segment(s) are active.
2019-04-25T13:36:11.375687Z 0 [Note] InnoDB: 5.7.25 started; log sequence number 7587288258
2019-04-25T13:36:11.375908Z 0 [Note] InnoDB: Loading buffer pool(s) from /home/matthias/.local/share/akonadi/db_data/ib_buffer_pool
2019-04-25T13:36:11.378592Z 0 [Note] Plugin 'FEDERATED' is disabled.
2019-04-25T13:36:11.537181Z 0 [Warning] Gtid table is not ready to be used. Table 'mysql.gtid_executed' cannot be opened.
2019-04-25T13:36:11.538875Z 0 [Note] Found ca.pem, server-cert.pem and server-key.pem in data directory. Trying to enable SSL support using them.
2019-04-25T13:36:11.538893Z 0 [Note] Skipping generation of SSL certificates as certificate files are present in data directory.
2019-04-25T13:36:11.793735Z 0 [Warning] CA certificate ca.pem is self signed.
2019-04-25T13:36:11.793774Z 0 [Note] Skipping generation of RSA key pair as key files are present in data directory.
2019-04-25T13:36:11.867268Z 0 [Warning] Insecure configuration for --pid-file: Location '/tmp' in the path is accessible to all OS users. Consider choosing a different directory.
2019-04-25T13:36:11.867352Z 0 [Warning] Failed to open optimizer cost constant tables
2019-04-25T13:36:11.867437Z 0 [Warning] Can't open and lock time zone table: Table 'mysql.time_zone_leap_second' doesn't exist trying to live without them
2019-04-25T13:36:11.867469Z 0 [ERROR] Can't open and lock privilege tables: Table 'mysql.servers' doesn't exist
2019-04-25T13:36:11.867524Z 0 [ERROR] Native table 'performance_schema'.'cond_instances' has the wrong structure
2019-04-25T13:36:11.867538Z 0 [ERROR] Native table 'performance_schema'.'events_waits_current' has the wrong structure
2019-04-25T13:36:11.867548Z 0 [ERROR] Native table 'performance_schema'.'events_waits_history' has the wrong structure
  ... skipped 81 similar lines ...
2019-04-25T13:36:11.868406Z 0 [ERROR] Native table 'performance_schema'.'variables_by_thread' has the wrong structure
2019-04-25T13:36:11.868415Z 0 [ERROR] Native table 'performance_schema'.'global_variables' has the wrong structure
2019-04-25T13:36:11.868424Z 0 [ERROR] Native table 'performance_schema'.'session_variables' has the wrong structure
2019-04-25T13:36:11.868674Z 0 [Note] /usr/sbin/mysqld: ready for connections.
Version: '5.7.25'  socket: '/tmp/akonadi-matthias.B68cEK/mysql.socket'  port: 0  Gentoo Linux mysql-5.7.25
2019-04-25T13:36:12.939516Z 3 [ERROR] InnoDB: Table `mysql`.`innodb_table_stats` not found.
2019-04-25T13:36:12.939565Z 3 [ERROR] InnoDB: Fetch of persistent statistics requested for table `akonadi`.`collectionattributetable` but the required system tables mysql.innodb_table_stats and mysql.innodb_index_stats are not present or have unexpected structure. Using transient stats instead.
2019-04-25T13:36:13.034408Z 3 [ERROR] InnoDB: Table `mysql`.`innodb_table_stats` not found.
2019-04-25T13:36:13.034427Z 3 [ERROR] InnoDB: Fetch of persistent statistics requested for table `akonadi`.`collectionmimetyperelation` but the required system tables mysql.innodb_table_stats and mysql.innodb_index_stats are not present or have unexpected structure. Using transient stats instead.
2019-04-25T13:36:13.212818Z 3 [ERROR] InnoDB: Table `mysql`.`innodb_table_stats` not found.
2019-04-25T13:36:13.212843Z 3 [ERROR] InnoDB: Fetch of persistent statistics requested for table `akonadi`.`collectionpimitemrelation` but the required system tables mysql.innodb_table_stats and mysql.innodb_index_stats are not present or have unexpected structure. Using transient stats instead.
  ... skipped 303 similar lines ...
2019-04-25T13:36:24.354058Z 4 [ERROR] InnoDB: Table `mysql`.`innodb_table_stats` not found.
2019-04-25T13:36:24.354069Z 4 [ERROR] InnoDB: Fetch of persistent statistics requested for table `akonadi`.`mimetypetable` but the required system tables mysql.innodb_table_stats and mysql.innodb_index_stats are not present or have unexpected structure. Using transient stats instead.
2019-04-25T13:36:24.354100Z 4 [ERROR] InnoDB: Table `mysql`.`innodb_table_stats` not found.
2019-04-25T13:36:24.354105Z 4 [ERROR] InnoDB: Fetch of persistent statistics requested for table `akonadi`.`parttable` but the required system tables mysql.innodb_table_stats and mysql.innodb_index_stats are not present or have unexpected structure. Using transient stats instead.
2019-04-25T13:36:24.783055Z 4 [ERROR] InnoDB: Table `mysql`.`innodb_table_stats` not found.
2019-04-25T13:36:24.783076Z 4 [ERROR] InnoDB: Fetch of persistent statistics requested for table `akonadi`.`collectionpimitemrelation` but the required system tables mysql.innodb_table_stats and mysql.innodb_index_stats are not present or have unexpected structure. Using transient stats instead.
2019-04-25T13:36:24.842682Z 0 [Note] Giving 0 client threads a chance to die gracefully
2019-04-25T13:36:24.842710Z 0 [Note] Shutting down slave threads
2019-04-25T13:36:24.842714Z 0 [Note] Forcefully disconnecting 0 remaining clients
2019-04-25T13:36:24.842739Z 0 [Note] Binlog end
2019-04-25T13:36:24.842877Z 0 [Note] Shutting down plugin 'ngram'
2019-04-25T13:36:24.842885Z 0 [Note] Shutting down plugin 'partition'
2019-04-25T13:36:24.842887Z 0 [Note] Shutting down plugin 'BLACKHOLE'
2019-04-25T13:36:24.842890Z 0 [Note] Shutting down plugin 'ARCHIVE'
2019-04-25T13:36:24.842892Z 0 [Note] Shutting down plugin 'PERFORMANCE_SCHEMA'
2019-04-25T13:36:24.842914Z 0 [Note] Shutting down plugin 'MRG_MYISAM'
2019-04-25T13:36:24.842918Z 0 [Note] Shutting down plugin 'MyISAM'
2019-04-25T13:36:24.842928Z 0 [Note] Shutting down plugin 'INNODB_SYS_VIRTUAL'
2019-04-25T13:36:24.842930Z 0 [Note] Shutting down plugin 'INNODB_SYS_DATAFILES'
2019-04-25T13:36:24.842932Z 0 [Note] Shutting down plugin 'INNODB_SYS_TABLESPACES'
2019-04-25T13:36:24.842934Z 0 [Note] Shutting down plugin 'INNODB_SYS_FOREIGN_COLS'
2019-04-25T13:36:24.842936Z 0 [Note] Shutting down plugin 'INNODB_SYS_FOREIGN'
2019-04-25T13:36:24.842938Z 0 [Note] Shutting down plugin 'INNODB_SYS_FIELDS'
2019-04-25T13:36:24.842940Z 0 [Note] Shutting down plugin 'INNODB_SYS_COLUMNS'
2019-04-25T13:36:24.842942Z 0 [Note] Shutting down plugin 'INNODB_SYS_INDEXES'
2019-04-25T13:36:24.842943Z 0 [Note] Shutting down plugin 'INNODB_SYS_TABLESTATS'
2019-04-25T13:36:24.842945Z 0 [Note] Shutting down plugin 'INNODB_SYS_TABLES'
2019-04-25T13:36:24.842947Z 0 [Note] Shutting down plugin 'INNODB_FT_INDEX_TABLE'
2019-04-25T13:36:24.842949Z 0 [Note] Shutting down plugin 'INNODB_FT_INDEX_CACHE'
2019-04-25T13:36:24.842951Z 0 [Note] Shutting down plugin 'INNODB_FT_CONFIG'
2019-04-25T13:36:24.842952Z 0 [Note] Shutting down plugin 'INNODB_FT_BEING_DELETED'
2019-04-25T13:36:24.842954Z 0 [Note] Shutting down plugin 'INNODB_FT_DELETED'
2019-04-25T13:36:24.842956Z 0 [Note] Shutting down plugin 'INNODB_FT_DEFAULT_STOPWORD'
2019-04-25T13:36:24.842958Z 0 [Note] Shutting down plugin 'INNODB_METRICS'
2019-04-25T13:36:24.842960Z 0 [Note] Shutting down plugin 'INNODB_TEMP_TABLE_INFO'
2019-04-25T13:36:24.842961Z 0 [Note] Shutting down plugin 'INNODB_BUFFER_POOL_STATS'
2019-04-25T13:36:24.842963Z 0 [Note] Shutting down plugin 'INNODB_BUFFER_PAGE_LRU'
2019-04-25T13:36:24.842965Z 0 [Note] Shutting down plugin 'INNODB_BUFFER_PAGE'
2019-04-25T13:36:24.842967Z 0 [Note] Shutting down plugin 'INNODB_CMP_PER_INDEX_RESET'
2019-04-25T13:36:24.842969Z 0 [Note] Shutting down plugin 'INNODB_CMP_PER_INDEX'
2019-04-25T13:36:24.842971Z 0 [Note] Shutting down plugin 'INNODB_CMPMEM_RESET'
2019-04-25T13:36:24.842973Z 0 [Note] Shutting down plugin 'INNODB_CMPMEM'
2019-04-25T13:36:24.842974Z 0 [Note] Shutting down plugin 'INNODB_CMP_RESET'
2019-04-25T13:36:24.842976Z 0 [Note] Shutting down plugin 'INNODB_CMP'
2019-04-25T13:36:24.842978Z 0 [Note] Shutting down plugin 'INNODB_LOCK_WAITS'
2019-04-25T13:36:24.842980Z 0 [Note] Shutting down plugin 'INNODB_LOCKS'
2019-04-25T13:36:24.842988Z 0 [Note] Shutting down plugin 'INNODB_TRX'
2019-04-25T13:36:24.842990Z 0 [Note] Shutting down plugin 'InnoDB'
2019-04-25T13:36:24.843054Z 0 [Note] InnoDB: FTS optimize thread exiting.
2019-04-25T13:36:24.843105Z 0 [Note] InnoDB: Starting shutdown...
2019-04-25T13:36:24.943299Z 0 [Note] InnoDB: Dumping buffer pool(s) to /home/matthias/.local/share/akonadi/db_data/ib_buffer_pool
2019-04-25T13:36:24.944046Z 0 [Note] InnoDB: Buffer pool(s) dump completed at 190425 15:36:24
2019-04-25T13:36:26.717488Z 0 [Note] InnoDB: Shutdown completed; log sequence number 7587288286
2019-04-25T13:36:26.718475Z 0 [Note] InnoDB: Removed temporary tablespace data file: "ibtmp1"
2019-04-25T13:36:26.718485Z 0 [Note] Shutting down plugin 'MEMORY'
2019-04-25T13:36:26.718489Z 0 [Note] Shutting down plugin 'CSV'
2019-04-25T13:36:26.718492Z 0 [Note] Shutting down plugin 'sha256_password'
2019-04-25T13:36:26.718494Z 0 [Note] Shutting down plugin 'mysql_native_password'
2019-04-25T13:36:26.718587Z 0 [Note] Shutting down plugin 'binlog'
2019-04-25T13:36:26.718814Z 0 [Note] /usr/sbin/mysqld: Shutdown complete
There are 4 issue worth to be mentioned:
  • The deamon opens the socket successfully (2019-04-25T13:36:11.868674Z 0 [Note] /usr/sbin/mysqld: ready for connections.)
  • The deamon immediately terminates again (2019-04-25T13:36:24.842682Z 0 [Note] Giving 0 client threads a chance to die gracefully)
  • There are a lot of errors following the pattern: [ERROR] Native table 'X'.'Y' has the wrong structure
  • There are a lot of errors following the pattern: [ERROR] InnoDB: Table `X`.`innodb_table_stats` not found ... Using transient stats instead.
Although, the error messages are not nice, they do not seam to be the true reason why mysqld dies. At least mysqld claims to use a fall back solution.

Any ideas?
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum