SuiteCRM 8 Beta - Install Questions

@rwebb616, strange, that url looks ok. Could you try re-setting the permissions for the .env.local (or all files). My best guess at the moment is that its not being able to read .env.local so no url is set…

Assuming your apache group and user are www-data (may need sudo before the following):

find . -type d  -exec chmod 2775 {} \;
find . -type f  -exec chmod 0644 {} \;
chown -R www-data:www-data .

I applied these permissions.

Could there be something up with the database itself? I could drop the db and go through a complete reinstall if you think that would be helpful. That way it would recreate the db.

Hi @rwebb616,

Don’t think this is db related, seems like the config is not being picked for some reason.

Hi @rwebb616,

I think I found the root cause. Please look at the comments on the following threads:

It is the # sign that is not recognized by PHP’s parse_url() function as valid, this issue is not related to Symfony, but to Doctrine DBAL

Think it could be because you have a # (or some special character?) on your password. Seems an issue with Doctrine DBAL. Do you have a # on your password?

During the install process, I think we need to encode the password, when adding to DATABASE_URL .

I’m going to raise this internally

Hi @broms,

Sorry for the delay in replying.

I’m not 100% sure on it yet, though I have a feeling that your issue with not being able to login, may be related with the following thread. Could you, please, try installing a providing a password without any special characters? (I’m guessing that # and % may cause problems).

As mentioned on the thread, I’ve raised this internally .

Hi @clemente.raposo,

I am using IIS and PHP 8, do you have any suggestions to fix performance issue ?

Thanks,
Milan

Yes, I do have a # sign in my password - so should I change the password? It’s the same password on a version 7 install and works so I take it this is because you’re using a different framework for v8?

Rich

Hi @rwebb616,

  1. In order to keep your password you can url encode the #. Try replacing the # with %23 in DATABASE_URL on .env.local.
  • Notes:
    • other special characters may also need to be encoded.
    • I didn’t try it yet, on the github issues I’ve linked before some people where still having issues with %23. So I’m not 100% on this
  1. The alternative is to use a simple password for the moment, until we change the install command to auto encode the password for you (i.e. to do the same that was explained in 1) )

Hi @milanraval,

I’ll need to investigate a bit on this.

I’ve found some stackoverflow threads about performance with windows + php + symfony. Though I still need to have a better look at it. It seems that symfony can be slower on windows. Adding them here in case they help.

1 Like

Yes, this was it - I was able to get a login screen. Thank you for your help!

hey, sorry for delayed reply. I tried removing the previous install, dropping the DB and re-installing everything. Still getting the same error. This time I used the command-line options so I know there’s no typo in the password:

./bin/console suitecrm:app:install -u “admin” -p “test” -U “my-db-user” -P “my-db-password” -H “localhost” -N “suitecrm8beta” -S “http://myurl/suitecrm8” -d “no”

If I understand, I should be able to login with username: admin and password: test. But I’m getting the login credentials incorrect error.

Everything else with the install script seems to have worked–the login page loads at the URL and the database tables were created and there’s a row for my admin user in the users table.

Seeing this in ./logs/prod/prod.log:

[2021-08-04 15:12:16] request.CRITICAL: Uncaught PHP Exception Doctrine\DBAL\Exception\DriverException: "An exception occurred in driver: could not find driver" at /srv/http/suitecrm8/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/AbstractMySQLDriver.php line 128 {"exception":"[object] (Doctrine\\DBAL\\Exception\\DriverException(code: 0): An exception occurred in driver: could not find driver at /srv/http/suitecrm8/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/AbstractMySQLDriver.php:128, Doctrine\\DBAL\\Driver\\PDO\\Exception(code: 0): could not find driver at /srv/http/suitecrm8/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDO/Exception.php:18, PDOException(code: 0): could not find driver at /srv/http/suitecrm8/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDOConnection.php:39)"} []

Any ideas how to resolve? Running php 7.3.29-1, apache 2.4.48-1, mariadb 10.5.11-1

Hi @broms,

Thank you for the feedback. Those logs help a lot.

Could you check if you have the pdo_mysql php extension installed, please? From the logs that seems to be the problem.

You can run php -m to check the extensions.

Extra notes

At first it seemed strange how you were able to run the command and install.
Though it now makes a bit more sense.

The install process calls legacy. Legacy only depends on the mysqli extension.

Now, the login, goes through Suite 8 side, and suite 8 uses symfony and doctrine which required the pdo_mysql extension.

@samus-aran, we should probably add a clear list of the php module dependencies to the Compatibility matrix or to the Installation guide on docs.

Nailed it. Uncommenting the extension=pdo_mysql line in php.ini resolves login problem. Thanks a bunch for helping me get up and running!

Alrighty! I’ve created an issue on SuiteDocs GitHub for this. https://github.com/salesagility/SuiteDocs/issues/526

1 Like

Hi there,

I’m having issues getting the new interface up and running.
I’ve been able to install via the CLI and can login using the Legacy URL, (http://localhost/legacy/index.php?action=Login&module=Users), however the new login page just keeps on telling me that the username and password are incorrect. The console logs a polyfills-es2015.af170ffe981b0ba2d77d.js:118 POST http://localhost/login 500 (Internal Server Error).
In the logs I also get:
request.CRITICAL: Uncaught PHP Exception Doctrine\DBAL\Exception\ConnectionException: "An exception occurred in driver: SQLSTATE[HY000] [2002] No such file or directory" at /var/www/html/SuiteCRM/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/AbstractMySQLDriver.php line 112 {"exception":"[object] (Doctrine\\DBAL\\Exception\\ConnectionException(code: 0): An exception occurred in driver: SQLSTATE[HY000] [2002] No such file or directory at /var/www/html/SuiteCRM/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/AbstractMySQLDriver.php:112, Doctrine\\DBAL\\Driver\\PDO\\Exception(code: 2002): SQLSTATE[HY000] [2002] No such file or directory at /var/www/html/SuiteCRM/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDO/Exception.php:18, PDOException(code: 2002): SQLSTATE[HY000] [2002] No such file or directory at /var/www/html/SuiteCRM/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDOConnection.php:39)"} []
I’ve confirmed that pdo_mysql is installed and is running, I’ve also checked to ensure that rewrites is enabled. I just cant see what I’m doing wrong :frowning:
Running Apache2 with PHP8 on Ubuntu (latest) inside of Docker/Docker-Compose.
Cheers!

Hi @jont_titmus,

Welcome to the community :wave: and thanks for trying out SuiteCRM 8 beta.

Also, thanks for posting the logs, thats helpful.

Could you check if you have mysqli extension installed, please? From the logs it seems like it could be it.

Hope this helps

Hey @clemente.raposo,

Thanks! And thanks for the swift reply :slight_smile:

Yes, mysqli is installed and running:
php -m
[PHP Modules]
calendar
Core
ctype
curl
date
dom
exif
FFI
fileinfo
filter
ftp
gettext
hash
iconv
intl
json
libxml
mysqli
mysqlnd
openssl
pcntl
pcre
PDO
pdo_mysql
Phar
posix
readline
Reflection
session
shmop
SimpleXML
sockets
sodium
SPL
standard
sysvmsg
sysvsem
sysvshm
tokenizer
xml
xmlreader
xmlwriter
xsl
Zend OPcache
zip
zlib

[Zend Modules]
Zend OPcache

Hi @jont_titmus,

Thanks for the feedback.

Was looking into this issue.

Found some threads, talking about this issue. More on this

https://github.com/maxpou/docker-symfony/issues/72#issuecomment-363049962

My guess at the moment is that it could be docker config related issue. I Imagine you have your db setup on a separate service of docker compose, something like:

db:
    image: mysql
    ports:
    - "3306:3306"
    environment:
        ...

if so, on the db url are you using localhost / 127.0.0.1 for the server address? Could you try using the name of your docker database service, on the above example is db. You can change this on .env.local file that should have been generated on install.

Hey @clemente.raposo,

This is my docker config for mysql:
mysql_crm:
image: mariadb:10.4
ports:
- “3306:3306”
environment:
- MYSQL_ROOT_PASSWORD=suitecrm
- MYSQL_USER=suitecrm
- MYSQL_PASSWORD=suitecrm
- MYSQL_DATABASE=suitecrm
volumes:
- ./docker/config/mysql:/etc/mysql/conf.d
- ./docker/data/mysql:/var/lib/mysql
networks:
- suitecrm_net

And this is the DB config in .env.local:
DATABASE_URL=“mysql://suitecrm:suitecrm@mysql_crm:3306/suitecrm”