Kmail opens same window hundreds of times on start

When kmail is started up, it opens the same message window hundreds of times and is unusable. It will keep opening this window until the app is killed. Is there some place I can reset the data or erase the offending email or reset kmail itself? Is there some other procedure I can use to stop this behavior?

Thanks.

Take a look in ‘~/.cache/kontact/messagelist/threading/’ – remove everything that’s in there and, restart Kontact.
Also, execute

 > akonadictl fsck 2>&1| grep -iE 'found|no RID'

and

 > akonadictl vacuum

I hope that, the above Akonadi housekeeping will be sufficient – if it ain’t, we’ll have to begin with the MariaDB – there was a patch a day or so ago …

I couldn’t find the directory you specified, but it did give me a clue. I found ~/.local/kmail2/autosave and deleted the contents of that directory. ****** and vacuumed akonadi and now everything seems ok. Thanks.

Hmmm – The only directory below my ~/.local/ is “share” – but, my ‘~/.local/share/kmail2/autosave/’ is empty …

  • Possibly because, I always start Kontact, rather than, the individual components …
karl@erlangen:~> find  ~/.config/  -name kmail*       
/home/karl/.config/session/kmail2_10d3d9d1cf000164956913000000013450010_1657769643_102667 
/home/karl/.config/kmailsearchindexingrc 
/home/karl/.config/kmail2rc 
karl@erlangen:~> cat /home/karl/.config/session/kmail2_10d3d9d1cf000164956913000000013450010_1657769643_102667 
[1] 
docked=true 

[Number] 
NumberOfWindows=1 

[WindowProperties1] 
ClassName=KMMainWin 
HDMI-A-0 Height 3840x2160=2019 
HDMI-A-0 Width 3840x2160=3840 
HDMI-A-0 XPosition 3840x2160=0 
HDMI-A-0 YPosition 3840x2160=61 
ObjectName=kmail-mainwindow#1 
RestorePositionForNextInstance=false 
State=AAAA/wAAAAD9AAAAAAAADwAAAAdOAAAABAAAAAQAAAAIAAAACPwAAAABAAAAAgAAAAEAAAAWAG0AYQBpAG4AVABvAG8AbABCAGEAcgEAAAAA/////wAAAAAAAAAA 
karl@erlangen:~> 

Try to remove the session file.

My mistake. It should have been ~/.local/share/kmail2/autosave/. This had 196 files all created at almost the same time. After eliminating them, no more have been created and things seem to be working normally. I did this before karlmistelberger suggested to remove the session file. I don’t know whether that would have worked or not, but I certainly appreciate the suggestion.

Thanks for the feedback. Developers are very terse regarding configuration files. KDE uses lots of them and it’s a big annoyance to identify them all.