Bug 52751 - Compacting does not remove deleted emails
Summary: Compacting does not remove deleted emails
Status: RESOLVED WORKSFORME
Alias: None
Product: kmail
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: RedHat Enterprise Linux Linux
: NOR normal
Target Milestone: ---
Assignee: kdepim bugs
URL:
Keywords:
: 59273 59371 (view as bug list)
Depends on:
Blocks:
 
Reported: 2003-01-08 20:03 UTC by Joshua Trimm
Modified: 2007-09-14 12:17 UTC (History)
3 users (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 Joshua Trimm 2003-01-08 20:03:27 UTC
Version:            (using KDE KDE 3.0.4)
Installed from:    RedHat RPMs
OS:          Linux

When deleting a message from my inbox the message stays in my inbox mbox file. I compacted all folders afterwards and my home directory's are not mounted via nfs.
Compactable=true on all folders in my kmailrc and my trash folder is empty. I have tried re-opening kmail. The problem is all my user's kmail inbox's are growing huge when they have no messages in there. If i delete the .inbox.index the deleted messages come back to the inbox. How can i get these files out of the inbox mbox file?
Comment 1 cb-kde 2003-01-26 16:02:59 UTC
 
I have this same problem on a recent CVS from the KDE_3_1_BRANCH. 
 
Comment 2 Ingo Klöcker 2003-01-26 18:12:03 UTC
Subject: Re:  New: Compacting does not remove deleted emails

On Wednesday 08 January 2003 20:03, Joshua Trimm wrote:
> How can i get these files out of the inbox mbox file?

The following should work:
- Create a temporary backup folder
- Move all message from the Inbox that you want to keep to the backup 
folder
- Exit KMail
- Delete ~/Mail/inbox and ~/Mail/.inbox.index*
- Start KMail; the Inbox will be recreated
- Move all message from the backup folder back to the Inbox
- Delete the backup folder

BTW, you should use this opportunity to convert your inbox from mbox 
format to maildir format (maildir is the recommend format since it's 
much more robust than mbox and compaction isn't necessary with maildir 
since each message is in a file of its own). In order to convert your 
inbox from mbox format to maildir format all you have to do 
(additionally to the above steps) is to switch the default folder 
format to maildir (in Settings->Configure KMail...->Folders).

Comment 3 Colin Jensen 2003-05-30 21:30:36 UTC
This problem is not specific to inboxes.  Compact usually does nothing for me on mbox 
folders.  This is especially problematic since I have spam filed in a folder, I remove 
valid emails from the folder and compact it, and want to report the rest to Razor.  Since 
I have no way of compacting the folder, I can't remove the valid email so I cannot 
report to Razor. 
 
It used to be that at least "empty folder" actually emptied the folder, so you could "fix" 
the problem from within kmail.   
 
Above workaround (conversion to maildir format) is the only solution I know of. 
 
But.... why bother even HAVING a "compact folder" action that does absolutely 
nothing :-) 
Comment 4 Ingo Klöcker 2003-06-01 15:21:34 UTC
Subject: Re:  Compacting does not remove deleted emails

I just want to point out that in general compacting works. But sometimes 
KMail turns off compaction for a folder because it "thinks" that the 
index of this folder and its contents are out-of-sync. In this case 
compaction is disabled in order to prevent a trashed folder. You can 
check whether this is the case by looking at KMail's configuration file 
(usually in ~/.kde/share/config/kmailrc). If the settings of a folder 
include "Compactable=false" then KMail disabled compaction because of 
the aforementioned reason. You can try to change it to 
"Compactable=true" (while KMail isn't running).
Comment 5 Colin Jensen 2003-06-02 19:49:07 UTC
I retract my claim that compacting never works.   Before I converted my Inbox to 
maildir, I looked at the size of the mbox and it had obviously been compacted pretty 
efficiently. 
 
Ingo's comment above reveal the true problem I was having.  I was procmailing my 
spam into a separate directory, and then using a shell script periodically to insert them 
into a kmail-controlled mbox so I could verify the spams before reporting them. And 
then I would invoke my reporting script which would report and delete the emails in the 
spam mbox. 
 
I guess the workaround is either using maildirs for this kind of situation (external 
programs trying to "help" kmail) or wait until kmail has a system by which we can 
invoke an external spam-reporting system. 
 
Comment 6 Ingo Klöcker 2003-06-06 01:22:01 UTC
*** Bug 59273 has been marked as a duplicate of this bug. ***
Comment 7 Ingo Klöcker 2003-06-06 01:22:02 UTC
*** Bug 59371 has been marked as a duplicate of this bug. ***
Comment 8 Stephan Kulow 2003-09-24 08:39:02 UTC
so it works in general 
Comment 9 David Faure 2004-09-14 17:29:03 UTC
*** Bug 83773 has been marked as a duplicate of this bug. ***