Grant Permission On Database In MySQL Server On CentOS 7

You can also check privileges in MySQL and grant permission or access to the database for the user using the show grants commands. you should be very careful when you run these commands on the server. We can also use SQLYog to perform this task graphically using the software where you don’t need to remember the syntax.

Grant Permission On Database In Server:

you can see permission on particular database before giving it to the user. if you want
to give all the privileges to the user, it means they can do anything they want on the

you can not log in to the MySQL server and access the database. So we will have to
give grant permission on the database for a user. 

By default, MySQL does not assign any access to the database. you need to secure 
and remove the test database from the MySQL server.

Check Out: Different Ways of Finding Table Size In Mysql Server

Step 1: Create a User 

CREATE USER ‘abc’@’’ IDENTIFIED BY ‘password’;

Grant Permission On Database

Step 2: Create a DATABASE


database permissions mysql

Step 3: Grant all Permission On Databases

grant database access

Check Out: Check MySQL Slow Queries In Mysql Database Server

Step 4: Flush Privileges;

database permissions for user

You’re done permissions grant  access for user mysql show privileges database

Share on:

I'm the founder of Curious Viral. I hope this blog will provide you complete information about Linux Technology & I would like to share my technical knowledge with you which I have learned during this period.

Other Posts You May Like...

Leave a comment