I often see in many MySQL tutorials that people use command IDENTIFIED BY \'password\' both during user creation and granting him privileges.
For examp
Code below gives full access to all databases. Other commands mentioned in answers are work if you have the specific databases in the mysql server. Code below is works regardless of the state in which the server is in. Just login to the linux server -> type mysql and enter:
GRANT ALL privileges ON *.* TO 'user'@'host' identified BY 'password';