MySQL Forums
Forum List  »  Security

mysql (Linux) privileges
Posted by: Tony Chamberlain
Date: May 15, 2009 02:50PM

We are using 5.0.19 mysql on CentOS 4.5. I have a couple questions:

1) Someone told us to use SKIP-NAME-RESOLVE in my.cnf. After using it, none of
the privileges seemed to work (or only a limited number). I guess you can't
use host names beginning with digits or it would confuse them with IP addresses.
The mysql.user (user and host) are "root", "%", but that does not work with
SKIP-NAME-RESOLVE. Anyway to do IP and host wildcard?

2) when recreating a database from a mysql dump on another machine, suddenlt,
tomcat got mysql errors (This is WITHOUT the SKIP-NAME-RESOLVE). The error
in the logfile was something like access denied to
"root@localhost.localdomain".
There were at least two entries in mysql.user for root

"root", "%" and
"root", "localhost"
both had all privileges

i.e. grant all privileges on *.* to 'root'@'%'

(Relax, it is on an internal private network), but I still got that access
error. Adding

grant all privileges on *.* to 'root'@'localhost.localdomain'

fixed the problem, but if I use "%" I shouldn't have to specify any other
addresses, should I? Do multiple entries override each other? Or what is
the problem?

Options: ReplyQuote


Subject
Views
Written By
Posted
mysql (Linux) privileges
5935
May 15, 2009 02:50PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.