We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 17698
    • 19 Posts
    I've been trying to upgrade a site from 2.1.5 to 2.2.4 (Current Release). Which I've been unable to complete even though every time the setup script tells me I've successfully completed it. After many frustrating attempts, I decided to do the upgrade incrementally 2.1.5 > 2.2.0-pl2 > 2.2.1 > 2.2.2 > 2.2.3 > 2.2.4.

    All upgrades through 2.2.3 were success with minimal errors in the core/cache/logs/install.config.*.log file. But whenever I run the upgrade setup for 2.2.4, this file is filled (300+KB) with errors similar to the following:

    [2012-06-27 18:37:55] (ERROR @ /setup/index.php) Error HY000 executing statement:
    Array
    (
    [0] => HY000
    [1] => 2006
    [2] => MySQL server has gone away
    )

    [2012-06-27 18:37:55] (ERROR @ /setup/index.php) Error HY000 executing statement:
    INSERT INTO `modx_namespaces` (`name`, `path`, `assets_path`) VALUES ('core', '{core_path}', '{assets_path}')
    Array
    (
    [0] => HY000
    [1] => 2006
    [2] => MySQL server has gone away
    )

    [2012-06-27 18:37:55] (ERROR @ /setup/index.php) Error saving vehicle object of class modNamespace; criteria: core
    [2012-06-27 18:37:55] (ERROR @ /setup/index.php) Error HY000 executing statement:
    Array
    (
    [0] => HY000
    [1] => 2006
    [2] => MySQL server has gone away
    )

    I set my mysql.connect_timeout & default_socket_timeout to 600 and my max_execution_time to 180 in the root and setup folders via local php.ini configuration. I've been successful jumping directly from 2.1.5 to 2.2.3 using this setup. But the 2.2.4 upgrade fails with a massive number "MySQL server has gone away" errors.

    This is running on a managed dedicated server (no root access) with minimal traffic, so mysql shouldn't be overly taxed. But I've contacted the host to make sure, there isn't some other issue. The thing that sends up red flags, is I've had no issues with any other version upgrading. Could something in 2.2.4 be closing the connection prematurely under certain circumstances during an upgrade?

    Clean installs of 2.2.4 seem to work properly.

    Any thoughts? [ed. note: lutenegger last edited this post 14 years, 3 months ago.]
      Erik Lutenegger
      Founder | Tenacity
      • 22303 MODX Staff
      • 10,725 Posts
      Sounds odd; how did you put the 2.2.4 files on the server? Did you FTP transfer each individual file, or FTP the zip and extract it on server in the proper location?
        • 17698
        • 19 Posts
        FTP each individual file. Filezilla with overwrite on.
          Erik Lutenegger
          Founder | Tenacity
          • 10208 ☆ A M B ☆
          • 1,780 Posts
          FTP the zip, then extract it on the server itself. Apparently ftp is unreliable and can miss or corrupt some files.

          Not to mention a heck of a lot slower than the filemanger on the server.

          Re-extract a new zip and then re-run setup.
            Frogabog- MODX Websites in Portland Oregon
            "Do yourself a favor and get a copy of "MODX - The Official Guide" by Bob Ray. Read it.
            Having server issues? These guys have MODX Hosting perfected - SkyToaster
            • 17698
            • 19 Posts
            Well that seems to do the tricked. The speed difference wasn't terribly different, few minutes at most, our work connection is ridiculously fast.

            Thanks for the help. But, of course, now I want to know what the difference is, and why there were no issues with the other versions.
              Erik Lutenegger
              Founder | Tenacity
              • 32316
              • 387 Posts
              But, of course, now I want to know what the difference is, and why there were no issues with the other versions.
              Are you sure?? Sometimes its best not to know!!! (Tongue planted firmly in cheek)
              Seriously - modx has lots of files, ftp upload of all of them seems to be prone to the occasional error (it only takes one... ) - it really is not worth your time to know what the exact error was, just that it seems much more reliable to upload the .zip and extract in place on the server.

              Of course you might start to wonder whether the whole system is too complicated, but that is a topic for some other thread or venue even.
                • 17698
                • 19 Posts
                Yeah, there is no way, I will spend time on it.

                We always come to trust the tools we use. Whether its MODX or Filezilla, when something says 4000+ success transfers 0 failed, you want to believe it, just like when you see Successfully Installed with no warnings you want to believe it. I suppose if I know the latter isn't necessarily true, the former isn't either.

                Of course you might start to wonder whether the whole system is too complicated, but that is a topic for some other thread or venue even.
                Yes, one does occasionally wonder that.
                  Erik Lutenegger
                  Founder | Tenacity