We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 49998
    • 9 Posts
    Hello.
    I have a very old site on Revo 2.2.6-pl. And few weeks ago it start working veeeery slowly (aspecually manager panel).

    Log contains this error:

    [2016-08-05 14:12:15] (ERROR @ /connectors/system/phpthumb.php) Error HY000 executing statement:
    INSERT INTO `modx_session` (`id`, `access`, `data`) VALUES ('97f9e25e7ef4163a0350f0ab2588fa0b', 1470395535, 'modx.user.contextTokens|a:1:{s:3:\"mgr\";i:1;}modx.user.0.resourceGroups|a:1:{s:2:\"en\";a:0:{}}modx.user.0.attributes|a:2:{s:3:\"web\";a:4:{s:16:\"modAccessContext\";a:2:{s:2:\"en\";a:1:{i:0;a:3:{s:9:\"principal\";i:0;s:9:\"authority\";s:1:\"0\";s:6:\"policy\";a:1:{s:4:\"load\";b:1;}}}s:3:\"web\";a:1:{i:0;a:3:{s:9:\"principal\";i:0;s:9:\"authority\";s:1:\"0\";s:6:\"policy\";a:1:{s:4:\"load\";b:1;}}}}s:22:\"modAccessResourceGroup\";a:0:{}s:17:\"modAccessCategory\";a:0:{}s:28:\"sources.modAccessMediaSource\";a:0:{}}s:2:\"en\";a:4:{s:16:\"modAccessContext\";a:2:{s:2:\"en\";a:1:{i:0;a:3:{s:9:\"principal\";i:0;s:9:\"authority\";s:1:\"0\";s:6:\"policy\";a:1:{s:4:\"load\";b:1;}}}s:3:\"web\";a:1:{i:0;a:3:{s:9:\"principal\";i:0;s:9:\"authority\";s:1:\"0\";s:6:\"policy\";a:1:{s:4:\"load\";b:1;}}}}s:22:\"modAccessResourceGroup\";a:0:{}s:17:\"modAccessCategory\";a:0:{}s:28:\"sources.modAccessMediaSource\";a:0:{}}}modx.mgr.user.token|s:52:\"modx51e395a2e874a0.68325019_157a455f0e5e402.12754738\";modx.mgr.session.cookie.lifetime|i:0;newResourceTokens|a:9:{i:0;s:23:\"57a45605303268.73320106\";i:1;s:23:\"57a45647075cd2.53942007\";i:2;s:23:\"57a4572b34eb84.80242165\";i:3;s:23:\"57a457632fac85.80275760\";i:4;s:23:\"57a457880c8df7.94228266\";i:5;s:23:\"57a464c004ef80.59389389\";i:6;s:23:\"57a4650dd3ba15.22377956\";i:7;s:23:\"57a465b4855aa1.52489304\";i:8;s:23:\"57a4665ae8f112.50260657\";}modx.user.1.userGroups|a:1:{i:0;i:1;}')
    Array
    (
        [0] => HY000
        [1] => 2006
        [2] => MySQL server has gone away
    )
    


    Using Gallery and phpthumb (v. 1.4.0).
    Clearing cache didn't help, of course.
    Hosting CPU loaded 100%.
    Don't know what to do.

    Any thinks?

    Thanks.
      • 40706
      • 128 Posts
      MySQL server has gone away should no MODx Problem, maybe its just caused of the high system load:
      http://dev.mysql.com/doc/refman/5.7/en/gone-away.html

      You could try to deactivate Database Sessions, by setting session_handler_class to an empty value.
      The PHP session Handling is also usually faster, then an Database Managed Solution.

      Also look if you have configured (by default ?) that every Page-Save clears all phpThumbOf caches.
      Which produces an huge amount of CPU usage with big or many images.
        • 49998
        • 9 Posts
        Thanks! I will testing new settings for couple of days and will give a report. Thanks again!
          • 49998
          • 9 Posts
          Well, now I get this:

          [2016-08-06 14:48:23] (ERROR @ /index.php) Error HY000 executing statement: 
          Array
          (
              [0] => HY000
              [1] => 2006
              [2] => MySQL server has gone away
          )