How to upgrade fail2ban from 4.x to 5 on WordPress droplet

Has anyone of you have to deal with the upgrade of the fail2ban plugin on the WordPress droplet from version 4.x to 5? I have a site using the WordPress image from the DO marketplace, and I have never touched the fail2ban plugin other than updating from the WordPress plane when needed. However, the developer has published a warning saying that version 5 is different and one have to update the filters. He’s not being very clear, so I’m not sure what will happen if I click the upgrade button. Anyone of you using the DO droplet with WordPress has already dealt with this situation?

Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Site Moderator
Site Moderator badge
April 8, 2023

Hello @mhwebb

If you upgrade the plugin you would also need to upgrade the filters as you’ve pointed out. In case you would like to see the default version be 5.0.0

To update the filters you have to download them from the directory and move them to the filter directory of fail2ban.

$ wget
$ wget
$ wget
$ sudo mv wordpress-*.conf /etc/fail2ban/filter.d/

You can check this question that was asked in our community:


Try DigitalOcean for free

Click below to sign up and get $200 of credit to try our products over 60 days!

Sign up

Get our biweekly newsletter

Sign up for Infrastructure as a Newsletter.

Hollie's Hub for Good

Working on improving health and education, reducing inequality, and spurring economic growth? We'd like to help.

Become a contributor

Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.

Welcome to the developer cloud

DigitalOcean makes it simple to launch in the cloud and scale up as you grow — whether you're running one virtual machine or ten thousand.

Learn more
DigitalOcean Cloud Control Panel