Bug 395138 - Unable to launch kmail on kde neon, akonadi crash
Summary: Unable to launch kmail on kde neon, akonadi crash
Status: RESOLVED WORKSFORME
Alias: None
Product: Akonadi
Classification: Frameworks and Libraries
Component: server (show other bugs)
Version: unspecified
Platform: Neon Linux
: NOR crash
Target Milestone: ---
Assignee: kdepim bugs
URL:
Keywords: triaged
Depends on:
Blocks:
 
Reported: 2018-06-08 09:35 UTC by Alan Pope
Modified: 2018-10-28 03:38 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alan Pope 2018-06-08 09:35:08 UTC
Running Kmail 5.8.2 on KDE Neon. Tried to launch kmail and got an akonadi failure.

$ kmail
org.kde.pim.kidentitymanagement: IdentityManager: There was no default identity. Marking first one as default.
Connecting to deprecated signal QDBusConnectionInterface::serviceOwnerChanged(QString,QString,QString)
No text-to-speech plug-ins were found.
org.kde.pim.akonadiserver: database server stopped unexpectedly
org.kde.pim.akonadiserver: Database process exited unexpectedly during initial connection!
org.kde.pim.akonadiserver: executable: "/usr/sbin/mysqld-akonadi"
org.kde.pim.akonadiserver: arguments: ("--defaults-file=/home/alan/.local/share/akonadi/mysql.conf", "--datadir=/home/alan/.local/share/akonadi/db_data/", "--socket=/tmp/akonadi-alan.CWOEck/mysql.socket", "--pid-file=/tmp/akonadi-alan.CWOEck/mysql.pid")
org.kde.pim.akonadiserver: stdout: ""
org.kde.pim.akonadiserver: stderr: "180608 10:26:00 [Note] /usr/sbin/mysqld (mysqld 10.0.34-MariaDB-0ubuntu0.16.04.1) starting as process 27773 ...\n180608 10:26:00 [Warning] Can't create test file /home/alan/.local/share/akonadi/db_data/KinkPad-K450.lower-test\n\x07/usr/sbin/mysqld: Can't change dir to '/home/alan/.local/share/akonadi/db_data/' (Errcode: 2 \"No such file or directory\")\n180608 10:26:00 [ERROR] Aborting\n\n180608 10:26:00 [Note] /usr/sbin/mysqld: Shutdown complete\n\n"
org.kde.pim.akonadiserver: exit code: 1
org.kde.pim.akonadiserver: process error: "Unknown error"
org.kde.pim.akonadiserver: Failed to remove runtime connection config file
org.kde.pim.akonadicontrol: Application 'akonadiserver' exited normally...
org.kde.pim.akonadicore: Job error:  "" for collection: QVector() 

org.kde.pim.akonadicore: Job error:  "" for collection: QVector() 

org.kde.pim.messagelist: Failed to load tags  ""
org.kde.pim.kmail: ""
org.kde.pim.kmail: ""
Comment 1 Pascalio 2018-06-10 00:15:16 UTC
I started having the same problem (with anything that requires akonadi) in Kubuntu 17.10.

$ akonadictl start
Connecting to deprecated signal QDBusConnectionInterface::serviceOwnerChanged(QString,QString,QString)
org.kde.pim.akonadiserver: database server stopped unexpectedly
org.kde.pim.akonadiserver: Database process exited unexpectedly during initial connection!
org.kde.pim.akonadiserver: executable: "/usr/sbin/mysqld-akonadi"
org.kde.pim.akonadiserver: arguments: ("--defaults-file=/home/pascalio/.local/share/akonadi/mysql.conf", "--datadir=/home/pascalio/.local/share/akonadi/db_data/", "--socket=/tmp/akonadi-pascalio.OxIIAQ/mysql.socket", "--pid-file=/tmp/akonadi-pascalio.OxIIAQ/mysql.pid")
org.kde.pim.akonadiserver: stdout: ""
org.kde.pim.akonadiserver: stderr: ""
org.kde.pim.akonadiserver: exit code: 2
org.kde.pim.akonadiserver: process error: "Unknown error"
mysqladmin: connect to server at 'localhost' failed
error: 'Can't connect to local MySQL server through socket '/tmp/akonadi-pascalio.OxIIAQ/mysql.socket' (2)'
Check that mysqld is running and that the socket: '/tmp/akonadi-pascalio.OxIIAQ/mysql.socket' exists!
org.kde.pim.akonadiserver: Failed to remove runtime connection config file
org.kde.pim.akonadicontrol: Application 'akonadiserver' exited normally...
Comment 2 Christophe Marin 2018-06-10 07:34:30 UTC
Is there anything special in your dmesg output after running akonadictl start ?
Comment 3 Alan Pope 2018-06-10 13:21:13 UTC
Yes, in my dmesg I see the following.

[Sat Jun  9 10:26:18 2018] audit: type=1400 audit(1528636826.531:499): apparmor="DENIED" operation="open" profile="/usr/sbin/mysqld-akonadi///usr/sbin/mysqld" name="/etc/mysql/mariadb.cnf" pid=4525 comm="mysqld" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
Comment 4 Christophe Marin 2018-06-10 13:31:45 UTC
The ubuntu people never learn...

Try that please:

sudo aa-complain mysqld then retry akonadictl start
Comment 5 Christophe Marin 2018-06-10 13:34:46 UTC
forgot one command, sorry :
sudo aa-complain mysqld
sudo /etc/init.d/apparmor reload

and akonadictl start after that
Comment 6 Christophe Marin 2018-06-10 13:40:02 UTC
and if that's still not enough, also run:
sudo aa-complain mysqld-akonadi and sudo /etc/init.d/apparmor reload
Comment 7 Christophe Marin 2018-06-14 06:18:38 UTC
Ping? any news?
Comment 8 Alan Pope 2018-06-14 10:30:59 UTC
Apologies for the delay.

aa-complain didn't work until I installed apparmor-utils.
Then it failed because mysqld wasn't found.
I don't appear to have mysql server installed.
Looks like I've got mariadb installed.

alan@KinkPad-K450:~$ dpkg -S /usr/sbin/mysqld
mariadb-server-core-10.0: /usr/sbin/mysqld

alan@KinkPad-K450:~$ sudo aa-complain mysqld
Profile for /usr/sbin/mysqld not found, skipping
Comment 9 Christophe Marin 2018-06-14 10:58:23 UTC
Any luck with sudo aa-complain mysqld-akonadi ?
Comment 10 Alan Pope 2018-06-14 11:29:27 UTC
alan@KinkPad-K450:~$ sudo aa-complain mysqld-akonadi 
[sudo] password for alan: 
Setting /usr/sbin/mysqld-akonadi to complain mode.
alan@KinkPad-K450:~$ sudo /etc/init.d/apparmor reload
[ ok ] Reloading apparmor configuration (via systemctl): apparmor.service.
alan@KinkPad-K450:~$ akonadictl start 
Connecting to deprecated signal QDBusConnectionInterface::serviceOwnerChanged(QString,QString,QString)
alan@KinkPad-K450:~$ org.kde.pim.akonadiserver: database server stopped unexpectedly
org.kde.pim.akonadiserver: Database process exited unexpectedly during initial connection!
org.kde.pim.akonadiserver: executable: "/usr/sbin/mysqld-akonadi"
org.kde.pim.akonadiserver: arguments: ("--defaults-file=/home/alan/.local/share/akonadi/mysql.conf", "--datadir=/home/alan/.local/share/akonadi/db_data/", "--socket=/tmp/akonadi-alan.Jv7DW9/mysql.socket", "--pid-file=/tmp/akonadi-alan.Jv7DW9/mysql.pid")
org.kde.pim.akonadiserver: stdout: ""
org.kde.pim.akonadiserver: stderr: "180614 12:28:39 [Note] /usr/sbin/mysqld (mysqld 10.0.34-MariaDB-0ubuntu0.16.04.1) starting as process 27655 ...\n180614 12:28:39 [Warning] Can't create test file /home/alan/.local/share/akonadi/db_data/KinkPad-K450.lower-test\n\x07/usr/sbin/mysqld: Can't change dir to '/home/alan/.local/share/akonadi/db_data/' (Errcode: 2 \"No such file or directory\")\n180614 12:28:39 [ERROR] Aborting\n\n180614 12:28:39 [Note] /usr/sbin/mysqld: Shutdown complete\n\n"
org.kde.pim.akonadiserver: exit code: 1
org.kde.pim.akonadiserver: process error: "Unknown error"
org.kde.pim.akonadiserver: Failed to remove runtime connection config file
org.kde.pim.akonadicontrol: Application 'akonadiserver' exited normally...
Comment 11 Christophe Marin 2018-06-14 11:47:23 UTC
Curious. does mkdir -p /home/alan/.local/share/akonadi/db_data succeed? 
sounds like it couldn't be created (permissions/owner problems maybe?)
Comment 12 Alan Pope 2018-06-14 13:26:39 UTC
alan@KinkPad-K450:~$ ls .local/share/akonadi/
akonadi_control.error      akonadictl.error      akonadiserver.error      mysql.conf
akonadi_control.error.old  akonadictl.error.old  akonadiserver.error.old  socket-KinkPad-K450
alan@KinkPad-K450:~$ ls -ld .local/share/akonadi/
drwxrwxr-x 2 alan alan 4096 Jun 14 12:28 .local/share/akonadi/

alan@KinkPad-K450:~$ mkdir -p /home/alan/.local/share/akonadi/db_data 
alan@KinkPad-K450:~$ ls -l /home/alan/.local/share/akonadi/db_data
total 0
Comment 13 Christophe Marin 2018-06-14 14:31:51 UTC
mmmh.. ok, try:

- renaming ~/.config/akonadi and ~/.local/share/akonadi
- then, if it's installed, run kdebugsettings and click on the "enable all debug" 
- and finally run akonadictl start and attach the full output please.
Comment 14 Andrew Crouthamel 2018-09-28 03:11:59 UTC
Dear Bug Submitter,

This bug has been in NEEDSINFO status with no change for at least 15 days. Please provide the requested information as soon as possible and set the bug status as REPORTED. Due to regular bug tracker maintenance, if the bug is still in NEEDSINFO status with no change in 30 days, the bug will be closed as RESOLVED > WORKSFORME due to lack of needed information.

For more information about our bug triaging procedures please read the wiki located here: https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

If you have already provided the requested information, please set the bug status as REPORTED so that the KDE team knows that the bug is ready to be confirmed.

Thank you for helping us make KDE software even better for everyone!
Comment 15 Andrew Crouthamel 2018-10-28 03:38:19 UTC
Dear Bug Submitter,

This bug has been in NEEDSINFO status with no change for at least 30 days. The bug is now closed as RESOLVED > WORKSFORME due to lack of needed information.

For more information about our bug triaging procedures please read the wiki located here: https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

Thank you for helping us make KDE software even better for everyone!