Fail2ban installed by default ? How to disable ?

12 posts / 0 new
Last post
#1 Sun, 03/18/2018 - 10:01
jvieille

Fail2ban installed by default ? How to disable ?

I was surprised that Fail2ban is now installed by default after setting up a new server with Webmin (which made a lot of trouble during the initial install...)

I uses csf/lf, so I don't need this feature, I prefer csf that has a webmin GUI. How can I disable it? Uninstall ? Don't start at boot time?

Thanks

Tue, 03/20/2018 - 09:02
scotwnw

Just uninstall fail2ban from the OS, then remove the fail2ban module from webmin if you wish. Thats what I do since I also use csf.

And installing fail2ban by default is better than it was before, which was nothing at all.

Mon, 08/13/2018 - 12:01
TheRavenKing

Hi, sorry to ask, but how do I remove fail2ban from my CentOSv7.5 with Virtualmin I tried yum remove fail2ban, but yum can't find it in both repos, any help much appreciated.

yum remove fail2ban
Loaded plugins: fastestmirror
No Match for argument: fail2ban
No Packages marked for removal

yum --enablerepo=epel remove fail2ban
Loaded plugins: fastestmirror
No Match for argument: fail2ban
No Packages marked for removal

I want to use CSF only.

Mon, 08/13/2018 - 12:03
andreychek

Howdy,

What is the output of this command:

rpm -qa | grep -i fail2ban

Mon, 08/13/2018 - 13:59
TheRavenKing

Hi, This is the output:

rpm -qa | grep -i fail2ban
fail2ban-firewalld-0.9.7-1.el7.noarch
fail2ban-server-0.9.7-1.el7.noarch
Mon, 08/13/2018 - 14:10
TheRavenKing

I am very new to this Webmin, and was looking around in all menus, I noticed that fail2ban is a module, in the Webmin Modules you can delete modules, fail2ban is one of them, is that perhaps the appropriate way to do this?

Mon, 08/13/2018 - 14:25
andreychek

Removing the Webmin module would simply make it so it can no longer be managed from within Webmin.

Either you'd want to go into Services -> Bootup and Shutdown, and stop the service there -- or, you'd want to remove the two packages relating to Fail2ban that we can see in your Comment #5 above.

Mon, 08/13/2018 - 14:26
TheRavenKing

OK, I think I might have found it :-) In Package search... you do a search for Fail2Ban, and it comes with these 2 and you can tick to delete them, so it seems it is possible in 2 ways: either by modules or package search. I have to say it looks very good in Webmin/Virtualmin. I also found you can export the module incase you want it to install again.

Mon, 08/13/2018 - 14:27
TheRavenKing

Thanks ever so much for your help. going to get rid of it and get my CSF configured.

Thu, 08/01/2019 - 23:22
CPConvert

Hi team

This is a helpful thread, thank you - however, nobody mentions why you can't run both fail2ban and csf together - is it not recommended? I realise they do similar things afterall, so I guess makes sense to choose one or other.

So what is the correct way to uninstall fail2ban ? Or is it enough to just disable it ?

Fri, 08/02/2019 - 03:16
Jfro

Uh you need to remove firewalld and such, fail2ban could be next to CSF. ( but could "conflict" or harder to find wich one has blocked a ip ) ( you can change the config using iptables right with csf and mail if blocking if wanted )

Is csf is blocking you can unblock in csf, if fail2ban you have to do there. so that is the most "conflicting" but if more conflicts please write here ??????

So fail2ban is not blocking csf installations!

You need i guess all of the required IPTables modules installed if not there already.

For all of you have a look before uninstall and using csf only to the jail.local config file.
So you know more.

;)

Fri, 08/02/2019 - 23:19
CPConvert

Yes, thanks that's helpful... I took the easy way ... >> go into Services -> Bootup and Shutdown, and stop the service there

Topic locked