Fail2Ban not starting after auto "security" updates

Now have two installations with the same issue. both after recent auto updates for security issues (?). Both running the same version of the distro. both hosted with Sangoma’s cloud service.

I get the following in the GUI Dashboard:

There is 1 module vulnerable to security threats

manager (Cur v. 13.0.2.9) should be upgraded to v. 13.0.2.10 to fix security issues: SEC-2021-010

However I show no modules that have pending upgrades in Module Admin.

As soon as you post the output from /usr/bin/fail2ban-client -x startwe can likely have you on your way.

The output I get from /usr/bin/fail2ban-client -xfrom the command line asks for options

[[email protected] ~]# /usr/bin/fail2ban-client -x
Usage: /usr/bin/fail2ban-client [OPTIONS]

Fail2Ban v0.8.14 reads log file that contains password failure report
and bans the corresponding IP addresses using firewall rules.

[[email protected] ~]# /usr/bin/fail2ban-client -x start
ERROR No file(s) found for glob /var/log/asterisk/zulu_out.log
ERROR Failed during configuration: Have not found any log file for zulu jail
[[email protected] ~]#

The 'option ’ you missed that I posted is ‘start’

Sorry about that - cut and paste missed the start :slight_smile: Got it the second try.

Quick work around

touch /var/log/asterisk/zulu_out.log

(someone needs to post a bug to get that fixed.)

1 Like

[[email protected] ~]# touch var/log/asterisk/zulu_out.log
touch: cannot touch ‘var/log/asterisk/zulu_out.log’: No such file or directory

My typo /var/log/asterisk/zulu_out.log .

1 Like

Looks like the repository servers are down at the moment. Getting this message when checking module admin on several FreePBX installations.

Warning: Cannot connect to online repository(s) (http://mirror1.freepbx.org,http://mirror2.freepbx.org). Online modules are not available.

That’s not relevant to this thread, start a new one.

touch /var/log/asterisk/zulu_out.log

That fixed the fail2ban issue.

Not fixed, just worked around. Post a bug.

Will do.

1 Like

This didn’t fix it for me (brand new install, all updates done)

/usr/bin/fail2ban-client -x start gives me this:

[[email protected] ~]# /usr/bin/fail2ban-client -x start
ERROR  Found no accessible config files for 'filter.d/apache-api' under /etc/fail2ban
ERROR  Unable to read the filter
ERROR  Errors in jail 'apache-api'. Skipping...

You will have to now fix the jail for apache-api that neither has a log file to watch, as defined in your `/etc/fail2ban/filter.d/apache-api’ file, you can similarly ‘touch’ it for a work around, this also needs to be a bug that you report

Understand that at this point you are not protected by either of those ‘jails’

(I believe that current versions of fail2ban will not outright fail for a mis-configured jail)

Thanks for the info, I will try the touch workaround in a few moments.
I didn’t leave the system running without the firewall, it was shutdown.

This is what fixed it for me:
/var/www/html/admin/modules/sysadmin/hooks/fail2ban-apache-config

Found it on:
https://community.freepbx.org/t/fail2ban-wont-start-after-update/76810/52

1 Like

This fixed the same issue for me, thanks Chris.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.