Announcement

Collapse
No announcement yet.

Kontact fails because akonadi not operational

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Kontact fails because akonadi not operational

    Since upgrading to 15.04, I cannot get kontact to work. It gives the error

    "The akonadi personal information management service is not operational."

    In the details, it says akonadictl found and usable, but control process not registered at D-Bus.

    I tried deleting kontact files in .kde/share/apps and .kde/share/config, but to no avail.

    This problem has been reported and Piotr has proposed a solution, but it doesn't work for everybody. Besides, since I use mysql for other things, I do not want to replace it with something called mariadb, whatever that may be.

    If I look in the logs, kern.log contains some entries like

    kernel: [ 1118.811706] audit: type=1400 audit(1434864305.127:19): apparmor="DENIED" operation="open" profile="/usr/sbin/mysqld-akonadi///usr/sbin/mysqld" name="/etc/mysql/mysql.cnf" pid=2612 comm="mysqld" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0

    and syslog, like

    [ 1118.811706] audit: type=1400 audit(1434864305.127:19): apparmor="DENIED" operation="open" profile="/usr/sbin/mysqld-akonadi///usr/sbin/mysqld" name="/etc/mysql/mysql.cnf" pid=2612 comm="mysqld" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
    'I must have a prodigious quantity of mind; it takes me as much as a week sometimes to make it up.' Mark Twain

    #2
    What's the output of
    Code:
    sudo aa-status

    Comment


      #3
      $ sudo aa-status
      apparmor module is loaded.
      17 profiles are loaded.
      17 profiles are in enforce mode.
      /sbin/dhclient
      /usr/lib/NetworkManager/nm-dhcp-client.action
      /usr/lib/NetworkManager/nm-dhcp-helper
      /usr/lib/connman/scripts/dhclient-script
      /usr/lib/cups/backend/cups-pdf
      /usr/lib/telepathy/mission-control-5
      /usr/lib/telepathy/telepathy-*
      /usr/lib/telepathy/telepathy-*//pxgsettings
      /usr/lib/telepathy/telepathy-*//sanitized_helper
      /usr/lib/telepathy/telepathy-ofono
      /usr/sbin/cups-browsed
      /usr/sbin/cupsd
      /usr/sbin/cupsd//third_party
      /usr/sbin/mysqld
      /usr/sbin/mysqld-akonadi
      /usr/sbin/mysqld-akonadi///usr/sbin/mysqld
      /usr/sbin/tcpdump
      0 profiles are in complain mode.
      5 processes have profiles defined.
      5 processes are in enforce mode.
      /sbin/dhclient (840)
      /usr/sbin/cups-browsed (774)
      /usr/sbin/cupsd (2678)
      /usr/sbin/cupsd (2683)
      /usr/sbin/mysqld (1178)
      0 processes are in complain mode.
      0 processes are unconfined but have a profile defined.
      'I must have a prodigious quantity of mind; it takes me as much as a week sometimes to make it up.' Mark Twain

      Comment


        #4
        There are numerous reported problems (Google for the details) between AppArmor and various MySQL configurations. Frankly, the security layer provided by AppArmor is dubious at best; it's fairly easy to circumvent and the kinds of threats it protects against are quite uncommon in normal desktop usage scenarios. *buntu is one of the few distros that enables it by default. Debian, from which all *buntu flavors are derived, doesn't enable it. Thus, I disable it on all my machines:
        Code:
        sudo service apparmor teardown
        
        sudo service apparmor stop
        
        sudo apt-get purge apparmor

        Comment


          #5
          Ok, apparmor is gone. Probably a good thing. But kontact stilll does not work. Same error.

          If I launch it from a command line, I get

          $ kontact
          QDBusConnection: session D-Bus connection created before QCoreApplication. Application may misbehave.
          QDBusConnection: session D-Bus connection created before QCoreApplication. Application may misbehave.
          jon@jon-desktop:~$ kontact
          QDBusConnection: session D-Bus connection created before QCoreApplication. Application may misbehave.
          QDBusConnection: session D-Bus connection created before QCoreApplication. Application may misbehave.
          kontact(4631)/libakonadi Akonadi::AgentManagerPrivate::createDBusInterface: AgentManager failed to get a valid AgentManager DBus interface. Error is: 1 "org.freedesktop.DBus.Error.NameHasNoOwner" "Could not get owner of name 'org.freedesktop.Akonadi.Control': no such name"
          Connecting to deprecated signal QDBusConnectionInterface::serviceOwnerChanged(QStr ing,QString,QString)
          kontact(4631)/libakonadi Akonadi::SessionPrivate::socketError: Socket error occurred: "QLocalSocket::connectToServer: Invalid name"
          kontact(4631)/libakonadi Akonadi::SessionPrivate::socketError: Socket error occurred: "QLocalSocket::connectToServer: Invalid name"
          search paths: ("/usr/local/sbin", "/usr/local/bin", "/usr/sbin", "/usr/bin", "/sbin", "/bin", "/usr/games", "/usr/local/games", "/home/jon/jon-files/bin", "/home/jon/jon-files/jon-perl", "/home/jon/jon-files/jon-bin", "/usr/sbin", "/usr/local/sbin", "/usr/local/libexec", "/usr/libexec", "/opt/mysql/libexec", "/opt/local/lib/mysql5/bin", "/opt/mysql/sbin")
          Found mysql_install_db: "/usr/bin/mysql_install_db"
          Found mysqlcheck: "/usr/bin/mysqlcheck"
          Hspell: can't open /usr/share/hspell/hebrew.wgz.sizes.
          kontact(4631)/kdepimlibs (kpimidentities) KPIMIdentities::IdentityManager::readConfig: IdentityManager: There was no default identity. Marking first one as default.
          kontact(4631)/libakonadi Akonadi::SessionPrivate::socketError: Socket error occurred: "QLocalSocket::connectToServer: Invalid name"
          kontact(4631)/kdepimlibs (kpimidentities) KPIMIdentities::IdentityManager::readConfig: IdentityManager: There was no default identity. Marking first one as default.
          kontact(4631)/kdepimlibs (kpimidentities) KPIMIdentities::IdentityManager::readConfig: IdentityManager: There was no default identity. Marking first one as default.
          kontact(4631)/kdeui (KAction) KActionCollection::setComponentData: this does not work on a KActionCollection containing actions!

          ... and about 10 times that more of the same sort of thing. Later

          2015-06-26 08:27:30 4716 [Note] InnoDB: 5.6.24 started; log sequence number 2045922
          2015-06-26 08:27:30 4716 [Note] Server hostname (bind-address): '*'; port: 3306
          2015-06-26 08:27:30 4716 [Note] IPv6 is available.
          2015-06-26 08:27:30 4716 [Note] - '::' resolves to '::';
          2015-06-26 08:27:30 4716 [Note] Server socket created on IP: '::'.
          2015-06-26 08:27:30 4716 [ERROR] Can't start server: Bind on TCP/IP port: Address already in use
          2015-06-26 08:27:30 4716 [ERROR] Do you already have another mysqld server running on port: 3306 ?
          2015-06-26 08:27:30 4716 [ERROR] Aborting

          What's it doing with mysql?
          'I must have a prodigious quantity of mind; it takes me as much as a week sometimes to make it up.' Mark Twain

          Comment


            #6
            Akonadi uses a MySQL database for storing indexes and other metadata. Do you have another instance of MySQL running?

            Comment


              #7
              Yes, sure. I use mysql with Joomla. That has never been a problem.
              'I must have a prodigious quantity of mind; it takes me as much as a week sometimes to make it up.' Mark Twain

              Comment


                #8
                Normally Akonadi runs an "internal" MySQL server and talks to it over a unix socket. Yours seems to be attempting to communicate with some other MySQL instance via a TCP port. Did you change Akonadi's configuration in this way?

                Comment


                  #9
                  Originally posted by SteveRiley View Post
                  Normally Akonadi runs an "internal" MySQL server and talks to it over a unix socket. Yours seems to be attempting to communicate with some other MySQL instance via a TCP port. Did you change Akonadi's configuration in this way?
                  Not that I know of. In any case, I have no idea how to do that.

                  Might a reinstall of mysql help? It's kinduv annoying to do, but perfectly possible.

                  Thanks for your suggestions.
                  'I must have a prodigious quantity of mind; it takes me as much as a week sometimes to make it up.' Mark Twain

                  Comment


                    #10
                    I admit to being confused about mysql. Amarok also uses it, but seems to have its own copy hidden away. Is that correct?
                    'I must have a prodigious quantity of mind; it takes me as much as a week sometimes to make it up.' Mark Twain

                    Comment


                      #11
                      Please install the package akonadiconsole. Then run akonadiconsole from a console window. In the menu, choose Server -> Configure Server. Drag the bottom border of the window down to enlarge the window.

                      Does yours match this, or are the check boxes and fields filled in differently? If yours doesn't match, please post a screen shot.

                      Comment


                        #12
                        I installed the program, but when I run it, I get an error message "Failed to connect to database: Can't connect to local MySQL server through socket '/tmp/akonadi-jono6kr71.mysql.socket' (2) QMYSQL: Unable to connect". I click "Ok" twice on that message before the window comes up. When it does, it looks identical to yours except for the name of the socket and that it says at the bottom "The AKonadi server is not running", with "not" in bold characters.

                        Should I do something?
                        Attached Files
                        'I must have a prodigious quantity of mind; it takes me as much as a week sometimes to make it up.' Mark Twain

                        Comment


                          #13
                          What happens when you click the Start button?

                          Comment


                            #14
                            Originally posted by claydoh View Post
                            What happens when you click the Start button?
                            About the same thing I see when I try to start kontact.
                            'I must have a prodigious quantity of mind; it takes me as much as a week sometimes to make it up.' Mark Twain

                            Comment


                              #15
                              My screenshot got lost.
                              Attached Files
                              'I must have a prodigious quantity of mind; it takes me as much as a week sometimes to make it up.' Mark Twain

                              Comment

                              Working...
                              X