ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Upgrade from v1.6 to v 2.4 White Screen Site + CP

March 04, 2012 11:57pm

Subscribe [3]
  • #1 / Mar 04, 2012 11:57pm

    Creatology

    17 posts

    I have just copied an entire site to a new host server. I did not set up the original site nor do I have any cheat notes about what the previous developer did.

    I imported the SQL database and had the site working 100% as EE v1.66.

    I then proceeded to upgrade to v2.4 following the notes carefully. I received the dialogue box suggesting the upgrade was a success and to delete the installer directory to access the control panel. Please note that I changed the system directory name and that was reflected in the path.php and config.php files before the upgrade.

    It all goes a bit pear shaped from here….and I get either a database connection error with a blank database.php file (0kb) or a white screen with the PHP script I believe are necessary to have in place.

    The database php file contains the following:

    <?php if ( ! defined(‘BASEPATH’)) exit(‘No direct script access allowed’);
    removed for security

    ?>

    My config file contains the following script:

    <?php

    if ( ! defined(‘EXT’)){
    exit('Invalid file request');
    }

    $conf[‘app_version’] = “240”;
    $conf[‘license_number’] = “license number with dashes”;
    removed for security
    $conf[‘cookie_prefix’] = “”;
    $conf[‘is_system_on’] = “y”;
    $conf[‘allow_extensions’] = “y”;
    $conf[‘multiple_sites_enabled’] = “n”;
    $config[‘uri_protocol’]  = “QUERY_STRING”;
    $conf[‘site_url’] = “http://test.domain.com.au/”;
    $conf[‘tmpl_file_basepath’] = “/path/to/seaband-admin/expressionengine/templates”;
    $conf[‘theme_folder_url’] = “http://test.domain.com.au/themes/”;
    $conf[‘theme_folder_path’] = “/path/to/themes/”;
    ?>


    The EE v1.66 site I have been given had no database.php only a separate directory under the system folder called db and in that was a db.mysql.php file that was (21Kb). Somehow this database.php I am trying to manually create is missing the mark somehow….have you got any ideas?


    I can run dbtest.php from the site root directory and get the following:
    A connection was established to your database server
    Your database was selected.

    The server that hosts this passed the qualifying criteria before the install but when I checked the PHP version it says 5.1.56

     

  • #2 / Mar 05, 2012 5:30pm

    Robin Sowell

    13255 posts

    Hi Creatology.  I edited some of the config stuff for security.  I actually think you’d done the same, but since I wasn’t dead certain, I pulled some bits out.

    Your database.php config file looked good to me (assuming you’d edited the password and such).  And yes- 1.x didn’t have a separate database.php config file- but from looking at what you had, it appears it was properly written to when you upgraded.  A blank database.php will definitely result in a failure to connect. 

    The config.php file looks a little off, though.  Which is odd.  You didn’t replace it with the old one or anything?  The main thing that’s off is the config array is now called $config instead of $conf- so the top part of mine looks like:

    $config['app_version'] = '240';
    $config['install_lock'] = "";
    $config['license_number'] = "8243-9553-6030-5099";
    $config['debug'] = "1";
    $config['cp_url'] = "http://127.0.0.1:8888/g20/system/index.php";
    $config['doc_url'] = "http://ellislab.com/expressionengine/user-guide/";
    $config['is_system_on'] = "y";
    $config['allow_extensions'] = 'y';
    $config['site_label'] = 'EE 2.4';
    $config['cookie_prefix'] = '';

    Plus- those database configs (password, db, username, host stuff) should have been removed when it wrote them to database.php.  I would think that perhaps the config.php wasn’t writable- but that should have caused an error.  Plus- 2.4.0 is the correct version- it wouldn’t have written that bit and nothing else.

    It’s definitely $conf[ instead of $config[ in your config.php file?  And it’s definitely showing version 2.4.0 in there?

    If so- let’s try two things:
    1. Switch $conf[ to $config[ in that config.php file (this is very odd if you need to do this);
    2. Turn errors on, so we can see what php error is being thrown- so in the ... let’s do this in system/index.php- make sure $debug = 1;  Then look at the control panel- any errors showing?

  • #3 / Mar 05, 2012 5:45pm

    Creatology

    17 posts

    Hi Robin,


    I overwrote the config file which is perhaps indicating that the upgrade didn’t install succesfully…


    I don’t have made changes to config file as follows:
    <?php

    if ( ! defined(‘EXT’)){
    exit('Invalid file request');
    }

    $config[‘app_version’] = “240”;
    $config[‘license_number’] = “1111-1111-1111-1111”;
    $config[‘debug’] = “2”;
    $config[‘install_lock’] = “1”;
    $config[‘system_folder’] = “seaband-admin”;
    $config[‘cp_url’] = “http://test.mydomain.com.au/seaband-admin/index.php”;
    $config[‘doc_url’] = “http://expressionengine.com/docs/”;
    $config[‘cookie_prefix’] = “”;
    $config[‘is_system_on’] = “y”;
    $config[‘allow_extensions’] = “y”;
    $config[‘multiple_sites_enabled’] = “n”;
    $config[‘uri_protocol’]  = “QUERY_STRING”;
    $config[‘site_url’] = “http://test.mydomain.com.au/”;
    $config[‘tmpl_file_basepath’] = “/path/to/seaband-admin/expressionengine/templates”;
    $config[‘theme_folder_url’] = “http://test.mydomain.com.au/themes/”;
    $config[‘theme_folder_path’] = “/path/to/themes/”;
    ?>


    I have changed debug setting in system\index to 1


    I get the following error:

    Fatal error: Call to undefined method CI_Config::site_prefs() in /home/3-web/31/76/mydomain.com.au/public/test/seaband-admin/expressionengine/libraries/Core.php on line 133

    And the following erro from the CP
    Fatal error: Call to undefined method CI_Config::site_prefs() in /home/3-web/31/76/mydomain.com.au/public/test/seaband-admin/expressionengine/libraries/Core.php on line 133


    This is the line in the Libraries/Core.php
    $this->EE->config->site_prefs($this->EE->config->item(‘site_name’));

    What entry do I need here?

  • #4 / Mar 05, 2012 8:05pm

    Robin Sowell

    13255 posts

    Hrm- I wonder if the exp_sites table got corrupted.  Let’s try setting the name in the config and see if that does good enough- add this to the config:

    $config['site_name'] = "My site";
  • #5 / Mar 05, 2012 8:13pm

    Creatology

    17 posts

    Tried this in the config file

    $config[‘site_name’] = “test.mydomain.com.au”; 

    Got the same error

    Fatal error: Call to undefined method CI_Config::site_prefs() in /home/3-web/31/76/mydomain.com.au/public/test/seaband-admin/expressionengine/libraries/Core.php on line 133

     

  • #6 / Mar 06, 2012 5:59pm

    Robin Sowell

    13255 posts

    K- grab the attached download, open up the zip.  Edit the top to reflect your site (the license and cp_url).

    Keep a copy of your current config.php (inside system/expressionengine/config/) and then replace it.  Any difference?  (And my apologies for the delay!)

  • #7 / Mar 06, 2012 6:28pm

    Creatology

    17 posts

    Hi There,


    Can access control panel via login, however main site page is now white.

    None of the original site populated version 2.4…..including:
    - Content
    - Channels
    - Extensions
    - Add Ons
    - Templates
    - Members

    The SQL database seemed to have been overwritten so I reimported the original database to the host. I now get the following:

    Site Error: Unable to Load Site Preferences; Invalid Preference Data

    The dbtest.php returns the following:
    A connection was established to your database server
    Your database was selected.

    Not sure where to go next??? Ideas welcome. Will be online from 7.30am EST

  • #8 / Mar 07, 2012 5:39pm

    Creatology

    17 posts

    Any thoughts

  • #9 / Mar 07, 2012 7:07pm

    Creatology

    17 posts

    Should I just go back to using v1.6 and scrap v2.4 for this site?

    Applying 1 fix every 48 hours is taking too long too achive an outcome…is there any other way?

  • #10 / Mar 08, 2012 6:13pm

    Sean C. Smith

    3818 posts

    Hi Creatology,

    I see in this thread you have already rolled back. When you did the rollback did completely drop the database and start fresh? See the instructions on retrying after a failed up grade. This is very important.

    I’m also closing the other thread so that we can keep the discussion in one central location.

    At this point Is your site working again now that you are back to 1.6.x?

    Sean

  • #11 / Mar 08, 2012 7:31pm

    Creatology

    17 posts

    Thx Sean,

    Reimported the backed up database so yes fresh install.

    Site is working again v1.6.

    CP has no formatting or themeing just text and functionality.

    Just want to get this part up and running before I try progressing further a second time.

    How do I get all the CSS foramting and themeing back in CP?

     

     

  • #12 / Mar 09, 2012 12:08am

    narration

    773 posts

    just passing by and jumping in for the moment, given your time zones.

    _probably_ what is needed is for you to return to the complete and only 1.66 contents of the site/themes folder. Did you remember that, when you backed out of EE2?

    This is where the CP formatting comes from—and any thirdparty themes you need for add-ons.

    There are probably similar needs to have the original 1.66 contents for the images folder.

    In short, you need to have everything back the way it was, not just the system folder and database.

    Good fortune,
    Clive

    Edit: noticed the other thread, and that you are actually copying a site to a different server, even with 1.66.

    Then it’s very important that you update both the URL path and the host filesystem paths for in the way that citadel points out here, for that new server: CP Pathing. Notice that he’s also got a link to the EE User Guide instructions for this.

    Be sure to discover your actual host full filesystem path—something like /www/sites/yoursite/public_html/themes, for that entry.

    Then you also need the URL path, something like http://www.yoursite.com.au/themes. Watch out that citadel said ‘theme’—it’s ‘themes’.

    Watch spellings carefully also, as you are moving from ...co.uk to ...com.au.

    It looks like you have the idea of this over in your config.php file listing on that other thread. Just make sure the config file has the absolutely correct paths for themes.

    Once this works, so that your CP has layout, then looks like you’ll need to do the same for your template paths, so those can be found.

    Once you have these right, things should go well.

    I’m going to leave the rest to support, but I think the advice for upgrading is to upgrade to the latest EE 1.x first, then upgrade to EE 2.x.

     

  • #13 / Mar 09, 2012 5:37pm

    Shane Eckert

    7174 posts

    Hello Creatology,

    Continued from this thread here.

    That tag belongs to the Add-On Structure, correct? Did you update Structure? That syntax error will often come from the Add-On not being installed or an older version not compatible with the latest version of ExpressionEngine.

    Have you tried to upload the themes folder again? That is where the themes get the formatting, images, CSS and such.

    Cheers,

  • #14 / Mar 09, 2012 5:43pm

    Creatology

    17 posts

    Hi Shane,


    When I updated last night to v2.4 it went through the process of clicking form v1.6 to 1.7 - 2.4 etc.

    The only thing I did differently was not change the system folder name until after the update.

    I haven’t copied the v1.6 themes (themes_old) over the top of the v2.4 ones I did during the install - is that what I should be doing? Should I change the 2.4 themes to themes_old and replace with the v1.6 ones?

    How do I re-apply the add ons?

  • #15 / Mar 11, 2012 1:32pm

    Sean C. Smith

    3818 posts

    Hi Creatology,

    In the above post you said the upgrade process went through to 2.4 without an issue. So yes you should be using the 2.4 themes folders and not the 1.6. In the upgrade docs there is no mention of using the v1.6 themes. You should be using the 2.3 themes folder.

    How do I re-apply the add ons?

    By this do you mean re-install? If that is correct, then you’ll need to download the 2.4 compatible version of each add-on and install them as normal. if this is not what you mean, please clarify.

    Sean

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases