mysql5.7基础 查看mysql的所有用户

镇场文:
       学儒家经世致用,行佛家普度众生,修道家全生保真,悟易理象数通变。以科技光耀善法,成就一良心博客。
______________________________________________________________________________________________________
Operating System:UbuntuKylin 16.04 LTS 64bit
mysql: Ver 14.14 Distrib 5.7.17, for Linux (x86_64) using  EditLine wrapper

step1:

登陆

[email protected]:~$ mysql -u root -p
Enter password: 
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 5
Server version: 5.7.17-0ubuntu0.16.04.1 (Ubuntu)

Copyright (c) 2000, 2016, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type ‘help;‘ or ‘\h‘ for help. Type ‘\c‘ to clear the current input statement.

step2:

进入mysql数据库 并 查询所有用户

mysql> use mysql;
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A

Database changed
mysql> select host,user from user;
+-----------+------------------+
| host      | user             |
+-----------+------------------+
| localhost | TestUser         |
| localhost | debian-sys-maint |
| localhost | myTestUser       |
| localhost | mysql.sys        |
| localhost | phpmyadmin       |
| localhost | root             |
+-----------+------------------+
6 rows in set (0.00 sec)

step3:

退出

mysql> exit
Bye
[email protected]:~$

______________________________________________________________________________________________________
若是您觉得此博文有可以改进的地方或者内容过时了,请评论,我会仔细思考的。
注:此博文仅用于科研学习,如果侵犯到您的权益,请及时告知,我会做出相应的处理。

时间: 2024-08-20 00:32:43

mysql5.7基础 查看mysql的所有用户的相关文章

mysql5.7基础 查看mysql的服务状态

镇场文:       学儒家经世致用,行佛家普度众生,修道家全生保真,悟易理象数通变.以科技光耀善法,成就一良心博客.______________________________________________________________________________________________________ Operating System:UbuntuKylin 16.04 LTS 64bitmysql: Ver 14.14 Distrib 5.7.17, for Linux (

mysql5.7基础 查看mysql数据库的默认编码

镇场文:       学儒家经世致用,行佛家普度众生,修道家全生保真,悟易理象数通变.以科技光耀善法,成就一良心博客.______________________________________________________________________________________________________Operating System:UbuntuKylin 16.04 LTS 64bitmysql: Ver 14.14 Distrib 5.7.17, for Linux (x

mysql5.7基础 关闭mysql服务

镇场文:       学儒家经世致用,行佛家普度众生,修道家全生保真,悟易理象数通变.以科技光耀善法,成就一良心博客.______________________________________________________________________________________________________ Operating System:UbuntuKylin 16.04 LTS 64bitmysql: Ver 14.14 Distrib 5.7.17, for Linux (

linux 查看mysql 、nginx用户和组

查看是否存在MySQL组: [[email protected] home]# grep mysql /etc/group 不存在创建MySQL组: [[email protected] home]# groupadd mysql 查看是否存在MySQL用户: [[email protected] home]# grep mysql /etc/passwd 不存在创建MySQL用户: [[email protected] ~]# useradd mysql -g mysql -M -s /sbi

mysql5.7基础 查看一个表的结构 与 详细信息 使用的什么引擎

镇场文:       学儒家经世致用,行佛家普度众生,修道家全生保真,悟易理象数通变.以科技光耀善法,成就一良心博客.______________________________________________________________________________________________________ Operating System:UbuntuKylin 16.04 LTS 64bitmysql: Ver 14.14 Distrib 5.7.17, for Linux (

mysql5.7基础 查看一个数据库中的所有表

镇场文:       学儒家经世致用,行佛家普度众生,修道家全生保真,悟易理象数通变.以科技光耀善法,成就一良心博客.______________________________________________________________________________________________________ Operating System:UbuntuKylin 16.04 LTS 64bitmysql: Ver 14.14 Distrib 5.7.17, for Linux (

Ubuntu使用root用户+安装mysql5.07+基础配置

上一章讲到破解root权限,个人是不建议使用root用户的,毕竟权限越大责任越大.不过有些朋友还是有需要的,下面讲讲. 破解root权限: 1)sudo passwd root //设置root用户的密码 2)把/etc/ssh/sshd_config文件下的 PermitRootLogin without-password修改为permitRootLogin yes //这是允于root用户登录 3)重启系统 经过上面的步骤我们就可以用root用户登录了,重新登录后可以看到我们是root用户了

查看MYSQL数据库中所有用户及拥有权限

查看MYSQL数据库中所有用户 mysql> SELECT DISTINCT CONCAT('User: ''',user,'''@''',host,''';') AS query FROM mysql.user; 查看数据库中具体某个用户的权限mysql> show grants for 'cactiuser'@'%';

如何查看mysql的用户及授权

1)查看mysql中存在的用户 mysql> select user,host from mysql.user; +------------+--------------------------+ | user       | host                     | +------------+--------------------------+ | oldgirl    | %                        | | wan        | %