0

I'm trying to install Magento 2.4.0 and I keep getting the "Access Denied" for user: 'root'@'localhost' (using password: NO) I'm using Wamp64 Web Server to configure it and using Mysql 8.0.21. I can see that my root user has all privileges' granted to the magento DB. Also, root has a password but is showing with NO Password. This is the install command I'm trying:

Administrator@Windows MINGW64 /c/wamp64/www/magento
$ php bin/magento setup:install
--base-url=http://store.magento.com:8080/ 
--db-host=localhost
--db-name=magento
--db-user=root
--db-password=password123
--admin-firstname=magento
--admin-lastname=user
--admin-email=myuser@gmail.com
--admin-user=admin
--admin-password=password123
--language=en_US
--currency=USD
--timezone=America/Chicago
--use-rewrites=1

And, this is the response I get:

SQLSTATE[HY000] [1045] Access denied for user 'root'@'localhost' (using password: NO)

In InstallCommand.php line 274:

Parameter validation failed

Could this be affected because my bash creds are showing as: Administrator@Windows or what should I be a checking to see that root has access? Thank you so much for the help!

1 Answer 1

0

I was finally able to install Magento 2.4.0 on Windows Server using WAMP. My user was setup correctly as administrator. It was an insignificant mistake, when using the terminal and writing the query to install, I had two spaces between the command arguments. So just make sure all your cmd arguments have just one space in between like this:

$ php bin/magento setup:install --base-url=http://store.magento.com:8080/ --db-host=localhost --db-name=magento --db-user=root --db-password=password123 --admin-firstname=magento --admin-lastname=user --admin-email=myuser@gmail.com --admin-user=admin --admin-password=password123 --language=en_US --currency=USD --timezone=America/Chicago --use-rewrites=1

And this, finally worked. I hope it helps if you run into this problem with a windows machine... and for that fact with Linux systems too. The whole thing is to properly form your command arguments. Thanks!

Your Answer

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

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