Hi,
In one of the servers that we manage, we don't want to run any mail server. When we setup CSF and start it, lfd is stopping soon after it has been started. We removed SENDMAIL path line from csf.conf and restarted csf. Still lfd wouldn't run.
------------------------------------ lfd.log entries --------------------------
Jul 25 00:00:02 localhost lfd[38846]: Unable to send SENDMAIL alert via []: No such file or directory at /usr/sbin/lfd line 3725.
Jul 25 00:00:02 localhost lfd[38846]: daemon stopped
Jul 25 00:00:07 localhost lfd[38837]: *Error* pid mismatch or missing, at line 907
Jul 25 00:00:07 localhost lfd[38837]: daemon stopped
---------------------------------------------------------------------------------
[root@localhost ~]# grep ^SMTP /etc/csf/csf.conf
SMTP_BLOCK = "0"
SMTP_ALLOWLOCAL = "0"
SMTP_REDIRECT = "0"
SMTP_PORTS = "25,465,587"
SMTP_ALLOWUSER = ""
SMTP_ALLOWGROUP = "mail,mailman"
SMTPAUTH_RESTRICT = "0"
SMTPAUTH_LOG = "/var/log/secure"
This is a CentOS 7 server with Plesk control panel on it. We would like to know how to run lfd even if we don't run a mail server (as we don't need any mail alerts).
Thank you
How to run CSF while not running mail server
Re: How to run CSF while not running mail server
Have you turned off "LF_EMAIL_ALERT" inside CSF configuration?
Re: How to run CSF while not running mail server
We have now disabled LF_EMAIL_ALERT and tried. Still same error, when csf -r is run:
*WARNING* Binary location for [SENDMAIL] [] in /etc/csf/csf.conf is either incorrect, is not installed or is not executable
*WARNING* Missing or incorrect binary locations will break csf and lfd functionality
And lfd.log shows:
Jul 26 07:42:27 localhost lfd[63438]: Unable to send SENDMAIL alert via []: No such file or directory at /usr/sbin/lfd line 3725.
Jul 26 07:42:27 localhost lfd[63438]: daemon stopped
*WARNING* Binary location for [SENDMAIL] [] in /etc/csf/csf.conf is either incorrect, is not installed or is not executable
*WARNING* Missing or incorrect binary locations will break csf and lfd functionality
And lfd.log shows:
Jul 26 07:42:27 localhost lfd[63438]: Unable to send SENDMAIL alert via []: No such file or directory at /usr/sbin/lfd line 3725.
Jul 26 07:42:27 localhost lfd[63438]: daemon stopped
Last edited by tuxg on 26 Jul 2016, 08:44, edited 1 time in total.
-
- Moderator
- Posts: 1524
- Joined: 01 Oct 2008, 09:24
Re: How to run CSF while not running mail server
The simplest way would be to create a dummy /usr/sbin/sendmail script, e.g:
Code: Select all
echo '#!/bin/sh' > /usr/sbin/sendmail
chmod +x /usr/sbin/sendmail
Re: How to run CSF while not running mail server
This hasn't helped either.
-
- Moderator
- Posts: 1524
- Joined: 01 Oct 2008, 09:24
Re: How to run CSF while not running mail server
If it is still the same error that that suggests that you have not disabled all the ALERT settings in csf.conf (there are quite a few). There is a profile that you can use to do so.
Re: How to run CSF while not running mail server
Creating a dummy /usr/sbin/sendmail as suggested above and disabling the alerts as per disable_alerts profile settings has got it working.
Thanks a lot for your help.
Thanks a lot for your help.