between 0 and 1

add new user and set remote access 본문

Software Development Engineering/MySQL

add new user and set remote access

devxpert.yoon 2021. 2. 10. 01:26
728x90
반응형

for internal access (localhost)

CREATE USER 'newuser'@'localhost' IDENTIFIED BY 'password';
GRANT ALL PRIVILEGES ON * . * TO 'newuser'@'localhost';
FLUSH PRIVILEGES;

 

 

for remote access 

CREATE USER 'newuser'@'%' IDENTIFIED BY 'password';
GRANT ALL PRIVILEGES ON * . * TO 'newuser'@'%';
FLUSH PRIVILEGES;

 

728x90
반응형