• Resolved Pat K

    (@blackcapdesign)


    Hello and thanks again for this great plugin! This isn’t a support request; it’s a heads-up for others who may be wondering whether to turn on GeoBlocking vs. Geo-challenge in the plugin’s Geolocation settings.

    I have enabled both methods on a few different sites and on one of them I noticed it was taking forever for it to load – especially in the dashboard. I also noticed that the number of blocked IPs (the little red & white icon in the side and top menu bars in the dashboard) was growing steadily whereas on other sites, it fluctuated up and down as IPs were removed after the temporary blocks were lifted.

    On closer inspection I realized I had added several countries to the GeoBlocking tool – and the growing number of blocked IPs in the list were permanent blocks from these countries. In other words, each time an IP from a blocked country was detected, it was being permanently blocked – which is great, except that this also begins to bloat the database and gradually slows the site as (*I think*) the plugin queries the database to determine if a new visiting IP is in the BLOCK list (I’m using MaxMind).

    In other words, the plugin is working awesomely well to block traffic, but the method I’ve chosen is (I believe) starting to bloat the database and slowing down page load.

    The solution was simple: I just removed the countries from the GeoBlocking tool and entered them in the Geo-challenge tool instead. With Geo-challenge, they’re not being permanently blocked – just challenged on a per-visit basis.

    The more time consuming task is to filter the list of IPs using the GeoBlock filter, then removing the ones marked “Permanent” …because just removing a country from the GeoBlocking tool in the plugin’s settings doesn’t remove the corresponding IPs from the block list.

    NOTE: if any of this is inaccurate, please correct me!

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author IniLerm

    (@inilerm)

    Hi Pat K,

    Thank you so much for taking the time to share this incredibly detailed and accurate heads-up with the community! You’ve hit the nail right on the head, and your understanding of how the plugin interacts with the database is 100% correct.

    You are absolutely right: when a country is added to the strict GeoBlocking tool with a “Permanent” block duration, every single IP from that country that hits your site gets permanently written into the database. Under heavy traffic or bot scans, this can cause the database table to bloat over time. While Advanced IP Blocker is highly optimized, a massive database table will inevitably slow down queries, especially on hosting environments with limited resources.

    Your solution to switch to the Geo-Challenge is brilliant. The Geo-Challenge acts as a lightweight shield—it intercepts and challenges the traffic at the edge without needing to write a permanent database record for every single visitor. It consumes far fewer server resources while keeping your site perfectly safe.

    Taking this a step further, we actually highly advise against using “Permanent” blocks in any of the plugin’s modules (Lockdowns, Threat Score, etc.) for this exact reason. The recommended best practice is to set your block durations to 1440 minutes (24 hours).

    A 24-hour block is the sweet spot: it is long enough to stop an attacker or a botnet in its tracks, but it allows the plugin to naturally “self-clean” expired IPs from the database every day. This keeps your database lean, fast, and completely immune to bloat over time.

    Regarding your cleanup task, you are doing it perfectly. Filtering by “Permanent” in the block list and bulk-deleting them is the way to go to restore your database to peak performance.

    Thanks again for sharing your experience. Feedback like yours is what makes this community so great, and I’m sure it will help many other users optimize their setups!

    https://wordpress.org/support/topic/country-blocking-geoblocking-or-geo-challenge/

    Best regards,
    Advanced IP Blocker Team

    • This reply was modified 5 days, 12 hours ago by IniLerm.
    Thread Starter Pat K

    (@blackcapdesign)

    Super! Thanks for confirming I’m doing it correctly. Also, thanks of the tip regarding the other modules and the potential cost of making those blocks permanent. Very helpful and much appreciated 🙂

Viewing 2 replies - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.