Create Database And User In Linux

0


1) Open SSH ( For Example : PuTTY )
2) Write This Commands :
sudo mysql -u root -p

*Change (Your DB Name)

CREATE DATABASE Your DB Name;

*Change  ( USERNAME ) , ( PASSWORD )

CREATE USER 'USERNAME'@'localhost' IDENTIFIED BY 'PASSWORD';

*Change ( Your DB Name ) , ( USERNAME ) , ( PASSWORD )

GRANT ALL ON Your DB Name.* TO 'USERNAME'@'localhost' IDENTIFIED BY 'PASSWORD' WITH GRANT OPTION;

FLUSH PRIVILEGES;

EXIT;