Koozali.org: home of the SME Server
Obsolete Releases => SME Server 7.x => Topic started by: dede77b on October 07, 2008, 05:18:55 PM
-
Hi guys, I spent 2 days on this forum looking for my problem, and trying many suggestion but I still have my problem
This is my error, seen many many time on this forum. Sorry for that but I can't solve my error alone.
#1045 - Access denied for user 'root'@'localhost' (using password: YES) (myphpadmin error)
I pretty sure that my default root password for mysql is right, I followed the suggestion to reset default password as describe here
http://wiki.contribs.org/MySQL#Resetting_the_MySQL_root_password (http://wiki.contribs.org/MySQL#Resetting_the_MySQL_root_password)
but still have problem.
All the contribs I installed can't access mysql. Joomla is in error, myphpadmin give me that error, cpg gallery too.
Could be that the default password of mysql is right, and the problem is the user and password I used for creating db for these application i mentioned before?
Please, give me suggestion for that.
Thanx Fred
-
Hi guys, I spent 2 days on this forum looking for my problem, and trying many suggestion but I still have my problem
This is my error, seen many many time on this forum. Sorry for that but I can't solve my error alone.
#1045 - Access denied for user 'root'@'localhost' (using password: YES) (myphpadmin error)
I pretty sure that my default root password for mysql is right, I followed the suggestion to reset default password as describe here
http://wiki.contribs.org/MySQL#Resetting_the_MySQL_root_password (http://wiki.contribs.org/MySQL#Resetting_the_MySQL_root_password)
but still have problem.
All the contribs I installed can't access mysql. Joomla is in error, myphpadmin give me that error, cpg gallery too.
Could be that the default password of mysql is right, and the problem is the user and password I used for creating db for these application i mentioned before?
Please, give me suggestion for that.
Thanx Fred
You should have looked at the FAQ. Never use the root password for your applications, it is a far to powerfull account for applications. The mysql root password is a random string of about 70 charachters which you do not need to know.
You can login on the SME Server shell as root, without a password, as there is a clever mechanism providing the password when you try to login. This does not work when you login from other locations or clients.
Create a user with the proper privileges for the task it should do like layed out here: http://wiki.contribs.org/SME_Server:Documentation:FAQ#MySQL_Database
-
I always used to set up application user name ROOT and password XYZ. (sure different from default)
The strange thing is that if my default password is right and didn't change, why phpmyadmin give me this error? Without it I can do anything.
Maybe I can from command line, but I'm not so good with mysql.
How can I be sure that default psw is the right one? ( I suppose that if I login as root and type mysql and it runs, the default is right, isn't it?)
If answer is YES, than with SELECT Host, User FROM mysql.user; I see 6 users, two of them are root. Can I change the password for all these 6 user with this command?
SET PASSWORD FOR ''@'localhost' = PASSWORD('newpwd');
or for the two root user is better to do nothing while they use the default password. ( I'm really confuse about the default password and the password a root user can have.....)
-
I always used to set up application user name ROOT and password XYZ. (sure different from default)
That is a bad thing, you should never setup the users like that. There is only one root user for localhost, you can not create multiple and if you change the password you will criple your SME Server. In general the MySQL root user is only used as an administrative account as it has way to much privileges and implies a havy security risk when used.
Badly written code could execute code on your MySQL database that only a root user is allowed to do, leaving other applications making use of another MySQL database on your system criple or dead-in-the-water while you are clueless what happened. Reset your MySQL root password and after that generate a proper account with a different username for your application. That will save you a lot of problems, puling of hair and scratching your bold scarf after that. ;-)
-
It seems to run now :-P
I change the two root user password in mysql, and change this password in the configuration file of my application and it looks great.
I will check all tomorrow morning.
Thanx a lot for your help.
Cheers Fred
-
It seems to run now :-P
I change the two root user password in mysql, and change this password in the configuration file of my application and it looks great.
I hope you not only changed passwords but that you are also not using the root user for your application anymore.
-
In fact I'm accessing my DB with the root user.
I check my databases, and all of these have ALL PRIVILEGES set for both root users.
I'm assigning these databases to a new user, but I have to mantain the same privileges? (all privileges) Or give less permission?
And last, do I have to remove root privileges to databases HORDE and MYSQL too?
Thank you again,
Fred
-
In fact I'm accessing my DB with the root user.
Well, you shouldn't do that.
I'm assigning these databases to a new user, but I have to mantain the same privileges? (all privileges) Or give less permission?
And last, do I have to remove root privileges to databases HORDE and MYSQL too?
You've already been told multiple times what you should do. Create a different user and use that for your application. Read the good documentation which has been provided. Sleep well at night.