keithc

Member
Jun 5, 2007
14
0
151
Hi,

Here is my Cpanel Version Info

WHM 11.23.2 cPanel 11.23.3-C25946
CENTOS Enterprise 4.6 x86_64 on standard - WHM X v3.1.0
Spamassassin 3.2.4

Anytime I restart Exim, I receive the following errors.

Code:
1.  Can't locate Mail/SpamAssassin/CompiledRegexps/body_0.pm in @INC

I tried to copy body_0.pm from another location but it still could not load that module. Assuming it was built for another version of Spamassassin? I notice when I look for the Perl module called Mail::SpamAssassin::CompiledRegexps::body_0 but it doesn't seem to exist anymore?

2.  

rules: failed to run CG_FUJI_JPG test, skipping:
        (Can't locate object method "image_name_regex" via package "Mail::SpamAssassin::PerMsgStatus" at (eval 639) line 732.
)
rules: failed to run CG_DOUBLEDOT_GIF test, skipping:
        (Can't locate object method "image_name_regex" via package "Mail::SpamAssassin::PerMsgStatus" at (eval 639) line 865.
)
rules: failed to run CG_SONY_JPG test, skipping:
        (Can't locate object method "image_name_regex" via package "Mail::SpamAssassin::PerMsgStatus" at (eval 639) line 1343.
)
rules: failed to run CG_CANON_JPG test, skipping:
        (Can't locate object method "image_name_regex" via package "Mail::SpamAssassin::PerMsgStatus" at (eval 639) line 2235.
)

I know I can comment these rules out but this issue has been around for a while

3.  

BEGIN failed--compilation aborted at /scripts/test_sa_compiled line 19.
Mail::SpamAssassin::Plugin::Rule2XSBody is not available: disabled
I have the perl module for Rule2XSBody loaded but I'm not sure why it isn't working?

Anyone else experience these issues?

Thanks,

Keith
 
Last edited by a moderator:

Bruce

Well-Known Member
Oct 4, 2001
146
0
316
Same problem here to:

cPanel 11.23.3-S25959

This module is required by cPanel, and the system may not function correctly until it is installed, and functional. Below is the results of the auto-install attempt:

Code:
Test Run
==============
Can't locate Encode/Detect/Detector.pm in @INC (@INC contains: /usr/lib/perl5/5.8.8/i686-linux /usr/lib/perl5/5.8.8 /usr/lib/perl5/site_perl/5.8.8/i686-linux /usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl5/site_perl/5.8.7/i686-linux /usr/lib/perl5/site_perl/5.8.7 /usr/lib/perl5/site_perl/5.6.2 /usr/lib/perl5/site_perl/5.6.1 /usr/lib/perl5/site_perl/5.6.0 /usr/lib/perl5/site_perl .) at - line 1.
BEGIN failed--compilation aborted at - line 1
+++++++++++++++++++++++++++++++++++++++++++++++
Can't locate Mail/SpamAssassin/CompiledRegexps/body_0.pm in @INC (@INC contains: /var/lib/spamassassin/compiled/3.002004 /var/lib/spamassassin/compiled/3.002004 /scripts /usr/lib/perl5/5.8.8/i686-linux /usr/lib/perl5/5.8.8 /usr/lib/perl5/site_perl/5.8.8/i686-linux /usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl5/site_perl/5.8.7/i686-linux /usr/lib/perl5/site_perl/5.8.7 /usr/lib/perl5/site_perl/5.6.2 /usr/lib/perl5/site_perl/5.6.1 /usr/lib/perl5/site_perl/5.6.0 /usr/lib/perl5/site_perl .) at /scripts/test_sa_compiled line 19.
BEGIN failed--compilation aborted at /scripts/test_sa_compiled line 19.
Mail::SpamAssassin::Plugin::Rule2XSBody is not available: disabled
 
Last edited by a moderator:

lukaschemp

Active Member
Nov 6, 2006
28
0
151
Same here:

cPanel 11.23.3-R25903

Code:
Can't load '/var/lib/spamassassin/compiled/3.002004/auto/Mail/SpamAssassin/CompiledRegexps/body_0/body_0.so' for module Mail::SpamAssassin::CompiledRegexps::body_0: /var/lib/spamassassin/compiled/3.002004/auto/Mail/SpamAssassin/CompiledRegexps/body_0/body_0.so: undefined symbol: PL_stack_sp at /usr/lib64/perl5/5.8.8/x86_64-linux-thread-multi/XSLoader.pm line 70.
 at /var/lib/spamassassin/compiled/3.002004/Mail/SpamAssassin/CompiledRegexps/body_0.pm line 314
BEGIN failed--compilation aborted at /var/lib/spamassassin/compiled/3.002004/Mail/SpamAssassin/CompiledRegexps/body_0.pm line 315.
Compilation failed in require at /scripts/test_sa_compiled line 19.
BEGIN failed--compilation aborted at /scripts/test_sa_compiled line 19.
plugin: failed to parse plugin (from @INC): Can't locate BSD/Resource.pm in @INC (@INC contains: /usr/lib/perl5/site_perl/5.8.8 /usr/lib64/perl5/site_perl/5.8.8/x86_64-linux-thread-multi /usr/lib64/perl5/site_perl/5.8.7/x86_64-linux-thread-multi /usr/lib64/perl5/site_perl/5.8.6/x86_64-linux-thread-multi /usr/lib64/perl5/site_perl/5.8.5/x86_64-linux-thread-multi /usr/lib/perl5/site_perl/5.8.7 /usr/lib/perl5/site_perl/5.8.6 /usr/lib/perl5/site_perl/5.8.5 /usr/lib/perl5/site_perl /usr/lib64/perl5/vendor_perl/5.8.8/x86_64-linux-thread-multi /usr/lib64/perl5/vendor_perl/5.8.7/x86_64-linux-thread-multi /usr/lib64/perl5/vendor_perl/5.8.6/x86_64-linux-thread-multi /usr/lib64/perl5/vendor_perl/5.8.5/x86_64-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.8 /usr/lib/perl5/vendor_perl/5.8.7 /usr/lib/perl5/vendor_perl/5.8.6 /usr/lib/perl5/vendor_perl/5.8.5 /usr/lib/perl5/vendor_perl /usr/lib64/perl5/5.8.8/x86_64-linux-thread-multi /usr/lib/perl5/5.8.8) at /usr/lib/perl5/site_perl/5.8.8/Mail/SpamAssassin/Plugin/ResourceLimits.pm line 30.
BEGIN failed--compilation aborted at /usr/lib/perl5/site_perl/5.8.8/Mail/SpamAssassin/Plugin/ResourceLimits.pm line 30.
Compilation failed in require at (eval 538) line 1.

[28419] info: config: failed to parse line, skipping, in "/etc/mail/spamassassin/local.cf": resource_limit_mem 134217728
[28419] info: generic: base extraction starting. this can take a while...
[28419] info: generic: extracting from rules of type body_0
100% [===============================================================] 14034.49 rules/sec 00m00s DONE
100% [===============================================================] 777.73 bases/sec 00m01s DONE
[28419] info: body_0: 677 base strings extracted in 1 seconds
sa-compile: not compiling; 'spamassassin --lint' check failed!
Can't load '/var/lib/spamassassin/compiled/3.002004/auto/Mail/SpamAssassin/CompiledRegexps/body_0/body_0.so' for module Mail::SpamAssassin::CompiledRegexps::body_0: /var/lib/spamassassin/compiled/3.002004/auto/Mail/SpamAssassin/CompiledRegexps/body_0/body_0.so: undefined symbol: PL_stack_sp at /usr/lib64/perl5/5.8.8/x86_64-linux-thread-multi/XSLoader.pm line 70.
 at /var/lib/spamassassin/compiled/3.002004/Mail/SpamAssassin/CompiledRegexps/body_0.pm line 314
BEGIN failed--compilation aborted at /var/lib/spamassassin/compiled/3.002004/Mail/SpamAssassin/CompiledRegexps/body_0.pm line 315.
Compilation failed in require at /scripts/test_sa_compiled line 19.
BEGIN failed--compilation aborted at /scripts/test_sa_compiled line 19.
Mail::SpamAssassin::Plugin::Rule2XSBody is not available: disabled
@edit

/scripts/upcp --force fixed the problem
 
Last edited:

Bruce

Well-Known Member
Oct 4, 2001
146
0
316
/scripts/upcp --force cPanel 11.23.3-S25971 / cPanel 11.23.3-E25972

This module is required by cPanel, and the system may not function correctly until it is installed, and functional. Below is the results of the auto-install attempt:

Code:
Test Run
==============
Can't locate Encode/Detect/Detector.pm in @INC (@INC contains: /usr/lib/perl5/5.8.8/i686-linux /usr/lib/perl5/5.8.8 /usr/lib/perl5/site_perl/5.8.8/i686-linux /usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl5/site_perl/5.8.7/i686-linux /usr/lib/perl5/site_perl/5.8.7 /usr/lib/perl5/site_perl/5.6.2 /usr/lib/perl5/site_perl/5.6.1 /usr/lib/perl5/site_perl/5.6.0 /usr/lib/perl5/site_perl .) at - line 1.
BEGIN failed--compilation aborted at - line 1.


Installer Run
==============
~~~~~~~~~~~
ion (.) or string at /usr/lib/perl5/5.8.8/ExtUtils/ParseXS.pm line 508, <GEN36> line 71.
cc -Isrc -I/usr/lib/perl5/5.8.8/i686-linux/CORE -DXS_VERSION="1.01" -DVERSION="1.01" -fpic -x c++ -Iinclude -c -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O2 -o lib/Encode/Detect/Detector.o lib/Encode/Detect/Detector.c
lib/Encode/Detect/Detector.c:79: parse error before `__attribute__'
lib/Encode/Detect/Detector.c: In function `void 
XS_Encode__Detect__Detector_new (...)':
lib/Encode/Detect/Detector.c:80: parse error before `__attribute__'
lib/Encode/Detect/Detector.c: In function `void 
XS_Encode__Detect__Detector_new (...)':
lib/Encode/Detect/Detector.c:80: redefinition of `void 
XS_Encode__Detect__Detector_new (...)'
lib/Encode/Detect/Detector.c:79: `void XS_Encode__Detect__Detector_new 
(...)' previously defined here
lib/Encode/Detect/Detector.c: In function `void 
XS_Encode__Detect__Detector_new (...)':
lib/Encode/Detect/Detector.c:85: register name not specified for `SV 
**mark'
lib/Encode/Detect/Detector.c:85: `sp' undeclared (first use this 
function)
lib/Encode/Detect/Detector.c:85: (Each undeclared identifier is 
reported only once for each function it appears in.)
lib/Encode/Detect/Detector.c:87: parse error before `if'
lib/Encode/Detect/Detector.c:89: parse error before `void'
lib/Encode/Detect/Detector.c:94: ISO C++ forbids declaration of 
`RETVAL' with no type
lib/Encode/Detect/Detector.c:94: conflicting types for `int RETVAL'
lib/Encode/Detect/Detector.c:92: previous declaration as `Detector 
*RETVAL'
lib/Encode/Detect/Detector.c:94: cannot convert `Detector *' to `int' 
in initialization
lib/Encode/Detect/Detector.c:95: ISO C++ forbids declaration of 
`PL_stack_base' with no type
lib/Encode/Detect/Detector.c:95: variable-size type declared outside of 
any function
lib/Encode/Detect/Detector.c:95: type mismatch with previous external 
decl
/usr/lib/perl5/5.8.8/i686-linux/CORE/thrdvar.h:42: previous external decl of `SV **PL_stack_base'
lib/Encode/Detect/Detector.c:95: invalid initializer
lib/Encode/Detect/Detector.c:96: `CLASS' undeclared (first use this 
function)
lib/Encode/Detect/Detector.c:96: ISO C++ forbids declaration of 
`Perl_sv_setref_pv' with no type
lib/Encode/Detect/Detector.c:96: `int Perl_sv_setref_pv' redeclared as 
different kind of symbol
/usr/lib/perl5/5.8.8/i686-linux/CORE/proto.h:1229: previous declaration of `SV *Perl_sv_setref_pv (SV 
*, const char *, void *)'
lib/Encode/Detect/Detector.c:96: initializer list being treated as 
compound expression
lib/Encode/Detect/Detector.c:98: parse error before `}'
lib/Encode/Detect/Detector.c:99: ISO C++ forbids declaration of 
`PL_stack_sp' with no type
lib/Encode/Detect/Detector.c:99: type mismatch with previous external 
decl
/usr/lib/perl5/5.8.8/i686-linux/CORE/thrdvar.h:34: previous external decl of `SV **PL_stack_sp'
lib/Encode/Detect/Detector.c:99: `tmpXSoff' undeclared (first use this 
function)
lib/Encode/Detect/Detector.c:99: parse error before `return'
lib/Encode/Detect/Detector.c:103: parse error before `__attribute__'
lib/Encode/Detect/Detector.c: In function `void 
XS_Encode__Detect__Detector_DESTROY (...)':
lib/Encode/Detect/Detector.c:104: parse error before `__attribute__'
lib/Encode/Detect/Detector.c: In function `void 
XS_Encode__Detect__Detector_DESTROY (...)':
lib/Encode/Detect/Detector.c:104: redefinition of `void 
XS_Encode__Detect__Detector_DESTROY (...)'
lib/Encode/Detect/Detector.c:103: `void 
XS_Encode__Detect__Detector_DESTROY (...)' previously defined here
lib/Encode/Detect/Detector.c: In function `void 
XS_Encode__Detect__Detector_DESTROY (...)':
lib/Encode/Detect/Detector.c:109: redefinition of `I32 ax'
lib/Encode/Detect/Detector.c:85: `I32 ax' previously defined here
lib/Encode/Detect/Detector.c:109: multiple initializations given for 
`ax'
lib/Encode/Detect/Detector.c:109: redefinition of `SV **mark'
lib/Encode/Detect/Detector.c:85: `SV **mark' previously defined here
lib/Encode/Detect/Detector.c:109: cannot convert `int *' to `SV **' in 
initialization
lib/Encode/Detect/Detector.c:109: redefinition of `I32 items'
lib/Encode/Detect/Detector.c:85: `I32 items' previously defined here
lib/Encode/Detect/Detector.c:111: parse error before `if'
lib/Encode/Detect/Detector.c:113: parse error before `void'
lib/Encode/Detect/Detector.c:121: ISO C++ forbids declaration of 
`PL_stack_sp' with no type
lib/Encode/Detect/Detector.c:121: redefinition of `int PL_stack_sp'
lib/Encode/Detect/Detector.c:99: `int PL_stack_sp' previously defined 
here
lib/Encode/Detect/Detector.c:121: parse error before `return'
lib/Encode/Detect/Detector.c:126: ISO C++ forbids declaration of 
`PL_stack_sp' with no type
lib/Encode/Detect/Detector.c:126: redefinition of `int PL_stack_sp'
lib/Encode/Detect/Detector.c:121: `int PL_stack_sp' previously defined 
here
lib/Encode/Detect/Detector.c:126: parse error before `return'
lib/Encode/Detect/Detector.c:130: parse error before `__attribute__'
lib/Encode/Detect/Detector.c: In function `void 
XS_Encode__Detect__Detector_handle (...)':
lib/Encode/Detect/Detector.c:131: parse error before `__attribute__'
lib/Encode/Detect/Detector.c: In function `void 
XS_Encode__Detect__Detector_handle (...)':
lib/Encode/Detect/Detector.c:131: redefinition of `void 
XS_Encode__Detect__Detector_handle (...)'
lib/Encode/Detect/Detector.c:130: `void 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
lib/Encode/Detect/Detector.c:305: parse error before `return'
lib/Encode/Detect/Detector.xs: In function `void 
__static_initialization_and_destruction_0 (int, int)':
lib/Encode/Detect/Detector.xs:55: confused by earlier errors, bailing 
out
error building lib/Encode/Detect/Detector.o from 'lib/Encode/Detect/Detector.c' at /usr/lib/perl5/site_perl/5.8.8/ExtUtils/CBuilder/Base.pm line 110.
make: *** [all] Error 2
  JGMYERS/Encode-Detect-1.01.tar.gz
  /usr/bin/make -- NOT OK
Running make install
  Make had returned bad status, install seems impossible
perlmod--Install done
 
Last edited by a moderator:

rrwh

Well-Known Member
Oct 2, 2004
48
0
156
fixed...

Fixed the upcp errors -

I updated Mail::SpamAssassin::Plugin::Rule2XSBody perl module and re-ran upcp and it "finished" things off.

Ran upcp a 2nd time and it didn't give me the errors.

now, the output is


Hostname Virtual Host is already setup
...Done

Updating services & databases...PHP version file is up to date
Mail::SpamAssassin::Plugin::Rule2XSBody test passed: enabled
Ftp Quota Check v1.6
 

Bdzzld

Well-Known Member
Apr 3, 2004
412
5
168
Code:
/scripts/upcp --force
did not correct the problem for me on 11.23.3-STABLE_25971.

I updated Mail::SpamAssassin::Plugin::Rule2XSBody perl module
How did you do this exactly ? Manually or via WHM/cPanel ?
 
Last edited:

rrwh

Well-Known Member
Oct 2, 2004
48
0
156
Code:
/scripts/upcp --force
did not correct the problem for me on 11.23.3-STABLE_25971.



How did you do this exactly ? Manually or via WHM/cPanel ?
I just did it via WHM and then I had to do an upcp twice to eliminate all errors.

I had the same issues as you and upcp --force did not work for me either, and that is why I tried to update the perl modules that reported in the log output and that was the one that worked.

I also did the upcp via WHM
 

Bdzzld

Well-Known Member
Apr 3, 2004
412
5
168
I entered the following :

Code:
/scripts/perlinstaller --force Mail::SpamAssassin::Plugin::Rule2XSBody
and it seemed to install w.o. problems. After a restart of Exim the error still popped up:

Code:
[email protected] [~]# service exim restart
Shutting down clamd:                                       [  OK  ]
Shutting down exim:                                        [  OK  ]
Shutting down spamd:                                       [  OK  ]
Starting clamd:                                            [  OK  ]
Starting exim-26:                                          [  OK  ]
Starting exim:                                             [  OK  ]
Starting exim-smtps:                                       [  OK  ]
Can't locate Mail/SpamAssassin/CompiledRegexps/body_0.pm in @INC (@INC contains: /var/lib/spamassassin/compiled/3.002004 /var/lib/spamassassin/compiled/3.002004 /scripts /usr/lib/perl5/5.8.8/x86_64-linux /usr/lib/perl5/5.8.8 /usr/lib/perl5/site_perl/5.8.8/x86_64-linux /usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl5/site_perl/5.8.7/x86_64-linux /usr/lib/perl5/site_perl/5.8.7 /usr/lib/perl5/site_perl/5.8.5 /usr/lib/perl5/site_perl/5.8.4 /usr/lib/perl5/site_perl/5.8.3 /usr/lib/perl5/site_perl/5.8.2 /usr/lib/perl5/site_perl/5.8.1 /usr/lib/perl5/site_perl/5.8.0 /usr/lib/perl5/site_perl/5.6.2 /usr/lib/perl5/site_perl .) at /scripts/test_sa_compiled line 19.
BEGIN failed--compilation aborted at /scripts/test_sa_compiled line 19.
Mail::SpamAssassin::Plugin::Rule2XSBody is not available: disabled
Any one got any ideas on how to solve this ?
 

Bdzzld

Well-Known Member
Apr 3, 2004
412
5
168
I'd expect cPanel to come up with a solution as this is (still) occurring in 75% of all cPanel servers despite my efforts :mad:
 

Bdzzld

Well-Known Member
Apr 3, 2004
412
5
168
The issue was resolved by creating a trouble ticket @ cPanel :

It is usually resolved with sa-compile command for this to stop. But it seems your system do not have re2c installed, so we have installed it using buildre2c in /usr/local/cpanel/src/3rdparty/mit/buildre2c.

Once the re2c was installed, I am able to run sa-compile which resolves this.
 

Bdzzld

Well-Known Member
Apr 3, 2004
412
5
168
Hi David,

That's correct, but your Support Dept. would greatly benefit from leaving the solution to a common problem here. As shown a post later, a ticket was indeed created.

cPanel suggests to look for a solution at the forums before filing a ticket. If the solution was already entered here, there would no longer be a means for creating the ticket and server owners would be able to correct the problem themselves. Hope you understand my reasoning...

Regards.
 
Last edited:

cPanelDavidG

Technical Product Specialist
Nov 29, 2006
11,212
13
313
Houston, TX
cPanel Access Level
Root Administrator
Hi David,

That's correct, but your Support Dept. would greatly benefit from leaving the solution to a common problem here. As shown a post later, a ticket was indeed created.
Sometimes a common problem has diverse causes. Hence we use our ticket system to ensure we make a proper diagnosis and proper resolution for your specific server. Additionally, our technical analysts can report trends in common diagnoses to our quality assurance team should our software need overall modification.

You can submit a ticket at: http://ticket.cPanel.net/submit

Of course, you are under no obligation to submit a ticket. However, not submitting a ticket means that your issue is likely to remain unresolved.

cPanel suggests to look for a soluiotn at the forums before filing a ticket. If the solution was already entered here, there would no longer be a means for creating the ticket and server owners would be able to correct the problem themselves. Hope you understand my reasoning...

Regards.
Can you let me know where you heard this so I can have the appropriate verbiage adjusted?
 

dminus

Registered
Jul 3, 2008
1
0
51
Fix, I think

Boy this one is lots of fun!

The problem is related to the SpamAssassin 3.2.5 update, released on 2008-06-12. cPanel tries to force the version to 3.2.4, which causes version inconsistencies (especially if you happen to have 2 or more versions of Perl installed!). cPanel and stock Perl seem to use different values for the @INC paths... not to mention the fact that on this particular client's machine alone, there exist THREE versions of Perl (5.8.5, .7, .8).

This is pretty silly, considering the importance of Perl in cPanel/WHM... maybe use your own instance independent of the rest of the OS, like Plesk does with PHP? (of course the fact that /scripts is full of obsolete cruft is not very helpful to this end)

To fix it, here's what I did (possibly bad, but I don't think so):

- Open up /home/.cpcpan/RELEASE/modules.versions
(or wherever modules.versions is in /home/.cpcpan)

- Change SpamAssassin's setting to look like:
Code:
Mail::SpamAssassin=3.2.5
- Reinstall SpamAssassin using cPanel script (will upgrade to 3.2.5):
Code:
[[email protected] ~]# /scripts/installspam
- Reinstall SpamAssassin using CPAN from commandline, to ensure all SA instances are v3.2.5:
Code:
[[email protected] ~]# cpan
CPAN: File::HomeDir loaded ok (v0.80)

cpan[1]> install Mail::SpamAssassin
- Restart SpamAssassin, using cPanel script to rebuild body_0.so/.pm and confirm everything works:


And you're off to the races.

re2c is not the culprit -- my compile never failed until XSLoader/DynaLoader. Rebuilding re2c using the script in /usr/local/cpanel required me to fix this script's hard-coded version, as 1.3.3 is not available from the re2c project page (latest: 1.3.5). The rebuild did not correct the problem as reported earlier in this thread.

It would be nice to have some sort of public discussion with cP staff on this problem, rather than taxing your support staff and having people open tickets. Potentially every single one of your customers who has updated since 6/12 is affected and could benefit from an announcement or acknowledgement.

[ e: hello to all - first post :) ]
 
Last edited:

Bdzzld

Well-Known Member
Apr 3, 2004
412
5
168
Installing re2c as suggested by cPanel Tech support solved forementioned problems on all servers. However, it looks like you're using RELEASE while we're using STABLE. That may be the difference and thus you may be experiencing different problems as well.