• Dear Pleskians! The Plesk Forum will be undergoing scheduled maintenance on Monday, 7th of July, at 9:00 AM UTC. The expected maintenance window is 2 hours.
    Thank you in advance for your patience and understanding on the matter.

How do you reinstall Fail2Ban entirely?

Simon123

New Pleskian
So on our server, fail2ban got itself in a mess. Tried various things to fix, to no avail, so figured I'd just do a fresh install of it. There was minimal customisation to it that I couldn't re-do.

Note I'd already rm'd /etc/fail2ban - as on previous attempts, the files in here didn't appear to be restored to their defaults. So I figured removing the directory would force this to happen (Whether this was wise I'm not sure!) ;-)

So, following instructions here: http://kb.odin.com/en/122654 I now get the following:

# wget http://kb.sp.parallels.com/Attachments/kcs-36245/fail2ban.gz
# gunzip fail2ban.gz
# mv fail2ban /etc/init.d/fail2ban
# chmod 755 /etc/init.d/fail2ban
# ll /etc/init.d/fail2ban /etc/fail2ban/fail2ban.conf

ls: cannot access /etc/fail2ban/fail2ban.conf: No such file or directory
-rwxr-xr-x 1 root root 2141 Aug 15 2014 /etc/init.d/fail2ban

I then uninstall/reinstall with # /usr/local/psa/admin/bin/autoinstaller

(Have tried via the web interface too)

I then get:

# ll /etc/init.d/fail2ban /etc/fail2ban/fail2ban.conf
ls: cannot access /etc/fail2ban/fail2ban.conf: No such file or directory
-rwxr-xr-x 1 root root 2141 Aug 15 2014 /etc/init.d/fail2ban

i.e., no change..

and if I go to the fail2ban settings in Plesk, I get:

Internal error: f2bmng failed: ERROR:f2bmng:No section: 'Definition'
Message f2bmng failed: ERROR:f2bmng:No section: 'Definition'

Is there a way to regenerate what should be in /etc/fail2ban by default?
 
Actually this file is a part of fail2ban package:

# rpm -qf /etc/fail2ban/fail2ban.conf
fail2ban-0.8.14-1.el6.noarch

Make sure that this package is correctly installed on your server.
 
Actually this file is a part of fail2ban package:

# rpm -qf /etc/fail2ban/fail2ban.conf
fail2ban-0.8.14-1.el6.noarch

Make sure that this package is correctly installed on your server.

Hi Igor,

Many thanks for the reply :) This is what I'm getting - do you know if this is correct?

# yum info fail2ban
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
* base: mirror.bytemark.co.uk
* epel: mirror.bytemark.co.uk
* extras: mirrors-uk.go-parts.com
* updates: mirror.bytemark.co.uk
Installed Packages
Name : fail2ban
Arch : noarch
Version : 0.9.1
Release : 4.el7
Size : 0.0
Repo : installed
From repo : epel
Summary : Daemon to ban hosts that cause multiple authentication errors
URL : http://fail2ban.sourceforge.net/
 
Back
Top