命令行操作

  1) 查询字符集

show variables like 'character%';

MySQL之常用查询

   

  2)查看版本

select version();

MySQL之常用查询

 

 

  3) 共享表空间的数据文件存储路径

show variables like 'innodb_data%';

MySQL之常用查询

 

 

  4) 查看是哪种类型的表空间

show variables like '%innodb_file_per_table%';

MySQL之常用查询

 

  5) MySql数据库物理文件存放位置

show VARIABLES like '%datadir%';

MySQL之常用查询

 

  6) 查看某个配置项sql_model

select @@sql_mode;

MySQL之常用查询

 

  7)获取到mysql的安装路径

select @@basedir; 

 

 

终端操作:

  1)查询mysql的配置文件加载路径(同时可以验证配置文件是否有错误)

mysql --help|grep 'Default options' -A 1

/etc/mysql/my.cnf /etc/my.cnf ~/.my.cnf

 

相关文章:

  • 2021-12-18
  • 2022-12-23
  • 2021-07-23
  • 2022-12-23
  • 2022-02-26
  • 2021-09-22
  • 2021-04-05
猜你喜欢
  • 2021-09-20
  • 2021-12-28
  • 2021-07-01
  • 2021-12-04
  • 2022-12-23
相关资源
相似解决方案