If you face any problem during the Environment check, you get general instructions about fixing it. You can pass it to your developers or hosting team, and they will be able to take care of it.
This article describes typical problems you may encounter during the software installation and what you can do to fix them.
Auth Code Requested at Step 1: License Agreement
In case the installation wizard is run not for the first time, the system will request an Auth Code on the step of accepting the License Agreement:
The Auth Code is stored in the etc/config.php file of an X-Cart package that has been downloaded to the server. Check for the auth_code
line there and copy the value to paste it on the License Agreement page.
Problems with Connection to Database
Such problems generally mean that you specified MySQL credentials incorrectly or MySQL server/database is incorrectly set up.
Examples:
FATAL ERROR: Cannot connect to the specified MySQL server : SQLSTATE[28000] [1045] Access denied for user 'tony'@'localhost' (using password: YES) Click the 'BACK' button and review the MySQL server settings provided
Such an error message means that your MySQL login or password is incorrect. You need to double-check your MySQL credentials and input them correctly.
Note: sometimes, this problem can happen even when you specify login and password correctly, but there is actually a problem with MySQL user preferences. You can check it in the following manner: go to the phpMyAdmin console of your server and check the MySQL user’s Host field. If it is specified as % (Any host), you should remove this MySQL user and create a new one with the same name but specify Host field as localhost (Local).
FATAL ERROR: Cannot connect to specified MySQL server : SQLSTATE[HY000] [1044] Access denied for user 'tony'@'localhost' to database 'xcart' Click the 'BACK' button and review the MySQL server settings you have provided.
Such an error message means that your MySQL login/password allowed X-Cart to log to the MySQL server, but your database does not exist, or your MySQL user cannot access it. You should log into your MySQL dashboard and make sure that your database exists and the MySQL user has access to it.
Other MySQL errors like:
FATAL ERROR: Cannot connect to the specified MySQL server : SQLSTATE[HY000] [2002] No connection could be made because the target machine actively refused it.
FATAL ERROR: Cannot connect to the specified MySQL server : SQLSTATE[HY000] [2002] The requested address is not valid in its context.
FATAL ERROR: MySQL server doesn't support InnoDB engine. It is required for X-Cart 5 operation(current version is 5.1.73-cll)mean that there is something wrong with your MySQL server settings. You need to send such an error message to your hosting team and ask them to fix it.
Permission Check Failed
Such error messages may look like this:
Permissions checking failed. Please make sure that the following file permissions are assigned (UNIX only):
chmod 666 /home/tony/public_html/xcart/.htaccess
or
Permissions checking failed. Please make sure that the following file permissions are assigned (UNIX only):
chmod 0777 /Applications/MAMP/htdocs/xcart/
find /Applications/MAMP/htdocs/xcart/var -type d -exec chmod 0777 {} \;
find /Applications/MAMP/htdocs/xcart/var -type f -exec chmod 0666 {} \;
find /Applications/MAMP/htdocs/xcart/images -type d -exec chmod 0777 {} \;
find /Applications/MAMP/htdocs/xcart/images -type f -exec chmod 0666 {} \;
find /Applications/MAMP/htdocs/xcart/files -type d -exec chmod 0777 {} \;
find /Applications/MAMP/htdocs/xcart/files -type f -exec chmod 0666 {} \;
chmod 666 /Applications/MAMP/htdocs/xcart/etc/config.php
chmod 666 /Applications/MAMP/htdocs/xcart/.htaccess
Such error messages mean that some files do not have suitable permissions, and you must correct them manually. Copy the instructions suggested and run them using the Terminal section in your Control Panel.
There are several examples of error message for a better understanding of the process:
chmod 666 /home/tony/public_html/xcart/.htaccess
Such instruction means that all users must have readable and writable permissions for the
/home/tony/public_html/xcart/.htaccess
file.
find /Applications/MAMP/htdocs/xcart/var -type d -exec chmod 0777 {} \;
Such instruction means that all users must have all possible permissions (
chmod 0777
) to all directories(-type d
) inside/Applications/MAMP/htdocs/xcart/var
folder.
Similarly to above
find /Applications/MAMP/htdocs/xcart/files -type f -exec chmod 0666 {} \;
this instruction means that all users must have readable and writeable permissions (
chmod 0666
) to all files(-type f
) inside the /Applications/MAMP/htdocs/xcart/var folder.
Disabled Functions
Your hosting company may disable several default PHP functions, and X-Cart 5 cannot work while they are disabled. In this case, you will get an error message like this:
There are disabled functions (phpinfo, escapeshellcmd, escapeshellarg, openlog, syslog, exec, popen) that may be used by software in some cases and should be enabled
The list of disabled functions can be different.
To solve this issue, you should send the list of disabled PHP functions (phpinfo, escapeshellcmd, escapeshellarg, openlog, syslog, exec, popen from the example above) to your hosting team and ask to enable them in your account.
Disabled PHP Extensions
If you are getting an error message like this:
PDO extension with MySQL support must be installed.
it means that your server does not support the library to work with MySQL via PDO. PDO is an extension that ensures safe work with databases, and it is required for proper X-Cart 5 work. Ask your hosting team to enable it for your hosting account.
If you are on a local machine, you need to edit your php.ini file, uncomment the following line there, and restart Apache.
;extension=pdo_mysql.so it should become extension=pdo_mysql.so
HTTPS Bouncer Is Not Installed
If you are getting an error message like this:
libcurl extension not found
it means that the libCurl system library is not enabled in your account, and your PHP scripts cannot create connections to other services. Ask your hosting team to enable libCurl for you.
The "Setting up cURL" article may be helpful if you are installing X-Cart 5 on your local server.