• Resolved lizcan1

    (@lizcan1)


    Hi
    I have several WordPress sites and having to redo the user agent exclusions for each of them is a complete pain. Can anyone tell me where the settings are stored so that I can just copy and paste a list into a file or database?

    In any event, having entered all the individual user agents for one of my sites, every time Wordfence updates the settings disappear, which is intensely irritating.

    Has anyone any ideas please?

    Liz

    https://www.ads-software.com/plugins/wordfence/

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author WFMattR

    (@wfmattr)

    Just to confirm, you are using the “cache exclusions” section on Wordfence’s Performance Setup page, and are not using another caching plugin along with Wordfence, correct?

    It isn’t normal for these settings to be lost when updating Wordfence. Do you lose other settings too, such as the admin email address you have set on your Wordfence Options page?

    The cache settings are stored in Wordfence’s configuration table, but they aren’t in a format that you can copy or export easily. As a temporary fix, you may be able to use the “Export Wordfence settings” button at the bottom of the Options page, and save the token it gives you. You can then import it if the settings are lost again, or you can import it on the other sites, if it’s ok for them to use the same Wordfence settings, including the admin email address, lockout options, etc.

    With the answers to the other questions, we can still try to see why the options are being lost. Additionally, are the sites all on the same host, or different hosts, or even different hosting companies?

    Thread Starter lizcan1

    (@lizcan1)

    Hi,

    Yes, I am using the “cache exclusions” and no, I am not using another caching plugin.

    The export/import facility only applies to the Options page, as I’m sure you know, not to the caching settings. Yes it does work but resets to the default when the plugin updates!

    I have tried copying the whole of the Wordfence plugin from a fully set up site to my other sites and when I check both the Performance page and the Options page, all the settings I want are there including the Cache Exclusions. However, as soon as there is a Wordfence update, all the settings disappear.

    Yes all the sites are with the same hosting company (Hostgator) on the same hostname and servers.

    Thanks

    Liz

    Thread Starter lizcan1

    (@lizcan1)

    As an additional point, I just tried to use the same token to import settings to another site and I got an error message saying it was the wrong token – it wasn’t – and it didn’t have extra spaces!

    Liz

    Plugin Author WFMattR

    (@wfmattr)

    Liz,

    Thanks for the additional details. Sorry I didn’t remember that the cache exclusions are not saved when exporting options — options on some other pages like blocked IPs are saved in the export, and the 3 cache option checkboxes are too (but not the cache type at the top, since enabling caching requires the server make some changes, unlike the regular options.) I’ve just added this as a feature request in our system (FB940), for a future version!

    It’s definitely not normal to lose any settings when Wordfence is updated, and I confirmed that updating from 6.0.15 to 6.0.16 does not affect my cache exclusions, so something else must be going on.

    Can you check the permissions on your database, to see if your database user has all privileges on all tables? It’s possible that your settings are only saved in Wordfence’s config cache file, instead of the database. That file would be included when you copied Wordfence to another site, but the settings still might not make it into the site’s database from there.

    If the database privileges are ok, I would try turning on the option “Disable config caching” on Wordfence’s Options page, and see if you can save cache exclusions after that. This might cause your cache exclusions to be lost on that site, if there is still a problem saving to the database, but would help narrow down the problem.

    I haven’t seen an export token fail like that before either — if you want to email me the token you have, I can see if I can import it on my end. (Don’t post it here, as it would contain your admin email address and other settings.) My email address is mattr (at) wordfence.com

    -Matt R

    Thread Starter lizcan1

    (@lizcan1)

    Hi Matt

    The database user (me) has full permissions so I’ve tried “Disable config cache” and the cache exclusions didn’t show up at all when I copied the files across.

    I can confirm that successfully transferred cache exclusions disappeared when I did the 6.0.17 upgrade!

    Regarding the export token; I created a new one and it worked fine.

    I think the quickest thing I can do rather than enter all the exclusions individually is change the mobile plugin to one which doesn’t require special configuration of Wordfence.

    Thanks for your help.

    Liz

    Plugin Author WFMattR

    (@wfmattr)

    Ok, it may have been the config cache causing trouble all along with both the cache exclusions and the token — on some hosts, there have been some unusual issues reported, but on most it works without any problems.

    On a site where you had added the exclusions manually, if config caching was disabled before the upgrade to 6.0.17, did those settings still appear after the upgrade? (If you didn’t check this while upgrading and are definitely changing mobile plugins, then it’s ok if you don’t answer!)

    You’re right that changing the mobile plugin may be the easiest solution. If you use a plugin that makes the site “responsive,” where the same HTML can be used by both mobile and desktop users, they can also both benefit from the cached files, instead of having some visits excluded from caching.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Cache settings with WPTouch’ is closed to new replies.