Jump to content
  • 0

Installation Error: BLESTA_VERSION Undefined


JaxSite

Question

I am attempting to install the latest version of Blesta 4.1.2 for development and testing. I first tried to install locally on my Mac but was unsuccessful. I knew there were differences in my local AMPPS setup vs my production server, so I opted to try and install on the production server in another subdomain/folder. This production server runs my main instance of Blesta. I just recently upgraded it from 3.x to 4.1.2 without problems.

During installation, it tells me I meet the minimum and recommended requirements, etc. I fill out my database info and click INSTALL. The progress bar gets about 80% complete then routes me to ../admin/login/setup and the page is blank. I've checked Chrome Dev tools and nothing is returned. It does return a 200 OK. I've dropped the database tables, removed the code, and tried again with the same result. Upon checking my error log, it showed the following:

Quote

Use of undefined constant BLESTA_VERSION - assumed 'BLESTA_VERSION' {"code":8,"message":"Use of undefined constant BLESTA_VERSION - assumed 'BLESTA_VERSION'","file":"/home/user/subdomain/dev/app/models/license.php","line":0}

Based on the post here I modified my MySQL my.cnf file with the following and restarted mysqld but still get the same error.

wait_timeout=2400 
connect_timeout=360

Any ideas or help would be much appreciated.

 

Regards,

Jonathan | JaxSite

Link to comment
Share on other sites

9 answers to this question

Recommended Posts

  • 0

Do you have special characters in your MySQL password? You may need to escape them in the /config/blesta.php config file with back slashes \ or use a password that does not have special characters.  You should be able to correct the issue by updating your config file, and then you can complete the setup.

Link to comment
Share on other sites

  • 0

Are you able to attempt the install via CLI? php ./index.php install

If you are getting a /config/blesta.php config file, you can enable error reporting and debugging and try accessing the /admin/login/setup screen again and see if any errors are output. Here's how to enable error reporting and debugging:

Quote

To enable error reporting, edit /config/blesta.php and change Configure::errorReporting(0); to Configure::errorReporting(-1); You may also wish to enable System Debug. To do so, change Configure::set("System.debug", false); to Configure::set("System.debug", true);

Be sure to change these settings back when you are done.

 

Link to comment
Share on other sites

  • 0

Paul,

I ran the installation via command line and it showed everything completed. It told me to go to /admin/login/ in browser and then I get the same blank screen. So I turned on errors and this is what I got:

Quote

SQLSTATE[HY000] [1045] Access denied for user 'jaxsite_blesta_d'@'localhost' (using password: YES) on line 74 in /home/jaxsite/bd.jaxsite.com/core/ServiceProviders/MinphpBridge.php

The installation connected to the database just fine because it creates all the tables.

 

-Jonathan

blesta-install-error.png

Link to comment
Share on other sites

  • 0

Yes I use a dollar sign like this:

////////////////////////////////////////////////////////////////////////////////
// Database
////////////////////////////////////////////////////////////////////////////////
// Database connection information
Configure::set(
    'Blesta.database_info',
    [
        'driver' => 'mysql',
        'host' => 'localhost',
        //'port' => "8889",
        'database' => 'some_database',
        'user' => 'some_user',
        'pass' => 'SomePassword1234\$',
        'persistent' => false,
        'charset_query' => "SET NAMES 'utf8'",
        'sqlmode_query' => "SET sql_mode='TRADITIONAL'",
        'options' => []
    ]
);

 

-Jonathan

Link to comment
Share on other sites

  • 0

Another cool update. So this whole thing started when I tried to install Blesta locally on my MacBook Pro running AMPPS. I shifted to installing it on my production server via another subdomain. Thanks to your help Paul, I was able to get it running. So I went back to my laptop and turned on error reporting and debugging. It turns out I was getting a "Session already started..." error. AMPPS default setting in php.ini was session.auto_start = 1. I set that to 0 and everything works locally now too!

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...