How can I enable the Rule2XSBody plugin to speed up anti-spam rules by compiling them into native code?

Overview

This article outlines the steps required to install system dependencies, compile SpamAssassin rules into native code, and enable the Rule2XSBody plugin within Warden for automated nightly updates.

Prerequisites

  • Sudo or root access to the server
  • Administrative access to the Warden control panel

Install Required Packages and Compile Rules

Execute the following commands based on your operating system to install dependencies and compile SpamAssassin rules.

// AlmaLinux/CloudLinux/RHEL
yum install gcc re2c make perl-ExtUtils-MakeMaker

// Debian/Ubuntu
apt-get install gcc re2c make

// run sa-compile to compile the rules into native code
/usr/bin/sa-compile

// AlmaLinux/RHEL/CloudLinux/RockyLinux/Centos users with SeLinux enabled must re-apply SELinux labels 
restorecon -R -v "/var/lib/spamassassin/compiled/"

Enable the Rule2XSBody Plugin in Warden

Follow these steps to activate the plugin and configure automated nightly updates:

  1. Navigate to Warden > Settings > Plugin Settings.
  2. Select the checkbox next to the Rule2XSBody plugin.
  3. Click the Update button to save your configuration.

Once enabled, Warden will automatically execute a nightly task that runs the sa-update and sa-compile commands.

Troubleshooting

  • Compilation Failures: Verify that all required packages are successfully installed before executing the sa-compile command.
  • SELinux Permission Errors: If you encounter access denied errors on RHEL-based systems, ensure the restorecon command was executed correctly to apply the necessary security contexts to the compiled directory.
  • Rule2XSBody, bayes, learning, optimize, performance
  • 0 Uživatelům pomohlo
Byla tato odpověď nápomocná?

Související články

How can I install or upgrade the extension?

We provide free installation and configuration for all our paid licenses. Open a support ticket...

How can I add stronger Postfix restrictions so that the bulk of spam is rejected at the SMTPD level before it gets processed by Amavis?

Overview Warden enables administrators to enforce stricter Postfix SMTPD restrictions. These...

How can I change the interface language of the extension?

Overview This article provides instructions on how to change the interface language within the...

How can I configure greylisting with Warden Anti-spam and Virus protection?

Overview Greylisting is an email filtering mechanism designed to mitigate spam by temporarily...