MySql management tool phpMyadmin create a database and set user permissions graphic tutorial phpmyadmin
BitsCN.com
PhpMyAdmin is a good web system for mysql management. it is convenient to use phpMyAdmin to create databases, create users, set user permissions, back up data, and restore data.
In terms of database management, security is very important, with minimum permissions and maximum security. The following describes how to use phpMyAdmin to set the access permissions for different databases.
Step 1: log on to phpMyAdmin as an administrator account. generally, log on to phpMyAdmin as root.
Part 2: create a database for which permissions are to be set (this is not required if it already exists)
Fill in the database name and database code. I chose the "Chinese-Chinese simplified" encoding and click Create. The data will be ready.
Step 3: Create a management User
After creating the database, click the new database "sweiku.com" and click "permissions". a new page is displayed, and then click "add new user", as shown in figure
In this step, note that you do not need to select global permissions and then click execute directly.
Step 4: Set user permissions
Select the corresponding permissions and click execute
The meaning of the above permissions can be translated as follows:
Data:
SELECT: allows reading data.
INSERT: data can be inserted or replaced.
UPDATA: Allows you to change data.
DELETE: Allows you to DELETE data.
FILE: Allows you to import data from a FILE and export data to a FILE.
Structure:
CREATE: allows the creation of new databases and tables.
ALTER: allows you to modify the structure of an existing table.
INDEX: Allows you to create and delete indexes.
DROP: allows you to delete databases and tables.
Create temporary tables: allows the creation of temporary tables.
Create view: allows the creation of new comments.
Show view: displays the created VIEW.
Create routine: allows the creation of stored procedures.
Alter routine: Allows changing and dropping stored procedures.
EXECUTE: Allows execution of stored procedures.
Management:
GRANT: users and permissions can be added, but the permission table cannot be reloaded.
SUPER: connection is allowed when the maximum allowed number is reached.
PROCESS: allows you to view complete queries in the PROCESS list.
RELOAD: allows you to RELOAD server settings and refresh the server cache.
SHUTDOWN: Allows Server SHUTDOWN.
Show databases: allows access to the complete database list.
Lock tables: the table that allows the current clue to be locked.
REFERENCES: invalid in MySQL of this version.
Replication client: the user has the right to ask where the submitter/controller is.
Replication slave: required to reply to the submitter.
Create user: Allows you to CREATE, drop, and rename USER accounts.
Now, the database creation and permission settings are complete. Finally, we can log on to phpMyAdmin with a new user.
We can see that the user can turn off the database with the corresponding permissions, while other databases are not visible.
BitsCN.com