Mysql查看版本号的几种方式

作者:whsnow 时间:2024-01-15 17:14:21 

有时候我们需要查看mysql的版本信息,那么就可以参考下面的方法

1、使用命令行模式进入mysql会看到最开始的提示符

在命令行登录mysql,即可看到mysql的版本号


[root@heyong ~]# mysql -uroot -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 487032
Server version: 5.7.17 MySQL Community Server (GPL)

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.

mysql>

Mysql查看版本号的几种方式

或者 mysql-v

Mysql查看版本号的几种方式

2、利用navicat连接mysql的客户端工具可以查看

连接之后右键——详细信息

Mysql查看版本号的几种方式

3、命令行中使用status可以看到


mysql> status
--------------
mysql Ver 14.14 Distrib 5.7.17, for linux-glibc2.5 (x86_64) using EditLine wrapper

Connection id:  488398
Current database:
Current user:  root@localhost
SSL:   Not in use
Current pager:  stdout
Using outfile:  ''
Using delimiter: ;
Server version:  5.7.17 MySQL Community Server (GPL)
Protocol version: 10
Connection:  Localhost via UNIX socket
Server characterset: utf8
Db  characterset: utf8
Client characterset: utf8
Conn. characterset: utf8
UNIX socket:  /tmp/mysql.sock
Uptime:   5 days 10 hours 5 min 40 sec

Threads: 154 Questions: 15051829 Slow queries: 0 Opens: 37599 Flush tables: 11 Open tables: 1563 Queries per second avg: 32.138
--------------

mysql>

Mysql查看版本号的几种方式

4、利用mysql命令查看

mysql> select version();
+-----------+
| version() |
+-----------+
| 5.7.17 |
+-----------+
1 row in set (0.01 sec)

mysql>

Mysql查看版本号的几种方式

5、使用mysql --help | grep Distrib查看

[root@heyong tools]# mysql --help | grep Distrib

mysql Ver 14.14 Distrib 5.7.17, for linux-glibc2.5 (x86_64) using EditLine wrapper

Mysql查看版本号的几种方式

6、包管理工具(根据不同系统 rh系列或则是bsd系列)

$ rpm -qa|grep mysql
qt-mysql-4.6.2-20.el6.x86_64
mysql-server-5.1.69-1.el6_4.x86_64
mysql-libs-5.1.69-1.el6_4.x86_64
mysql-5.1.69-1.el6_4.x86_64
mysql-devel-5.1.69-1.el6_4.x86_64

标签:Mysql,版本号
0
投稿

猜你喜欢

  • 用Python实现一个简单的线程池

    2023-09-21 15:14:56
  • Tensorflow的梯度异步更新示例

    2022-10-04 15:08:23
  • PHP基于phpqrcode类生成二维码的方法详解

    2023-06-12 17:20:38
  • Go开发Gin项目添加jwt功能实例详解

    2024-04-26 17:31:00
  • Python列表1~n输出步长为3的分组实例

    2021-10-31 04:25:27
  • 利用OpenCV进行对象跟踪的示例代码

    2023-05-28 14:14:54
  • pycharm中选中一个单词替换所有重复单词的实现方法

    2022-11-07 02:51:16
  • Python中time与datetime模块使用方法详解

    2022-11-06 11:03:59
  • JS实现拖动模糊框特效

    2023-08-06 05:18:51
  • python获取天气接口给指定微信好友发天气预报

    2023-08-11 18:13:06
  • python标准库random模块处理随机数

    2023-11-23 16:22:49
  • PHP组合模式Composite Pattern优点与实现过程

    2023-05-29 02:10:44
  • Python学习之列表常用方法总结

    2021-11-24 18:43:19
  • numpy数组合并和矩阵拼接的实现

    2022-09-05 19:39:54
  • YUI学习笔记(1)

    2009-01-12 18:06:00
  • 段正淳的css笔记(1)分类之间的横竖线

    2007-11-01 21:47:00
  • Python socket实现的简单通信功能示例

    2023-03-03 07:49:40
  • Python数据分析之双色球统计单个红和蓝球哪个比例高的方法

    2022-08-13 07:55:01
  • 从一个项目中来看三层架构

    2008-08-06 12:50:00
  • 关于大型页游后端管理系统的一点经验和个人见解

    2023-05-02 06:21:16
  • asp之家 网络编程 m.aspxhome.com