You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@spamassassin.apache.org by bu...@bugzilla.spamassassin.org on 2008/05/07 10:09:10 UTC

[Bug 5899] New: sa-compile /var/lib dir should contain perl version in path

https://issues.apache.org/SpamAssassin/show_bug.cgi?id=5899

           Summary: sa-compile /var/lib dir should contain perl version in
                    path
           Product: Spamassassin
           Version: SVN Trunk (Latest Devel Version)
          Platform: Other
        OS/Version: All
            Status: NEW
          Severity: enhancement
          Priority: P5
         Component: sa-compile
        AssignedTo: dev@spamassassin.apache.org
        ReportedBy: jm@jmason.org


from Debian bug #479865:


Subject: Bug#479865: spamassassin: perl 5.10 issue with sa-compile
From: Paul Wise <pabs.debian.org>
Date: Wed, 07 May 2008 11:40:19 +0800
To: Debian Bug Tracking System <submit.bugs.debian.org>

Package: spamassassin
Version: 3.2.4-1
Severity: normal

> I couldn't get spamassassin to start after upgrading to perl
> 5.10.   Srangely it works with -D enabled, but then doesn't let you stop
> it. The issue seems to be a problem with sa-compile and a symbol removed
> from perl: Perl_Tstack_sp_ptr. I was able to fix it by removing
> body_0.so and then rerunning sa-compile. 

my response:


sa-compile output (including body_0.so etc.) is specific to the version of
perl it was built with.  The ABI for compiled perl XS modules changed
between 5.8.x and 5.10.x.  This is what caused the sa-compile output to
become unloadable once you upgraded perl.

We need to fix SpamAssassin to include part of the perl version string
("5.10" for 5.10.0, "5.8" for 5.8.x, etc.) in the pathname of the
sa-compile output to avoid this, I think.

In the meantime, deleting the /var/lib/spamassassin/compiled/ dir when
you upgrade perl, and re-running sa-compile, will avoid this.


-- 
Configure bugmail: https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

[Bug 5899] [review] sa-compile /var/ lib dir should contain perl version in path

Posted by bu...@bugzilla.spamassassin.org.
https://issues.apache.org/SpamAssassin/show_bug.cgi?id=5899


Justin Mason <jm...@jmason.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|sa-compile /var/lib dir     |[review] sa-compile /var/lib
                   |should contain perl version |dir should contain perl
                   |in path                     |version in path
  Status Whiteboard|                            |needs 2 votes for 3.2.5




--- Comment #6 from Justin Mason <jm...@jmason.org>  2008-05-21 02:03:23 PST ---
guys, let's get some votes/testing on this.  IMO this is a critical bug and the
best reason to push out a 3.2.5 in the short term...


-- 
Configure bugmail: https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

[Bug 5899] sa-compile /var/lib dir should contain perl version in path

Posted by bu...@bugzilla.spamassassin.org.
https://issues.apache.org/SpamAssassin/show_bug.cgi?id=5899





--- Comment #4 from Justin Mason <jm...@jmason.org>  2008-05-18 07:04:16 PST ---
Created an attachment (id=4318)
 --> (https://issues.apache.org/SpamAssassin/attachment.cgi?id=4318)
fix

please review for 3.2.x; applied to 3.3.0:

: jm 106...; svn commit -m "bug 5899: add perl version string to the storage
area for compiled rulesets, to avoid crashes when perl is upgraded between
major versions and the ABI breaks"
Sending        build/preprocessor
Sending        lib/Mail/SpamAssassin/Plugin/Rule2XSBody.pm
Sending        lib/Mail/SpamAssassin.pm
Sending        sa-compile.raw
Transmitting file data ....
Committed revision 657564.


-- 
Configure bugmail: https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

[Bug 5899] sa-compile /var/lib dir should contain perl version in path

Posted by bu...@bugzilla.spamassassin.org.
https://issues.apache.org/SpamAssassin/show_bug.cgi?id=5899


Justin Mason <jm...@jmason.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Severity|enhancement                 |major
           Priority|P5                          |P1




--- Comment #1 from Justin Mason <jm...@jmason.org>  2008-05-15 13:41:38 PST ---
bumping up pri, this is turning out to be quite troublesome; spamassassin
becomes entirely unusable once an upgrade to perl 5.10 takes place :(


-- 
Configure bugmail: https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

[Bug 5899] [review] sa-compile /var/ lib dir should contain perl version in path

Posted by bu...@bugzilla.spamassassin.org.
https://issues.apache.org/SpamAssassin/show_bug.cgi?id=5899


Doc Schneider <ma...@maddoc.net> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Status Whiteboard|needs 1 vote for 3.2.5      |can be comitted for 3.2.5




--- Comment #10 from Doc Schneider <ma...@maddoc.net>  2008-05-26 17:40:01 PST ---
double cool +1


-- 
Configure bugmail: https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

[Bug 5899] sa-compile /var/lib dir should contain perl version in path

Posted by bu...@bugzilla.spamassassin.org.
https://issues.apache.org/SpamAssassin/show_bug.cgi?id=5899


Justin Mason <jm...@jmason.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
Attachment #4318 is|0                           |1
           obsolete|                            |




--- Comment #5 from Justin Mason <jm...@jmason.org>  2008-05-18 07:07:03 PST ---
Created an attachment (id=4319)
 --> (https://issues.apache.org/SpamAssassin/attachment.cgi?id=4319)
fix for 3.2.x

actually, that patch was against trunk.  it didn't apply cleanly to 3.2.x. 
this one does...


-- 
Configure bugmail: https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

[Bug 5899] [review] sa-compile /var/ lib dir should contain perl version in path

Posted by bu...@bugzilla.spamassassin.org.
https://issues.apache.org/SpamAssassin/show_bug.cgi?id=5899





--- Comment #7 from Daryl C. W. O'Shea <sp...@dostech.ca>  2008-05-25 14:09:28 PST ---
(In reply to comment #3)
> Note that it does not attempt to load rulesets from the old location -- so
> "sa-compile" will need to be re-run after applying this patch. this is because,
> due to this bug, the old rulesets may cause SA to exit anyway! so better safe
> than sorry.

To clarify... if you have compiled rules under 5.8 and then upgrade to 5.10
without re-compiling the rules, will SA then proceed to use the un-compiled
rules (until you compile them using 5.10)?  I believe (from memory) this would
be how it works but you can't tell from the patch alone.




-- 
Configure bugmail: https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

[Bug 5899] [review] sa-compile /var/ lib dir should contain perl version in path

Posted by bu...@bugzilla.spamassassin.org.
https://issues.apache.org/SpamAssassin/show_bug.cgi?id=5899


Justin Mason <jm...@jmason.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED




--- Comment #11 from Justin Mason <jm...@jmason.org>  2008-05-27 02:22:08 PST ---
thanks guys! applied:

: jm 107...; svn commit -m "bug 5899: add perl version string to the storage
: jm 108... >>; area for compiled rulesets, to avoid crashes when perl is
upgraded between
: jm 108... >>; major versions and the ABI breaks"
Sending        build/preprocessor
Sending        lib/Mail/SpamAssassin/Plugin/Rule2XSBody.pm
Sending        lib/Mail/SpamAssassin.pm
Sending        sa-compile.raw
Transmitting file data ....
Committed revision 660442.


-- 
Configure bugmail: https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

[Bug 5899] sa-compile /var/lib dir should contain perl version in path

Posted by bu...@bugzilla.spamassassin.org.
https://issues.apache.org/SpamAssassin/show_bug.cgi?id=5899





--- Comment #3 from Justin Mason <jm...@jmason.org>  2008-05-18 07:02:41 PST ---
here we go.  this changes the sa-compile compiled-ruleset storage dir to
include the perl major version ("5.008" for 5.8.x, "5.010" for 5.10.x, "5.006"
for 5.6 etc).  This is because perl minor version changes are ABI-compatible,
but major version changes are not.

Note that it does not attempt to load rulesets from the old location -- so
"sa-compile" will need to be re-run after applying this patch. this is because,
due to this bug, the old rulesets may cause SA to exit anyway! so better safe
than sorry.


-- 
Configure bugmail: https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

[Bug 5899] sa-compile /var/lib dir should contain perl version in path

Posted by bu...@bugzilla.spamassassin.org.
https://issues.apache.org/SpamAssassin/show_bug.cgi?id=5899


Justin Mason <jm...@jmason.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|3.3.0                       |3.2.5




--- Comment #2 from Justin Mason <jm...@jmason.org>  2008-05-16 08:56:40 PST ---
this needs to be fixed in 3.2.x and 3.3.0 IMO (thanks for pointing it out
Warren)


-- 
Configure bugmail: https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

[Bug 5899] [review] sa-compile /var/ lib dir should contain perl version in path

Posted by bu...@bugzilla.spamassassin.org.
https://issues.apache.org/SpamAssassin/show_bug.cgi?id=5899





--- Comment #8 from Justin Mason <jm...@jmason.org>  2008-05-26 01:57:54 PST ---
(In reply to comment #7)
> (In reply to comment #3)
> > Note that it does not attempt to load rulesets from the old location -- so
> > "sa-compile" will need to be re-run after applying this patch. this is because,
> > due to this bug, the old rulesets may cause SA to exit anyway! so better safe
> > than sorry.
> 
> To clarify... if you have compiled rules under 5.8 and then upgrade to 5.10
> without re-compiling the rules, will SA then proceed to use the un-compiled
> rules (until you compile them using 5.10)?  I believe (from memory) this would
> be how it works but you can't tell from the patch alone.

Currently: any invocation of a tool that uses Mail::SpamAssassin will exit with
an un-catchable fatal error from the perl interpreter.

With this patch: SA will use the un-compiled rules (until you compile them
using sa-compile and perl 5.10).

--j.


-- 
Configure bugmail: https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

[Bug 5899] [review] sa-compile /var/ lib dir should contain perl version in path

Posted by bu...@bugzilla.spamassassin.org.
https://issues.apache.org/SpamAssassin/show_bug.cgi?id=5899


Daryl C. W. O'Shea <sp...@dostech.ca> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Status Whiteboard|needs 2 votes for 3.2.5     |needs 1 vote for 3.2.5




--- Comment #9 from Daryl C. W. O'Shea <sp...@dostech.ca>  2008-05-26 14:57:44 PST ---
cool, +1


-- 
Configure bugmail: https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.