mysql 8.XX multiple versions ip access restrictions

Essays record, as customers require different ip access to the database, a lot of investigation, most of them or all ip ip segment can be accessed;

select user, host from user; you can view the user can access certain ip; but a user can only set a record;

ip and can not be used for dividing the comma;

As the table has

Description test test 192.168.0.12 192.169.0.12 users can access the database, but if you want to access with 192.168.0.14, try to use

grant all privileges on *. * To 'test'@'192.168.0.14'; you will be prompted to create a user can not use the grant; and we need to create the user

CREATE USER 'test'@'192.168.0.14' IDENTIFIED WITH mysql_native_password BY 'password';

And then execute the statement above, you can add a realized ip access different users;

Guess you like

Origin www.cnblogs.com/ljs0322/p/11249191.html
Recommended