• We value your experience with Plesk during 2024
    Plesk strives to perform even better in 2025. To help us improve further, please answer a few questions about your experience with Plesk Obsidian 2024.
    Please take this short survey:

    https://pt-research.typeform.com/to/AmZvSXkx
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

[solved] Unable to start spamassassin

pentabase

Basic Pleskian
Hi all,

I noticed that my spamassassin wasn't running on my server. so I restarted the service from the plesk panel but got the following message:

Error: Unable to make action: Unable to manage service by spammng: spamassassin: unrecognized service
ERROR:spammng:Unable to start SpamAssassin service
('--start', 'spamassassin')

So I SSH'ed into my machine and saw that spamassassin wasn't running.

The I reinstalled spamassassin from the "add and remove product components", but that didn't change anything. Still the same error.

Anyone that knows the answer to this?
 
My apologies.

i'm running 12.0.18 Update #47, last updated at May 23, 2015 09:54 AM on Centos 6.5

  • /etc/mail/spamassassin/local.cf

#ATTENTION!
#
#DO NOT MODIFY THIS FILE BECAUSE IT WAS GENERATED AUTOMATICALLY,
#SO ALL YOUR CHANGES WILL BE LOST THE NEXT TIME THE FILE IS GENERATED.
# These values can be overridden by editing ~/.spamassassin/user_prefs.cf
# (see spamassassin(1) for details)

# These should be safe assumptions and allow for simple visual sifting
# without risking lost emails.

report_safe 0

rewrite_header subject *****SPAM******
required_score 7.0
blacklist_from *@yandex.com​


there are no entries in the mailllog file regarding spamassassin or the starting of it.

when restarting from the CLI i get the following:

service spamassassin start
'spamassassin' is not a command​


I've allready applied: http://kb.odin.com/en/125553

Hope this is enough
 
Hi pentabase,

what is the output of:
Code:
service psa stopall
service psa start

... after you performed:
Code:
/usr/local/psa/admin/bin/autoinstaller --select-product-id plesk --select-release-current --reinstall-patch --remove-component spamassassin
/usr/local/psa/admin/bin/autoinstaller --select-product-id plesk --select-release-current --reinstall-patch --install-component spamassassin
 
after the remove-component spamassassin i got this in the logs:

**** Product perform-deferred-actions completed successfully.

STOP Bootstrapper 12.0.18 perform-deferred-actions AT Sat May 23 09:54:35 CEST 2015
START psa-spamassassin-12.0.18-cos6.build1200140606.15 installing AT Sat May 23 12:38:48 CEST 2015
Trying to stop service spamassassin...
WARNING!
Some problems are found during Unable to stop service spamassassin - control script doesn't exist or isn't executable(see log file: /var/log/plesk/install/plesk_12.0.18_installation.log)

Continue...


WARNING!
Some problems are found during stop(see log file: /var/log/plesk/install/plesk_12.0.18_installation.log)

Continue...

Trying to unregister service spamassassin... error reading information on service spamassassin: No such file or directory
error reading information on service spamassassin: No such file or directory
done

**** Package psa-spamassassin scriptlet completed successfully.

STOP psa-spamassassin-12.0.18-cos6.build1200140606.15 installing AT Sat May 23 12:38:50 CEST 2015
START psa-spamassassin-12.0.18-cos6.build1200140606.15 installing AT Sat May 23 12:38:50 CEST 2015
Removing 'spamassassin' upgrader configuration

**** Package psa-spamassassin scriptlet completed successfully.

STOP psa-spamassassin-12.0.18-cos6.build1200140606.15 installing AT Sat May 23 12:38:50 CEST 2015
START Bootstrapper 12.0.18 perform-deferred-actions AT Sat May 23 12:38:51 CEST 2015

After the install-component:

**** Product perform-deferred-actions completed successfully.

STOP Bootstrapper 12.0.18 perform-deferred-actions AT Sat May 23 12:38:51 CEST 2015
START psa-spamassassin-12.0.18-cos6.build1200140606.15 installing AT Sat May 23 12:41:51 CEST 2015

**** Package psa-spamassassin scriptlet completed successfully.

STOP psa-spamassassin-12.0.18-cos6.build1200140606.15 installing AT Sat May 23 12:41:51 CEST 2015
START psa-spamassassin-12.0.18-cos6.build1200140606.15 installing AT Sat May 23 12:41:51 CEST 2015
error reading information on service spamassassin: No such file or directory
ERROR:spammng:Command '['/sbin/chkconfig', '--add', 'spamassassin']' returned non-zero exit status 1
spamassassin: unrecognized service
ERROR:spammng:Unable to start SpamAssassin service
Initializing 'spamassassin' upgrader configuration (stage 'files')

**** Package psa-spamassassin scriptlet completed successfully.

STOP psa-spamassassin-12.0.18-cos6.build1200140606.15 installing AT Sat May 23 12:41:51 CEST 2015
START Bootstrapper 12.0.18 post-install for spammng AT Sat May 23 12:41:52 CEST 2015

**** Product post-install started.

===> Checking for previous installation ... found.

**** Product post-install for spammng completed successfully.

STOP Bootstrapper 12.0.18 post-install for spammng AT Sat May 23 12:41:52 CEST 2015
START Bootstrapper 12.0.18 perform-deferred-actions AT Sat May 23 12:41:53 CEST 2015

**** Product perform-deferred-actions started.

===> Checking for previous installation ... found.
/usr/local/psa/admin/sbin/spammng execution failed:
error reading information on service spamassassin: No such file or directory
ERROR:spammng:Command '['/sbin/chkconfig', '--add', 'spamassassin']' returned non-zero exit status 1
/usr/local/psa/admin/sbin/spammng execution failed:
error reading information on service spamassassin: No such file or directory
ERROR:spammng:Command '['/sbin/chkconfig', '--add', 'spamassassin']' returned non-zero exit status 1

And then after the startall command:

[root@hosting3 install]# /etc/init.d/psa startall
Starting psa... Starting sw-engine-fpm: [ OK ]
done
Starting xinetd service... done
Starting sw-cp-server service... done
Starting mysqld service... done
Starting named service... done
Starting postgresql service... not installed
Starting spamassassin service... not installed
Plesk: Starting Mail Server... done
for some reason it installs spamassassin, but it can't find the commands or something.

when I do a locate spamassassin it finds all the config files in /etc/mail/spamassassin and the executable: /usr/bin/spamassassin
 
Hi pentabase,

are you probably using SELinux in "Enforcing" mode? What is the output of
Code:
getenforce
... over your command line?
 
Hi pentabase,

somehow, you might have permission problems on your server at the moment. I would suggest to disable SELinux completely and run a bootstrapper repair:

/usr/local/psa/bootstrapper/pp12.0.18-bootstrapper/bootstrapper.sh repair

Afterwards, you could retry the suggested deinstallation and reinstallation of spamassassin, have a look if all works fine ( PSA restart ) and re-enable SELinux in permissive mode, to have another look with a PSA restart.
 
I've executed it with this result:

[root@hosting3 install]# /usr/local/psa/bootstrapper/pp12.0.18-bootstrapper/bootstrapper.sh repair

Bootstrap setup actions for Plesk 12.0.18

Usage: bootstrapper.sh <prep-install|post-install|rerun|perform-deferred-actions> [component|BASE]
bootstrapper.sh <repair|perform-deferred-actions>

Running 'bootstrapper.sh repair' with PLESK_INSTALLER_FAST_REPAIR=1 environment
variable set will skip some of the most time-consuming restore actions.


and it stops straight away.
 
Hi pentabase,

sometimes "copy&paste" from the forum doesn't work, if you do this with suggested commands. This is because some browser copy invisible spaces ( a HTML copy as "&nbsp;" ) as well and such symbols won't work over the command line. In such cases, please TYPE the command to avoid such issues. In your specific case, the additional string ( command ) " repair" wasn't performed and the bootstrapper repair didn't start, because the invisible (space)symbol between "....sh" and "repair" is incorrect and has to be a normal space.
 
Last edited by a moderator:
yeah ;).

so i ran the command again and it repaired everything. after that i've repeated the commands for reinstalling spamassassin, and did the restart of psa. But still it's the same.

Starting spamassassin service... not installed
 
Hi pentabase,

please run again bootstrapper and post the complete bootstrapper - log - file as attachment for further investigations.
If you are concerned about your personal informations, please open a new conversation with me to add the log - file as attachment.
 
I've added the repair log created by the bootstrapper. The repair_problem.log was empty btw.
 

Attachments

  • psa.txt
    7.6 KB · Views: 1
Hi pentabase,

what are now the current outputs of:
Code:
/etc/init.d/spamassassin stop
/etc/init.d/spamassassin start

or

/etc/init.d/spamassassin restart
 
There is no /etc/init.d/spamassassin startup script.

I really find it strange that the installer says it's installed, but in the end, it's not installed at all (for as far as I can see)
 
Hi pentabase,

it is indeed a strange situation, that you experience - and not a really normal behaviour. Please wait for other users, Product Experts or Plesk-TEAM - members for further investigations and suggestions.
 
Hi pentabase,

even if the following informations may not help to solve your issue, I still got the idea to point you to a similar issue with Fail2Ban ( http://kb.odin.com/122654 ). The KB - article describes a similar error:
Code:
Error: f2bmng failed: error reading information on service fail2ban: No such file or directory    
ERROR:f2bmng:Command '['/sbin/chkconfig', '--add', 'fail2ban']' returned non-zero exit status 1
... and the suggestion is to place the Fail2Ban - startup script to it's standard location, in order to be able to remove and re-install Fail2Ban.

Unfortunately I don't know if it helps, but the depending rpm for CentOS 6 ( x86_64 ) for you is for example located at:

http://pkgs.repoforge.org/spamassassin/spamassassin-3.3.2-4.el6.rfx.x86_64.rpm

( if you have another spamassasin version installed - you can check this with "rpm -qf /usr/bin/spamassassin" - please visit "http://pkgs.repoforge.org/spamassassin/" and choose your desired rpm - version )​

Please download it to a personal root folder ( i.e. /root/temp/spamassassin ) and try to re-install the rpm using the commands:
Code:
mkdir /root/temp && mkdir /root/temp/spamassassin
cd /root/temp/spamassassin
wget http://pkgs.repoforge.org/spamassassin/spamassassin-3.3.2-4.el6.rfx.x86_64.rpm
rpm -ivh --replacepkgs http://pkgs.repoforge.org/spamassassin/spamassassin-3.3.2-4.el6.rfx.x86_64.rpm
Please check now, if the needed startup script is installed at "/etc/init.d/spamassassin" and try to start it. If all went fine, then you can delete your temp - folders at ""/root/temp/", because you don't need them any longer.
 
Thanks a lot @UFHH01 you pointed me in the right direction.

I got the right version of spamassasin form the website. But instead of using the RPM command (which resulted in a missing dependancy issue) i've extracted the content of the rpm

Code:
rpm2cpio spamassassin-3.x.x-x.el5.rfx.x86_64.rpm | cpio -idmv

After that i've extracted the startup script and placed it in /etc/init.d. I also had to create the /etc/default/spamassassin file which was missing.

After that it was just a matter of starting spamassassin again.

Still I wonder how spamassassin got this messed up without my interference. But that's another discussion ;).
 
Back
Top