We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 24007
    • 38 Posts
    So essentially I recently moved another site over from an old shared platform to a VPS.
    Backed up the database, backed up the files.
    Setup the database on the VPS
    Changed all the config php file as per the instructions.
    changed the path in the workspaces table of the new database.

    cache folder was cleared and given write permissions.

    Used the test_config.php script to see what came up.

    Error message is :-
    $database_dsn is not set correctly. It should read: mysql:host=xxx.xxx.xxx.xxx;dbname=`mydatabasename`;charset=utf8

    (Naturally the ip address has been replaced with x's in this post along with a false database name)

    I'm feeling a bit fried, so could someone please help me resolve this.

    Thanks
      • 28042 ☆ A M B ☆
      • 24,524 Posts
      That's in the config.inc.php file...here's my localhost setting
      $database_dsn = 'mysql:host=localhost;dbname=revo228;charset=utf8';
      

        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
        • 24007
        • 38 Posts
        Forgot to mention that its revo 2.0.8 so as yet I could not locate the variable '$database_dsn' in the config.inc.php file
          • 28042 ☆ A M B ☆
          • 24,524 Posts
          Then try putting one in. Like this:
          $database_type = 'mysql';
          $database_server = 'localhost';
          $database_user = 'root';
          $database_password = 'root';
          $database_connection_charset = 'utf8';
          $dbase = 'revo228';
          $table_prefix = 'modx_';
          $database_dsn = 'mysql:host=localhost;dbname=revo228;charset=utf8';
          

            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
            • 24007
            • 38 Posts
            No dice,

            tried adding the variable with and without back ticks '`' around the database name.

            This time there is no readable error other than an internal server error 500 standard chrome browser page (this is for the test_config.php)
            The 503 error is still present when the server tries to parse the index.php at the web root
              • 28042 ☆ A M B ☆
              • 24,524 Posts
              What about any .htaccess files? What web server is your VPS using?

              Did you try running setup in upgrade mode?
                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
                • 24007
                • 38 Posts
                Well I first off tried removing the htaccess file.

                I've traced the correct version of revo from the database so now I have the correct version to overwrite the existing one.

                The server is CentOS 6.4 with a plesk panel.
                Running PHP 5.3.3, with php.ini configurable settings.
                Have full access to the Apache modules

                here is an error log excerpt:-

                mod_fcgid: stderr: PHP Fatal error:  require_once(): Failed opening required '/var/www/vhosts/mywebsite.com/httpdocs/core/xpdo/xpdo.class.php' (include_path='.:') in /var/www/vhosts/mywebsite.com/httpdocs/core/model/modx/modx.class.php on line 41
                  • 24007
                  • 38 Posts
                  Weird some empty files, a failed transfer it seems also, spuriously odd permissions on folders which denied write access