Bug - CB2 Redis and Rspamd configuration problem

Tristan

Verified User
Joined
Feb 11, 2005
Messages
684
Location
The Netherlands
According to the CB2 changelog:

2718, 2717 - Skip PHP-Redis installation on PHP 5.x.

2715 - Hide redis update in "./build versions" if redis=no is set.

2713 - Add redis=yes/no configuration option.

2706 - Added PHP-Redis extension support.

2705 - Added redis for rspamd support.

We should now have support to build Redis, have the PHP-Redis extension and have Rspamd Redis support? Is there any documentation available on how to enable all this? Couldn't find a mention on http://docs.directadmin.com yet. Is it something like:

Code:
cd /usr/local/directadmin/custombuild
./build update
./build set redis yes
./build set_php redis yes
./build set spamd rspamd
./build redis
./build rspamd
./build exim_conf

Afterwards while /etc/rspamd/local.d/redis.conf contains servers = "/var/lib/rspamd/.redis/redis.sock"; and seems to running fine, trying to upload SPAM/HAM within the Rspamd web interface it still fails with:

Code:
local > Request failed: Unknown statistics error, found when storing data on backend; classifier: (null)
Request failed

Rspamd log:
Code:
2021-06-07 13:11:58 #9880(controller) <73f5b1>; csession; rspamd_controller_check_password: allow unauthorized connection from a unix socket
2021-06-07 13:11:59 #9880(controller) <70d39e>; csession; rspamd_controller_check_password: allow unauthorized connection from a unix socket
2021-06-07 13:11:59 #9880(controller) <70d39e>; csession; rspamd_message_parse: loaded message; id: <2A0LCBDYWI5S.WJFC3450EA@WIN-UIR344453ASkk7124>; queue-id: <undef>; size: 119932; checksum: <e72dc50f334d46278c43c7b2070513c6>
2021-06-07 13:11:59 #9880(controller) <70d39e>; csession; rspamd_url_text_extract: got empty text part
2021-06-07 13:11:59 #9880(controller) <70d39e>; csession; rspamd_mime_part_detect_language: detected part language: en
2021-06-07 13:11:59 #9880(controller) <70d39e>; csession; rspamd_stat_classifiers_process: skip statistics as SPAM class is missing
2021-06-07 13:11:59 #9880(controller) <70d39e>; csession; rspamd_task_process: learn error: Unknown statistics error, found when storing data on backend; classifier: (null)
2021-06-07 13:11:59 #9880(controller) <70d39e>; csession; rspamd_controller_learn_fin_task: cannot learn <2A0LCBDYWI5S.WJFC3450EA@WIN-UIR344453ASkk7124>: Unknown statistics error, found when storing data on backend; classifier: (null)
 
Last edited:
Maybe the build script should also add exe:/usr/local/bin/redis-server to csf.pignore since that's installed by default nowadays?
 
Digged a bit more, looks like this is only happening on servers with previously installed (and uninstalled) distribution versions of Redis so probably a setting somewhere in /etc/redis messing with the Redis connection for Bayes. Didn't have time to properly investigate so in the end just de-installed Rspamd completely via this guide and reinstalled it again afterwards.
 
Last edited:
Rspamd completely via this guide and reinstalled it again afterwards.
So you removed redis with apt?
The removed with the guide
Then reinstalled CB rspamd with redis?

If you use the CB redis it seems to take up a lot of ram. Are you saying its because Debian/OS base redis was installed?
 
So you removed redis with apt?
The removed with the guide
Then reinstalled CB rspamd with redis?

If you use the CB redis it seems to take up a lot of ram. Are you saying its because Debian/OS base redis was installed?
Yeah correct, first removed Redis with apt, installed Redis with CB, although it seems ./build set redis yes. and ./build set_php redis result in the same thing at the moment.
 
Ah just for future reference if you use the uninstall guide on docs.directadmin and do a Rspamd reinstall, make sure to do issue a user config rewrite as well:

Code:
echo "action=rewrite&value=rspamd" >> /usr/local/directadmin/data/task.queue

Otherwise internal email will be broken and result in these errors during transport clogging op the queue:

R=spamcheck_directorT=spam check defer (-24): Transport filter process failed (127): unable to execute command
 
Back
Top