• Recently, I saw my rather first and a rare database anomaly I guess for my sqlite object cache powered wordpress website wherein all of a sudden, the site’s DB seemed to revert to a previous state like around 1 month ago.

    But only plugins and wordpress settings were affected like permalink settings, sitemap settings, any other plugin config and any plugins not activated around 1 month ago were also deactivated as of now. No data as it seems was affected by this as the latest posts and CPTs were all intact, I just had to reactivate the metabox plugin. I still couldn’t fix many settings as updating them doesn’t do anything, it doesn’t update like permalink settings took 4 tries to update. Some plugin settings could update. But DB was still corrupted and parts of my site changed.

    As far as I could see no file system change had happened. I happen to restore a backup for now. But it lets me think if this plugin has any hand in this? I will need to stay alert if it did? As even for updraftplus backups, I couldn’t restore them through dashboard as auth tokens were also missing in DB after this.

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author ImageOllieJones

    (@olliejones)

    Was APCu activated?

    If you run more than one site on the same server, and the multiple sites happen to have the same WP_CACHE_KEY_SALT values in their wp-config.php files, cached values leak from one site to another. Take a look at this: https://wordpress.org/plugins/sqlite-object-cache/#installation

    Is this possibly your situation?

    Thread Starter ImageSujal Jain

    (@sujaljain007)

    I have a cpanel server and yeah, I had one more fresh wordpress site installed for a long time on the same account. so they shared same resources but different folders ofcourse. The site was fresh and I didn’t plan or had worked on it after installation though.

    Anyways now that I have increased my DB backup frequency to per hour, and if the situation really arised out of this plugin, I still couldn’t live without it after using it for around 2 months. It just feels heavy and unreliable now without an object cache, atleast on my shared server. It managed to fasten the admin backend from around 3 seconds to nearly under 1 second.

    So, I enabled it again today and the other wordpress site is also deleted, so no more wordpress sites for now. I am using multisite, with only one main site as subsite for now and your plugin is network activated forever anytime I activate it.

    Now for the cache salt part, the hash we are talking about in the installation page is explicitly only directing to use a 12 character base64 one. Is it the limit for it? If not how far can we go, are there any consequences for doing it more or less than 12 characters?

    And, what prerequisites if any do I need to follow before adding the salt, important part – where do I add it, in wp-config.php it isn’t there by default I saw. I also happen to use two more page caching plugins – flyingpress and super page cache, I read in installation that we need to deactivate the plugins before adding the salt in wp-config and then clear all the caches for all the plugins?

    Just confirming if I am right. Even then, can you please write me the syntax and tell me the character limit for that base64 random string? And I guess it needs to be put into wp-config at any place but since any cache config is put at the top, i will do it just below it.

    And yeah, I forget to tell, APCu is activated and was. its there in wp-config when i check it – define( 'WP_SQLITE_OBJECT_CACHE_APCU', true );

    Regards

    Thread Starter ImageSujal Jain

    (@sujaljain007)

    Oh, Its there in wp-config about APCu but actually on checking, I found its not available for my shared setup. It never was available. I’m sorry for pointing it out wrong about having it enabled.

    Thread Starter ImageSujal Jain

    (@sujaljain007)

    Update, I enabled both APCu and Zend Opcache, and now admin is super fast, nearly under 0.5s average for all requests where http requests are not required. I added the cache key salt in wp-config but i would still prefer confirmation.

    Plugin Author ImageOllieJones

    (@olliejones)

    https://github.com/OllieJones/sqlite-object-cache/issues/87 is tracking for correction of the duplicated WP_CACHE_KEY_SALT issue.

    There is no limit on the length of the value of WP_CACHE_KEY_SALT. I arbitrarily chose the 16 characters that come from openssl rand -base64 12. Any unique string will serve the purpose.

    It is used as a prefix for cache keys in APCu and for the .sqlite file name. So an excessively long one will cause slowdowns.

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

You must be logged in to reply to this topic.