Cleaning up "dirty" items reported by akonadictl fsck

Jos van den Oever jos at vandenoever.info
Thu Aug 19 19:33:33 BST 2021


Hello David,

(sorry for the formatting, this is sent from webmail)

I'm not familiar with a good workaround but am familiar with the 
struggles of cleaning up Akonadi. I've done it often and it is never 
easy.

In fact since a week, akonadi refuses to start. It gives this error:

===

Error    : Table 'akonadi.pimitemtable' doesn't exist in engine
status   : Operation failed
===

There are reports that this is caused by a MariaDB update, but I'm not 
sure about that, because I'm on mariadb-server-10.5.11 with 
mariadb-connector-c-3.1.13, not libmariadb 3.2.

  https://old.reddit.com/r/kde/comments/p5d4bc/kmail_completely_broken/

akonadictl fsck will not run because akonadi is not running: a catch 22 
situation.

So, while this is no help to you, I would like to say that the 
documentation work is much appreciated!

Jos

David Bryant schreef op 2021-08-15 17:33:

> I'm currently working on Chapter 7 ("Troubleshooting") of the KMail
> documentation. It's almost done, except for some advice on dealing with
> "dirty" items in the akonadi/mysql database files.
> 
> This problem is documented as a bug: https://bugs.kde.org/show_bug.cgi?
> id=436550 I have a workaround, but it's quite laborious.
> 
> The problem is present if and when one obtains terminal output like 
> this.
> 
> ~ $ akonadictl fsck 2>&1 | grep ^Found
> Found 5 external files.
> Found 5 external parts.
> Found no unreferenced external files.
> Found 0 parts to be moved to external files
> Found 0 parts to be moved to database
> Found 6 collections without RID.
> Found 3 items without RID.
> Found 3001 dirty items.
> ~ $
> 
> From time to time akonadictl reports 1 dirty item, which KMail/akonadi 
> is
> apparently  able to patch up somehow.  But when I (some way or another) 
> got
> bitten by ~3,000 dirty items last April, KMail became practically 
> unuseable
> (lots of messages could not be accessed, although they were displayed 
> in the
> Message List).
> 
> Anyway, I'm hoping some clever programmer out there can think of an 
> easier way
> to fix this problem (when it occurs) than the method I devised. I 
> backed up all
> my email messages, deleted everything from the 
> ~/.local/share/local-mail/
> directory, then started KMail. Akonadi erased all its DB files when it 
> synced
> with an empty tree. That eliminated the "dirty" items. Then I closed 
> KMail &
> akonadi and restored the backup copy of all my messages. When I 
> restarted
> KMail, akonadi rebuilt the mysql DB files cleanly. But I lost some 
> auxiliary
> information (special folder properties, for instance), and some of my 
> mail
> filter rules had to be reconstructed. So it was a lot of work. Is there 
> a
> simpler way to fix the "dirty" items when they arrive en masse?
> 
> Thanks. Any and all suggestions are welcome.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-pim/attachments/20210819/04e7e069/attachment.htm>


More information about the kde-pim mailing list