This forum has been archived. All content is frozen. Please use KDE Discuss instead.

Kmail / Akonadi cannot access POP3 connection after upgrade

Tags: None
(comma "," separated)
deljbox
Registered Member
Posts
5
Karma
0
System upgraded to: Debian Linux Kernel 4.19.0-6, Stable, KDE Plasma Desktop, Kontact PIM suite 5.9.3, Kmail 5.9.3.

Prior to upgrading everything was working in Kontact. There were no errors during upgrade, however I chose to keep customized config files (don't recall that being asked for Kontact). After system upgrade, which included Kontact suite, everything is working except KMail mail receiving.
Errors received:
Plasma notifications:
Unable to login to the server pop.provider.net.
Could not connect to host pop.provider.net: SSL negotiation failed.

Unable to login to the server pop.provider.net.
Your POP3 server claims to support TLS but negotiation was unsuccessful.
You can disable TLS in the POP account settings dialog.

Note: Fails using any handshake protocol.

Errors received while running KMail via Konsole:
t.qpa.xcb: QXcbConnection: XCB error: 8 (BadMatch), sequence: 4031, resource id: 119537704, major code: 130 (Unknown), minor code: 3
(Repeats by the hundreds with only the sequence value incrementing...)

QIODevice::read (QLocalSocket): device not open

Error loading plugin: "The shared library was not found."
Hspell: can't open /usr/share/hspell/hebrew.wgz.sizes.
sonnet.plugins.hspell: HSpellDict::HSpellDict: Init failed
No text-to-speech plug-ins were found.
(Don't care about this.)

It doesn't matter what POP3 login type is used, SSP or TLS, or trying various combinations of Connection Settings in Account / Receiving, including Restarting and trying new Account Receive resources. I have verified that the settings are correct via Thunderbird. Again, it worked prior to upgrade, now does not.

How to troubleshoot to determine what part of the Kontact/Akonadi or libraries may need to be re-configured or re-installed? Prefer not to have to uninstall/re-install Kontact suite, it's a PITA to get running the way I want it by doing that. What are some things I can try to determine root cause so I can fix this mail receive problem?

I am starting this thread because the usual search of the Universal Brain was not helpful. This is not a GMail thing, nor settings issue, nor IMAP, nor ad nauseum. Mail receive was working, now does not. Something in the Kontact/Akonadi upgrade didn't upgrade properly or broke something. Seeking help from someone(s) who knows enough about how the code works, troubleshooting steps to isolate the root cause, and recommend fix actions.
User avatar
raphaelra
Registered Member
Posts
209
Karma
0
OS
I don't have a quick and dirty solution for you, but ...

Did you check /var/log/messages or /var/log/syslog or journalctl for "helpfull" messages ?

I doubt that ...
t.qpa.xcb: QXcbConnection: XCB error: 8 (BadMatch), sequence: 4031, resource id: 119537704, major code: 130 (Unknown), minor code: 3
(Repeats by the hundreds with only the sequence value incrementing...)

... is the reason for the connection problem.

How about connection test with plain login / without SSL/TLS (just for test and if your mail provider supports this) ? To check if any certificate handlich may be the reason ...

What happends, when you click on "Serverinfo" in kmail's mail account configuration panel, "Advanced" tab ?
deljbox
Registered Member
Posts
5
Karma
0
raphaelra,

Thanks for replying. Those are good suggestions, it did prompt to think of some other ideas for things to try.

I also think the xcb error likely doesn't have anything to do with it. I just included what the command line showed for completeness. I found nothing in the logs that indicated a problem with Kmail. As originally mentioned, I tried various connection configurations with no success. Of note, however, prior to the upgrade the config Accounts/Receiving/Advanced/Connections Settings Auto Detect would correctly detect the POP3 server. After the upgrade, I get an 'Unable to connect to the server, please verify the server address.' error dialog box. The server address is correct (wasn't changed after the upgrade and is still correct).

There is no 'Serverinfo' button in the Accounts/Receiving/Advanced panel on the KMail I'm using.

I tried setting up a test account but keep getting the same 'Unable to connect to the server, please verify the server address.' error dialog box. That tells me something in the upgrade broke at least the POP3 server access part, maybe in the Akonadi POP3 Server resource piece. Again, receiving email is the only part not working, sending works fine (SMTP).

What I'm looking for is something like: '...here is(are) the library(ies) KMail uses to connect to a POP3 server, and here is how you can test them to see if they are working...' or something along similar lines. Or just trying to re-install those libraries. I will likely end up uninstalling / reinstalling KMail. Although I don't like such sledgehammer approaches to fixing things. It usually takes hours to get things working like I had them before an upgrade.
deljbox
Registered Member
Posts
5
Karma
0
Just re-installed (Synaptic 'mark for re-installation') all installed KMail and Akonadi files and libraries. No change.
Some things I've noticed:
1. During upgrade 'mariadb' was installed. Did Kontact switch from 'mysql' to 'mariadb'? How to tell what database Akonadi is using?
2. Via Synaptic, 'libkf5akonadiprivate5' did not have a 'Mark for re-installation' option. It does, however, have 'Mark suggested for installation' which suggests 'akonadi-server', which is already installed. When selecting 'akonadi-server', it says 'akonadi-server' has unresolved dependencies, which it does not ('akonadi-server' re-installed without issue).
a. Uninstalled 'libkf5akonadiprivate5' and it disappeared from the library listings (there is a 'libkf5akonadiprivate5abi2' library. Thinking 'libkf5akonadiprivate5' is a deprecated version of 'libkf5akonadiprivate5abi2', I re-installed 'libkf5akonadiprivate5abi2'. No change.
3. After above, stopped and started Akonadi using 'akonadictl' via command line with these results:
~$ akonadictl start
Connecting to deprecated signal QDBusConnectionInterface::serviceOwnerChanged(QString,QString,QString)
dennis@hplt2000:~$ akonadi.collectionattributetable OK
akonadi.collectionmimetyperelation OK
akonadi.collectionpimitemrelation OK
akonadi.collectiontable OK
akonadi.flagtable OK
akonadi.mimetypetable OK
akonadi.parttable OK
akonadi.parttypetable OK
akonadi.pimitemflagrelation OK
akonadi.pimitemtable OK
akonadi.pimitemtagrelation OK
akonadi.relationtable OK
akonadi.relationtypetable OK
akonadi.resourcetable OK
akonadi.schemaversiontable OK
akonadi.tagattributetable OK
akonadi.tagremoteidresourcerelationtable OK
akonadi.tagtable OK
akonadi.tagtypetable OK
Connecting to deprecated signal QDBusConnectionInterface::serviceOwnerChanged(QString,QString,QString)

4. Ran 'akonadictl fsck' with these results:
Looking for resources in the DB not matching a configured resource...
Looking for collections not belonging to a valid resource...
Checking collection tree consistency...
Looking for items not belonging to a valid collection...
Looking for item parts not belonging to a valid item...
Looking for item flags not belonging to a valid item...
Looking for overlapping external parts...
Verifying external parts...
Found 655 external files.
Found 3 external parts.
Found unreferenced external file: /home/xxxx/.local/share/akonadi/file_db_data/7362_r0
... repeated hundreds of times for different 'file_db_data/<nnnn>_r<n>'
Moved 652 unreferenced files to lost+found.
Checking size treshold changes...
Found 0 parts to be moved to external files
Found 0 parts to be moved to database
Looking for dirty objects...
Collection "Search" (id: 1) has no RID.
Collection "Last Search" (id: 545) has no RID.
Collection "OpenInvitations" (id: 547) has no RID.
Collection "DeclinedInvitations" (id: 548) has no RID.
Found 4 collections without RID.
Item "2218" in collection "329" has no RID.
Item "6327" in collection "326" has no RID.
Item "6328" in collection "326" has no RID.
Found 3 items without RID.
Found 0 dirty items.
Looking for rid-duplicates not matching the content mime-type of the parent collection
Checking xxxx_addressbook
Checking Birthdays & Anniversaries
Checking Calendar
Checking Local Folders
Checking Notes
Checking Search
Checking akonadi_vcarddir_resource_0
Checking mailroom
Checking DeclinedInvitations
Checking Last Search
Checking OpenInvitations
Checking drafts
Checking inbox
Checking outbox
Checking sent-mail
Checking templates
Checking trash
... continued through folders ...
Migrating parts to new cache hierarchy...
Checking search index consistency...
Skipping virtual Collection 1
Checking Collection 204 search index...
Collection 204 search index contains 6 orphan items. Scheduling reindexing
Checking Collection 326 search index...
... continued checks for hundreds more indexes, skipping some virtual collections ...
Flushing collection statistics memory cache...
Consistency check done.

5. Command line from Step 3, running 'akonadictl start', spewed hundreds of 'log_...' lines. After Step 4, 'akonadictl fsck', and re-trying to 'Get Mail', the 'log_...' lines describe log entries about email folders, but nothing about not being able to connect to the POP3 server. E.g.,:
log_mixedmaildir: Maildir "/home/xxxx/<folder>" "cur" directory newer than the index: cur modified at QDateTime(2019-02-07 20:57:31.739 MST Qt::TimeSpec(LocalTime)) , index modified at QDateTime(2015-09-14 20:15:55.000 MDT Qt::TimeSpec(LocalTime))
log_mixedmaildirresource: storeList->error= 0
log_mixedmaildir: Store fetch got 0 items of which 0 are new and 0 are changed and 0 need to be removed
log_mixedmaildir: 0 items marked as Deleted
log_mixedmaildir: Akonadi fetch got 8 items
log_mixedmaildir: of which 8 have remoteId
log_mixedmaildirresource: storeList->error= 0
log_mixedmaildir: Store fetch got 8 items of which 0 are new and 0 are changed and 0 need to be removed

6. Results of 'akonadictl status':
~$ akonadictl status
Akonadi Control: running
Akonadi Server: running
Akonadi Server Search Support: available (Remote Search, Akonadi Search Plugin)
Available Agent Types: akonadi_akonotes_resource, akonadi_archivemail_agent, akonadi_birthdays_resource, akonadi_contacts_resource, akonadi_davgroupware_resource, akonadi_ews_resource, akonadi_ewsmta_resource, akonadi_facebook_resource, akonadi_followupreminder_agent, akonadi_googlecalendar_resource, akonadi_googlecontacts_resource, akonadi_ical_resource, akonadi_icaldir_resource, akonadi_imap_resource, akonadi_indexing_agent, akonadi_invitations_agent, akonadi_kalarm_dir_resource, akonadi_kalarm_resource, akonadi_kolab_resource, akonadi_maildir_resource, akonadi_maildispatcher_agent, akonadi_mailfilter_agent, akonadi_mbox_resource, akonadi_migration_agent, akonadi_mixedmaildir_resource, akonadi_newmailnotifier_agent, akonadi_notes_agent, akonadi_notes_resource, akonadi_openxchange_resource, akonadi_pop3_resource, akonadi_sendlater_agent, akonadi_tomboynotes_resource, akonadi_vcard_resource, akonadi_vcarddir_resource
Note: 'akonadi_pop3_resource' is included.
deljbox
Registered Member
Posts
5
Karma
0
RESOLVED???
After further attempts to get it to work, e.g., modifying a Receive account in preparation for deleting and re-initializing an account I stumbled upon something that works, although I don't quite like it.
Using any Encryption mode, the Auto Detect feature fails to connect to the POP3 server.
However, setting it to None and NOT using Auto Detect, then saving the configuration now allows me to receive emails. A good thing.
Setting Encryption to None - not a good thing if that's what is truly going on.
It seems since the upgrade, KMail's POP3 server negotiation algorithm no longer correctly negotiates with POP3 servers. I recommend the developers look at the Thunderbird algorithm, since TB was able to correctly negotiate the proper SSL connection.
TB's settings show: SSL Port 995, SSL/TLS encryption, Normal Password as the Authentication Method.
I don't know what KMail's equivalent settings are, but when Auto Detect is used, the SSL button gets greyed out. KMail obviously can't fully negotiate a SSL connection.


Bookmarks



Who is online

Registered users: Bing [Bot], daret, Google [Bot], Sogou [Bot]