C-Command Software Forum

SpamSieve could not save the corpus file

I Noticed that SpamSieve was not picking up Spam after I tried to train it as such. Earlier I had a problem when I tried to add an item to the BlockList. The message was that it could not save changes to the Block List. After I just tried to train SpamSieve, I checked the SpamSieveLog and saw the following entry “Error: SpamSieve could not save the corpus file, perhaps due to lack of disk space or permissions.”

I have plenty of disk space available. As far as I know, I have the default set of permissions for my User personality.

The ~/Library/ApplicationSupport/SpamSieve folder has the following: Me Read & Write; staff Read only, everyone Read only.

What other files/folders do I need to check?

The above should be sufficient to save the Rules file. For the corpus, check the permissions on the Corpus.corpus package.

Still have a problem saving changes to corpus
Finder says SpamSieve Permissions are: (Me) Read & Write, staff Read Only everyone Read only
Corpus.compus Permissions are: (Me) Read & Write, staff Read Only everyone Read only

Both say I have custom access.

Using TinkerTool System 2, I get a more detailed look and both are the same
No ACL
POSIX has three entities
me with allow Read Data, Write Data and Traverse folder
staff with allow Read Data
Others with allow Read Data

However, after I edited my corpus by deleting all spam words that had last been used before 12/31/2009, the corpus could not be saved.
Console SpamSieve Log: “Error: SpamSieve could not save the corpus file, perhaps due to lack of disk space or permissions.

There are other files in SpamSieve folder that I wonder about because of their exceedingly old Date Modified.
Migrated Corpus.plist Aug 7, 2003
Tokenizer Log Aug 26, 2004
mydefaults Nov 14 2007

The False Negatives folder has files dating back to Dec 31, 1969
The Messages folder only has files modified on Nov 27, 2007

Please check the “All Messages” section of Console. It may have some more detailed error information.

This is all fine except for the dates on the “False Negatives” files. The dates on those don’t really matter except as an indication that at some point there was a problem with your drive or backup software.

Here is the console log info (This is from the All Message section of Console):

12/31/11 2:44:25.825 PM SpamSieve: Error saving message counts: <NSError Domain=NSCocoaErrorDomain Code=513 UserInfo={
MJTStackFrames = (
“+[NSPropertyListSerialization(MJT) mjtWritePropertyList:toURL:format:error:] (39)”
);
NSFilePath = “/Users/dtrippjr/Library/Application Support/SpamSieve/Corpus.corpus/Info.plist”;
NSLocalizedDescription = “You don\U2019t have permission to save the file \U201cInfo.plist\U201d in the folder \U201cCorpus.corpus\U201d.”;
NSLocalizedFailureReason = “You don\U2019t have permission.”;
NSLocalizedRecoverySuggestion = “To view or change permissions, select the item in the Finder and choose File > Get Info.”;
NSUnderlyingError = “<NSError Domain=NSPOSIXErrorDomain Code=13 UserInfo={
NSLocalizedDescription = “The operation couldn\U2019t be completed. Permission denied”;
NSLocalizedFailureReason = “Permission denied”;
}>”;
}>
12/31/11 2:44:25.844 PM SpamSieve: Error saving message store: <NSError Domain=NSCocoaErrorDomain Code=513 UserInfo={
NSFilePath = “/Users/dtrippjr/Library/Application Support/SpamSieve/Corpus.corpus/MessageIDs”;
NSLocalizedDescription = “You don\U2019t have permission to save the file \U201cMessageIDs\U201d in the folder \U201cCorpus.corpus\U201d.”;
NSLocalizedFailureReason = “You don\U2019t have permission.”;
NSLocalizedRecoverySuggestion = “To view or change permissions, select the item in the Finder and choose File > Get Info.”;
NSUnderlyingError = “<NSError Domain=NSPOSIXErrorDomain Code=13 UserInfo={
NSLocalizedDescription = “The operation couldn\U2019t be completed. Permission denied”;
NSLocalizedFailureReason = “Permission denied”;
}>”;
}>
12/31/11 2:44:27.494 PM SpamSieve: Error saving word store: <NSError Domain=NSCocoaErrorDomain Code=513 UserInfo={
NSFilePath = “/Users/dtrippjr/Library/Application Support/SpamSieve/Corpus.corpus/Words201”;
NSLocalizedDescription = “You don\U2019t have permission to save the file \U201cWords201\U201d in the folder \U201cCorpus.corpus\U201d.”;
NSLocalizedFailureReason = “You don\U2019t have permission.”;
NSLocalizedRecoverySuggestion = “To view or change permissions, select the item in the Finder and choose File > Get Info.”;
NSUnderlyingError = “<NSError Domain=NSPOSIXErrorDomain Code=13 UserInfo={
NSLocalizedDescription = “The operation couldn\U2019t be completed. Permission denied”;
NSLocalizedFailureReason = “Permission denied”;
}>”;
}>
12/31/11 2:44:27.495 PM SpamSieve: Error saving word store: SpamSieve could not save the corpus file, perhaps due to lack of disk space or permissions.

The OS is telling SpamSieve that you don’t have permission to write to these files. I’m not sure why that is, as it sounded like the Get Info window was showing acceptable permissions.

It might help to create new folder called CorpusNew. Open the Corpus.corpus package and copy the files therein into the CorpusNew folder. Then rename Corpus.corpus to CorpusOld and rename CorpusNew to Corpus.corpus.

Problem Solved
I had not looked at nor treated the Corpus as a package/folder. When I opened t and looked at the contents, I saw the problem. They had an ACL that denied certain operations. i.e., the contents had a different set of permissions than the folder. I just had to propagate the ownership and permissions of the folder. Tried it out and my problem is gone.

Thanks.