0

I am running MySQL optimisation wizard, mysqltuner, which gives the suggestion:

User 'root@%' does not specify hostname restrictions.

How is this achieved? I can't readily find an answer.

1 Answer 1

2

root, assuming it is the SUPER user, should be very restricted.

'root'@'my.domain.com'

'root'@'11.22.33.44'

In other situations, you might want

'joe'@'192.168.%'

'sal'@'%.our-domain.com'
2
  • How do you limit to just 127.0.0.1? Commented Dec 6, 2018 at 22:35
  • 'joe'@'127.0.0.1' or (perhaps) 'joe'@'localhost' -- Note that "localhost" is not included in "%".
    – Rick James
    Commented Dec 6, 2018 at 22:54

Your Answer

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

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