0

I apologize for a question that I know has been asked and answered. However, I don't have enough reputation to reply to the answer, just to provide another "answer", which I don't have. Instead I have a complication.

I've grabbed my v3 files from this post, which I began following last year when I upgraded from 1 to 2. I've procrastinated upgrading to 5, but would like to do so within the next day or two if possible. The error I'm running into can be found in this post, which is where the problem arises: that's not what my config file looks like.

$config['app_version'] = '2.10.1';
$config['license_contact'] = "";
$config['license_number'] = '';
$config['debug'] = '1';
$config['cp_url'] = '';
$config['doc_url'] = 'http://ellislab.com/expressionengine/user-guide/';
$config['is_system_on'] = 'y';
$config['allow_extensions'] = 'y';
$config['cache_driver'] = "";
$config['install_lock'] = '1';
$config['db_hostname'] = '';
$config['db_username'] = '';
$config['db_password'] = '';
$config['db_name'] = '';
$config['db_type'] = 'mysql';
$config['db_prefix'] = 'exp';
$config['db_conntype'] = '0';
$config['system_folder'] = 'system';
$config['cookie_prefix'] = '';
$config['multiple_sites_enabled'] = 'n';

That's a blank example of what my config.php file in the user folder looks like. I followed the official instructions and yet hit this error. Is this an outdated config file? Could my database.php file also be outdated? Is there an empty config file I can use that's more up-to-date and in line with the answer from the other post?

I'm sorry to create a new question for something that's been answered, but that answer only provided more questions and StackExchange won't let me address that person's reply directly. Any assistance on this matter is appreciated.

Oh, and for what it's worth, I'm not using any 3rd party add-ons, so my step-by-step upgrade shouldn't be that much of a hassle. Shouldn't be. Sadly, it seems to be.

Thank you for any assistance.

2 Answers 2

0

Unclear from question if you have an issue, or are trying to pre-empt an issue.

I think you are saying you plan to upgrade and are concerned that your config.php file does not look like the example @jrothafer suggests in the answer you link to.

EE2 splits the config information between config.php and database.php - in EE3 and up the two files are merged into a single combined config.php file; in that file the format for defining the database connection is a bit different to that used in the EE2 database.php file.

So it is no surprise that the config.php file you have looks different - you did not include the database.php information, and it is a different format anyhow.

EE will rewrite your EE2 config files into a new conformant one during the upgrade process - so provided your EE2 site can access its database before the update, you should be good after the update also.

HTH - if I have misunderstood your question perhaps you can clarify the question where I'm mistaken, and I'll try to improve the answer...

additional based on your comment

If you want to manually add the database configuration to an EE3 config.php file you need to complete / add entries similar to the following:

    'expressionengine' => array(
        'hostname' => ' ... ', // Could be an IP, 'localhost', or a valid DNS lookup
        'database' => ' ... ', // The name of your EE database
        'username' => ' ... ', // The username of a super-admin account
        'password' => ' ... ', // A password for the super-admin account
        'dbprefix' => 'exp_', 
        'char_set' => 'utf8mb4',
        'dbcollat' => 'utf8mb4_unicode_ci',
        'port'     => ''
    ),

HTH

8
  • Sorry, I am already running into the error that was presented in the linked problem. I have followed the instructions trying to upgrade from 2 to 3, and I am getting that database error. For some reason it seems the database itself is not being defined. This is an excerpt of my database.php file, left empty, but only an excerpt due to character limits. $active_group = ''; $active_record = ; $db['expressionengine']['hostname'] = ''; $db['expressionengine']['username'] = ''; $db['expressionengine']['password'] = ''; So I guess I need to know where to define it?
    – ccesarano
    Commented Sep 19, 2020 at 0:23
  • In EE3. Database infos are in config.php. i guess if you copy this $config['database'] = array ( 'expressionengine' => array ( 'hostname' => '', 'username' => '', 'password' => '', 'database' => '' ), ); in your config.php and put the right infos. You should be good.
    – Benoit L
    Commented Sep 19, 2020 at 1:56
  • If your database.php file is empty then it is difficult to see how the EE2 installation worked... and how / what EE3 upgraded during the upgrade process. Commented Sep 19, 2020 at 8:12
  • To @BenoitL, what folder would that config.php file you're referencing be located in? To JCOGSDesign, sorry if I'm not being clear. When I say "empty", I mean my actual database info has been removed from the code I'm dropping in the comment. Don't want to place that out in public, right?
    – ccesarano
    Commented Sep 20, 2020 at 3:54
  • The config.php file can be found in system/user/config - HTH Commented Sep 20, 2020 at 11:45
0

So I figured out the real problem. The actual answer can be found over here.

I downloaded the Master of 3 from GitHub rather than the files with 3.5 with the actual installer. So I was following the official instructions correctly, just didn't grab the correct files. So if you run into this error, it has nothing to do with your config files. You need to grab the .zip (NOT source code) from this page.

Thanks to those that replied and tried to help me work through this.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.