0

I have a site in Drupal 7, multilanguage and multidomain, and when I do a weekly manual database backup (apart from the automated ones), I see that the size of the mysqldump file is of about 200 Mb. When I run the cron (which is set automatically to once each 3 hours), clear the cache, and then, finally, TRUNCATE all tables with prefix "cache_", the size of the dumped file reduces 4 fold to 50 Mb. I have Authcache and Varnish modules activated, so I thought that the cache was functioning in another way. How is it possible that the cache tables are so full, even with cron updating each 3 hours? May I have something wrong in the configuration?

2

Varnish should not ideally affect your cache tables, not sure about auth_cache. You should try the reverse approach to figure out what is wrong, check which of your cache tables is growing abnormally and then do bit of digging around to find what module/s is responsible for stashing cache data in those tables.

There is a well-known issue with cache_form table in D7, it can grow abnormally for some live sites. Check this issue, Cache Form table size is enormous.

If you find your cache_form also huge you can use one these modules to help you to periodically clear it, https://www.drupal.org/project/optimizedb or https://www.drupal.org/project/safe_cache_form_clear.

Hope this helps.

| improve this answer | |
  • I will take a look, but right now I find cache_menu has 2,000 entries, minutes after deleting this table. cache_form is fine. – Cesar May 25 '16 at 11:18
  • Definitely, the more problematic are cache_menu, locales_source, cache_views and cache_metatag. Cache_form stays reasonable size (100Kb) while the other grow over 30 Mbytes. – Cesar May 26 '16 at 7:16
  • Check this drupal.stackexchange.com/questions/103240/…. Also check drupal.org/node/2062983 and drupal.org/node/1234830, maybe you get some ideas. Both issues is still active against D7 but check the comments, some useful tips are mentioned. – Kimi Jun 17 '16 at 8:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.