Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

How do I change whether password is required for MySQL database? 
 
Brig
Jr. Member
 
Total Posts:  9
Joined:  2008-08-14
 

Magento installed & worked correctly when I created a blank, new MySQL database and made a password required --- and then inserted the sample data. But then the other apps on my site couldn’t establish their connections to their databases.

So I went into myPHPAdmin and removed the required password --- but now I get this message when I try to access mysite.com/magento ---- where I installed Magento: SQLSTATE[28000] [1045] Access denied for user ‘root’@’localhost’ (using password: YES)

I’d like to re-start the installation wizard and tell it that a password is not required, but I can’t get back to the installation wizard. How do I do that? Or, is there just a place in one of the files where I can edit that setting & be okay?

thanks!
Brig

 
Magento Community Magento Community
Magento Community
Magento Community
 
J_T_
Mentor
 
Avatar
Total Posts:  1961
Joined:  2008-08-07
London-ish, UK
 

Sounds like you added a password to an existing user, a user also required for the other scripts. No password is VERY BAD, most likely anyone can rmeotely write and read your database server.

What you need to do is make a new database user, with a new password and reinstall Magento, or work out how to update the current installation’s config settings (not sure myself on the latter, where exactly).

 
Magento Community Magento Community
Magento Community
Magento Community
 
Brig
Jr. Member
 
Total Posts:  9
Joined:  2008-08-14
 

Thanks very much for letting me know! I will look into it ----- but if anyone can tell me how to adjust the config settings for Magento without having to re-install, it would be much appreciated! Either username or pass for the mysql database…

 
Magento Community Magento Community
Magento Community
Magento Community
 
Brandlive_br
Guru
 
Avatar
Total Posts:  653
Joined:  2008-05-19
Buenos Aires, Argentina
 

Yes, you can look at /app/etc/local.xml
wink

 
Magento Community Magento Community
Magento Community
Magento Community
 
Brig
Jr. Member
 
Total Posts:  9
Joined:  2008-08-14
 

Thanks --- but I changed the username there, and when I run mysite.com/magento I still get the same error --- with the old username, like it’s looking for the old username. Are there any other places I need to change the username, or is that it?

 
Magento Community Magento Community
Magento Community
Magento Community
 
Brig
Jr. Member
 
Total Posts:  9
Joined:  2008-08-14
 

Yeah, I changed the username in app/etc/local.xml ---- to not be ‘root’ anymore, and yet I keep getting this error when it runs:

SQLSTATE[28000] [1045] Access denied for user ‘root’@’localhost’ (using password: YES)

I wonder why it’s still doing root@localhost instead of [newusername]@localhost?

 
Magento Community Magento Community
Magento Community
Magento Community
 
Brandlive_br
Guru
 
Avatar
Total Posts:  653
Joined:  2008-05-19
Buenos Aires, Argentina
 

Do you clean all the caché files sotred at /var/cache ?

 
Magento Community Magento Community
Magento Community
Magento Community
 
Brig
Jr. Member
 
Total Posts:  9
Joined:  2008-08-14
 

I didn’t --- there are a bunch of folder called: mage--0, mage--1, mage--2, etc, etc.

Do I just delete all those folders?

 
Magento Community Magento Community
Magento Community
Magento Community
 
Brandlive_br
Guru
 
Avatar
Total Posts:  653
Joined:  2008-05-19
Buenos Aires, Argentina
 

Yeap, the next time you load a page, all that folders it will be created again.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Brig
Jr. Member
 
Total Posts:  9
Joined:  2008-08-14
 

That worked—thanks!

Currently I have the magento installation in a directory called mysite.com/magento ----- it’s currently just the demo site with dummy skus. But I want to change the name of that directory to mysite.com/store. Do you know if there is a configuration parameter I need to change that will reflect that as well, so no links & connections in the Magento installation get messed up?

Many thanks for the help you gave me!
Brig

 
Magento Community Magento Community
Magento Community
Magento Community
 
Brandlive_br
Guru
 
Avatar
Total Posts:  653
Joined:  2008-05-19
Buenos Aires, Argentina
 

Mmmm… you need to change de base_url. (Check the core_config_data database table).
Also, when you change that, you need to clean again the cache folder. It’s not the best experience move magento from one folder to another, but it’s possible.
wink

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top