We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 49944
    • 21 Posts
    Hi all

    I'll start by saying I know *nothing* about ModX. I simply administer the web server that our site is hosted on (Ubuntu 14.04LTS) and I've inherited the website.

    The upgrade from 2.6.6 to 2.3.3 (traditional) worked fine, there were no errors and I got the success message. The site itself seems to be working too. But when I access the /manager URL, and I login (login is successful, my password is verified) I get a blank page. Nothing seems to be getting logged - anywhere - on the server, so something must be dieing somewhere but I need to understand how to go about finding what's wrong?

    Can anyone suggest how I increase logging, or debug it, or get it to write to a log file etc.? If it helps, if I add some debug statements around /manager/index.php, everything works fine until the call to

    $modx->request->handleRequest();

    e.g. an Echo Hello before that line succeeds but if I place the "Hello" after that line I get the blank page.

    Many thanks



    Jim
      • 28042 ☆ A M B ☆
      • 24,524 Posts
      1. Make sure your browser cache and cookies are cleared.

      2. Delete the core/cache directory (yes, the whole cache directory, MODX will re-generate it as it's needed).

      If that doesn't work, we'll consider stronger measures.
        Studying MODX in the desert - http://sottwell.com
        Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
        Join the Slack Community - http://modx.org
        • 49944
        • 21 Posts
        Quote from: sottwell at Feb 24, 2015, 11:50 AM
        1. Make sure your browser cache and cookies are cleared.

        2. Delete the core/cache directory (yes, the whole cache directory, MODX will re-generate it as it's needed).

        If that doesn't work, we'll consider stronger measures.

        Many thanks sottwell, but stronger measures are needed sad I've cleared the cache and browser - I've even tried a virtual machine where I can guarantee I haven't access the site before - but I get the same. I've also cleared the core/cache folder, and after visiting the site I can see a load of folders being recreated.

        But still the blank page, and no sign of anything being logged. I've tried renaming the .htaccess files in the root and the manager folder, in case they're having any impact, but no change.

        EDIT These are the logs folders I can find, but nothing useful in any of them, and nothing in the /var/log/apache/oursite/error_log file:

        /var/www/oursite.com/2013/layout/.git/logs
        /var/www/oursite.com/2013/manager/controllers/default/system/logs
        /var/www/oursite.com/2013/manager/templates/default/system/logs
        /var/www/oursite.com/2013/manager/templates/thrislington/system/logs

        Happy to give you access to the site....via PM.....
          • 28042 ☆ A M B ☆
          • 24,524 Posts
          You say you upgraded from 2.6.6, that can't be right. Exactly what did you have originally?

          I'd say it's a bad upgrade. Files were corrupted or lost.

          Get this install.php script and put it in your MODX installation root (along with the index.php file), then run it from your browser. Select the standard version, wait for the script to download and extract and move the files, then run the setup again in upgrade mode.

          https://github.com/sottwell/installer
            Studying MODX in the desert - http://sottwell.com
            Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
            Join the Slack Community - http://modx.org
            • 28042 ☆ A M B ☆
            • 24,524 Posts
            Usually a blank page means a fatal PHP error, so you would need to look in the server's PHP error logs. A fatal PHP error means that MODX can't even be run, so it can't write anything to its own logs.
              Studying MODX in the desert - http://sottwell.com
              Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
              Join the Slack Community - http://modx.org
              • 49944
              • 21 Posts
              Unfortunately there's practically nothing in the /var/log/apache2/siteame/errorlog file

              I'll download your installer and report back.
                • 49944
                • 21 Posts
                Hi again


                No joy, I've run your installer script, completed the process, and I still get a blank page.

                ============

                Installation Summary

                Pre-installation tests were successful. Click Install below to continue.

                Checking PHP version: OK! Running: 5.5.9-1ubuntu4.6

                Checking PHP for zlib dependency: OK!

                Checking for SimpleXML: OK!

                Checking if memory limit is set to at least 24M: OK! Set to 128M

                Checking if sessions are properly configured: OK!

                Checking if /var/www/thrislingtoncubicles.com/2013/core/cache directory exists: OK!

                Checking if /var/www/thrislingtoncubicles.com/2013/core/cache directory is writable: OK!

                Checking if /var/www/thrislingtoncubicles.com/2013/core/export directory exists: OK!

                Checking if /var/www/thrislingtoncubicles.com/2013/core/export directory is writable: OK!

                Checking if /var/www/thrislingtoncubicles.com/2013/core/packages directory exists: OK!

                Checking if /var/www/thrislingtoncubicles.com/2013/core/packages directory is writable: OK!

                Checking if /var/www/thrislingtoncubicles.com/2013/core/config/config.inc.php exists and is writable: OK!

                Creating connection to the database: OK!

                Checking to make sure safe_mode is off: OK!

                Checking for suhosin issues:OK!

                Checking if we should disable CSS/JS compression: Not selected, skipping test.








                Installation Summary

                Core installation was successful. Click next to complete the installation process.





                =================
                  • 49944
                  • 21 Posts
                  This is the contents of our core/config/config.inc.php:

                  /**
                  * MODX Configuration file
                  */
                  $database_type = 'mysql';
                  $database_server = 'localhost';
                  $database_user = 'xxx';
                  $database_password = 'xxx';
                  $database_connection_charset = 'utf8';
                  $dbase = 'xxx';
                  $table_prefix = 'modx_';
                  $database_dsn = 'mysql:host=localhost;dbname=xxx;charset=utf8';
                  $config_options = array (
                  );
                  $driver_options = array (
                  );

                  $lastInstallTime = 1424805265;

                  $site_id = 'xx.xx';
                  $site_sessionname = 'xx';
                  $https_port = '443';
                  $uuid = '311e48d4-c9a5-xx-xx-xx';

                  if (!defined('MODX_CORE_PATH')) {
                  $modx_core_path= '/var/www/thrislingtoncubicles.com/2013/core/';
                  define('MODX_CORE_PATH', $modx_core_path);
                  }
                  if (!defined('MODX_PROCESSORS_PATH')) {
                  $modx_processors_path= '/var/www/thrislingtoncubicles.com/2013/core/model/modx/processors/';
                  define('MODX_PROCESSORS_PATH', $modx_processors_path);
                  }
                  if (!defined('MODX_CONNECTORS_PATH')) {
                  $modx_connectors_path= '/var/www/thrislingtoncubicles.com/2013/connectors/';
                  $modx_connectors_url= '/connectors/';
                  define('MODX_CONNECTORS_PATH', $modx_connectors_path);
                  define('MODX_CONNECTORS_URL', $modx_connectors_url);
                  }
                  if (!defined('MODX_MANAGER_PATH')) {
                  $modx_manager_path= '/var/www/thrislingtoncubicles.com/2013/manager/';
                  $modx_manager_url= '/manager/';
                  define('MODX_MANAGER_PATH', $modx_manager_path);
                  define('MODX_MANAGER_URL', $modx_manager_url);
                  }
                  if (!defined('MODX_BASE_PATH')) {
                  $modx_base_path= '/var/www/thrislingtoncubicles.com/2013/';
                  $modx_base_url= '/';
                  define('MODX_BASE_PATH', $modx_base_path);
                  define('MODX_BASE_URL', $modx_base_url);
                  if(defined('PHP_SAPI') && (PHP_SAPI == "cli" || PHP_SAPI == "embed")) {
                  $isSecureRequest = false;
                  } else {
                  $isSecureRequest = ((isset ($_SERVER['HTTPS']) && strtolower($_SERVER['HTTPS']) == 'on') || $_SERVER['SERVER_PORT'] == $https_port);
                  }
                  if (!defined('MODX_URL_SCHEME')) {
                  $url_scheme= $isSecureRequest ? 'https://' : 'http://';
                  define('MODX_URL_SCHEME', $url_scheme);
                  }
                  if (!defined('MODX_HTTP_HOST')) {
                  if(defined('PHP_SAPI') && (PHP_SAPI == "cli" || PHP_SAPI == "embed")) {
                  $http_host='www.thrislingtoncubicles.com';
                  define('MODX_HTTP_HOST', $http_host);
                  } else {
                  $http_host= array_key_exists('HTTP_HOST', $_SERVER) ? $_SERVER['HTTP_HOST'] : 'www.thrislingtoncubicles.com';
                  if ($_SERVER['SERVER_PORT'] != 80) {
                  $http_host= str_replace(':' . $_SERVER['SERVER_PORT'], '', $http_host); // remove port from HTTP_HOST
                  }
                  $http_host .= ($_SERVER['SERVER_PORT'] == 80 || $isSecureRequest) ? '' : ':' . $_SERVER['SERVER_PORT'];
                  define('MODX_HTTP_HOST', $http_host);
                  }
                  }
                  if (!defined('MODX_SITE_URL')) {
                  $site_url= $url_scheme . $http_host . MODX_BASE_URL;
                  define('MODX_SITE_URL', $site_url);
                  if (!defined('MODX_ASSETS_PATH')) {
                  $modx_assets_path= '/var/www/thrislingtoncubicles.com/2013/assets/';
                  $modx_assets_url= '/assets/';
                  define('MODX_ASSETS_PATH', $modx_assets_path);
                  define('MODX_ASSETS_URL', $modx_assets_url);
                  }
                  if (!defined('MODX_LOG_LEVEL_FATAL')) {
                  define('MODX_LOG_LEVEL_FATAL', 0);
                  define('MODX_LOG_LEVEL_ERROR', 1);
                  define('MODX_LOG_LEVEL_WARN', 2);
                  define('MODX_LOG_LEVEL_INFO', 3);
                  define('MODX_LOG_LEVEL_DEBUG', 4);
                  }
                  if (!defined('MODX_CACHE_DISABLED')) {
                  $modx_cache_disabled= false;
                  define('MODX_CACHE_DISABLED', $modx_cache_disabled);
                  }



                  Also, we have NO .htaccess files in the root or in the manager folder (we did have, but I've renamed them for now).

                  Many thanks for your help.



                  Jim
                    • 49944
                    • 21 Posts
                    Finally, this is what I see in my apache accesslog when I browse to manager:

                    [24/Feb/2015:19:24:01 +0000] "GET /manager/ HTTP/1.1" 500 486 "http://www.thrislingtoncubicles.com/manager/" "Mozilla/5.0 (Windows NT 6.3; WOW64; rv:35.0) Gecko/20100101 Firefox/35.0"

                    500 - internal server error.
                      • 28042 ☆ A M B ☆
                      • 24,524 Posts
                      Do you have a date.timezone setting in your php.ini?
                        Studying MODX in the desert - http://sottwell.com
                        Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
                        Join the Slack Community - http://modx.org