Mathiau
asked on
MySQL 5.0.45 - root access on any external, no pass ?
Hello everyone
I have read every thread i could find and tried every command i can, i am sure i am doing something wrong or lack of sleep has fried my brain.
brand new 5.0.45 MySQl install, i need to allow access on root from all hosts with no password
i cant get it to work, i can only connect from local host on root...
i tried adding *.* as a host using mysql admin but it seems to do nothing and doesnt allow me to connect from another system
i have tried grant commands, giving grant to root,flush privileges afterwards, but nothing is working for me, this is a test bed system, not accessible from the Inet, i am redoing someone else's work who has no security so for now i need just root access with no password from *.* anywhere.....
Please save what little sannity i have left, i know the question has been asked, but i have tried literally ever response people have given to everyone else :(
I have read every thread i could find and tried every command i can, i am sure i am doing something wrong or lack of sleep has fried my brain.
brand new 5.0.45 MySQl install, i need to allow access on root from all hosts with no password
i cant get it to work, i can only connect from local host on root...
i tried adding *.* as a host using mysql admin but it seems to do nothing and doesnt allow me to connect from another system
i have tried grant commands, giving grant to root,flush privileges afterwards, but nothing is working for me, this is a test bed system, not accessible from the Inet, i am redoing someone else's work who has no security so for now i need just root access with no password from *.* anywhere.....
Please save what little sannity i have left, i know the question has been asked, but i have tried literally ever response people have given to everyone else :(
First of all, like Angellll says: root with NO password is ...I even do not have an idea how to call such approach!
But if you still want to grant access to all hosts, put "%" instead of "localhost" in Host row of mysql table, and reload privileges.
But if you still want to grant access to all hosts, put "%" instead of "localhost" in Host row of mysql table, and reload privileges.
ASKER
I know it is, why this system isnt accessible to the internet right now, i am well aware of the security issued involved.
the original coder claimed passwords didnt work with his scripts, i have tested some, and some work and some dont, this person also uses global variables (using php with mysql).
So i am just trying to move what i need to a new server, once done, i plan to go back over the coding and fix it so it works with user and passwords, these items wont be seeing the light of day, or the internet, until they are password protected.
the original coder claimed passwords didnt work with his scripts, i have tested some, and some work and some dont, this person also uses global variables (using php with mysql).
So i am just trying to move what i need to a new server, once done, i plan to go back over the coding and fix it so it works with user and passwords, these items wont be seeing the light of day, or the internet, until they are password protected.
...also, assure firewall is not blocking traffic on port 3306, which is used by MySQL server.
>the original coder claimed passwords didnt work with his scripts, i
actually, with PHP, having no password will not work, you will have to use a password anyhow.
actually, with PHP, having no password will not work, you will have to use a password anyhow.
ASKER
not sure, cause non of his php scripts have password to connect to the mysql DB's and his pages work, not a single one! scary how he got by for 4 years doing this, using root with no passwords to connect tot he DB's, not even IP access was used.
example
$use=$PHP_AUTH_USER;
$dblink=mysql_connect("*** *******", "root", "");
$db_list = mysql_list_dbs($dblink);
while ($database=mysql_fetch_obj ect($db_li st))
all his scripts are like that.
example
$use=$PHP_AUTH_USER;
$dblink=mysql_connect("***
$db_list = mysql_list_dbs($dblink);
while ($database=mysql_fetch_obj
all his scripts are like that.
ASKER
Just tried this
grant all privileges on *.* to 'root'@'%';
but now i get the
"Can't find any matching row in the user table"
grant all privileges on *.* to 'root'@'%';
but now i get the
"Can't find any matching row in the user table"
ASKER
angelIII, could i tbe because of using version of PHP 4 and lower? i know after 4.1? global variables was off by default and other security items changed to make it more out of the gate secure.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
i am still getting the error
Can't find any matching row in the user table
running the GRANT ALL ON *.* TO 'root'@'%';
i am conencting using mySQL Query Browser and then connecting to the mysql folder locally on the machine which the BD is hosted on... am i doing something incorrectly? or is their some restriction on mysql 5.0.45 that wont allow me to grant this access to root?
Can't find any matching row in the user table
running the GRANT ALL ON *.* TO 'root'@'%';
i am conencting using mySQL Query Browser and then connecting to the mysql folder locally on the machine which the BD is hosted on... am i doing something incorrectly? or is their some restriction on mysql 5.0.45 that wont allow me to grant this access to root?
>angelIII, could i tbe because of using version of PHP 4 and lower?
yes, that is highly probable!
now, please run this:
mysql> use mysql
mysql> select user, hostname, password from user
and report that it returns (clearing the passwords anyhow).
yes, that is highly probable!
now, please run this:
mysql> use mysql
mysql> select user, hostname, password from user
and report that it returns (clearing the passwords anyhow).
ASKER
just did a completly reinstall of MySQL, no passwords on root, standard install (still get same error with grant)
results from select * from users ( added the ...)
Host...................... .......... .User .......................... Password
localhost................. .........r oot
production................ .......roo t
127.0.0.1................. ........ro ot
results from select * from users ( added the ...)
Host......................
localhost.................
production................
127.0.0.1.................
ASKER
there are no passwords set also, why they are blank.
ASKER
is it posible i may need to put a password on root before i can allow external access, and if so, can i remove the password after it was been added?
ASKER
didnt work with a password on the root account either, now i am completly lost on this one :( Did MySQL completly block in the program root access on *.* in some new version
ASKER
Did i get everyone stumped on ths as well :)
ASKER
Well, it seems to make this work, this method worked
Put a password on the root account / Apply
Add Hosts from which the user can connect (*.*)
remove password from root account / apply
done, can now access externally from any host, i did this using MySQL Admin.
Put a password on the root account / Apply
Add Hosts from which the user can connect (*.*)
remove password from root account / apply
done, can now access externally from any host, i did this using MySQL Admin.
ASKER
The solution was correct, but did not seem to apply perfectly to this situation, perhaps this is a new limitation in MySQL 5.0.45 + that you can not give such access with out root having at least a password to start, which is good news of course.
I am glad you solved it. MySQL admin tool can be used for such things, too.
ASKER
this is weird, set up another system and tried the above but it is not working..lol so maybe it was a combo of what i did and some queries, time to test!
DON'T do that... it will save you from more severe illness later!!!
why ROOT?
why no password?