MySQL关闭SSL

博主介绍:

计算机科班人,全栈工程师,掌握C、C#、Java、Python、Android等主流编程语言,同时也熟练掌握mysql、oracle、sqlserver等主流数据库,能够为大家提供全方位的技术支持和交流。

具有丰富的项目经验和开发技能。提供相关的学习资料、程序开发、技术解答、代码讲解、文档报告等专业服务。

目录

系统环境:

shell 复制代码
[dalaochao@xxzx-dalaochao-19 ~]$ cat /etc/os-release
NAME="Kylin Linux Advanced Server"
VERSION="V10 (Tercel)"
ID="kylin"
VERSION_ID="V10"
PRETTY_NAME="Kylin Linux Advanced Server V10 (Tercel)"
ANSI_COLOR="0;31"

MySQL版本:5.7.44

1、查看SSL的开启状态
sql 复制代码
SHOW VARIABLES LIKE '%ssl%';

have_openssl表示是否支持SSL。have_ssl的值为YES,表示已开启SSL。

2、修改配置文件/etc/my.cnf,添加 skip_ssl
shell 复制代码
[mysqld]
#
# Remove leading # and set to the amount of RAM for the most important data
# cache in MySQL. Start at 70% of total RAM for dedicated server, else 10%.
# innodb_buffer_pool_size = 128M
#
# Remove leading # to turn on a very important data integrity option: logging
# changes to the binary log between backups.
# log_bin
#
# Remove leading # to set options mainly useful for reporting servers.
# The server defaults are faster for transactions and fast SELECTs.
# Adjust sizes as needed, experiment to find the optimal values.
# join_buffer_size = 128M
# sort_buffer_size = 2M
# read_rnd_buffer_size = 2M
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
port=8888

# Disabling symbolic-links is recommended to prevent assorted security risks
symbolic-links=0

log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid
skip_ssl
3、重启mysqld服务
shell 复制代码
systemctl mysqld restart
4、再次查看SSL,have_ssl的值为DISABLED,即为关闭状态

大家点赞、收藏、关注、评论啦!


更多技术干货,请持续关注程序员大佬超。

原创不易,转载请务必注明出处。

相关推荐
普马萨特23 分钟前
实体与位置关系的数据从哪里来:获取、治理与仍待解决的问题
网络·数据库
醉颜凉40 分钟前
KingbaseES日期格式化:MySQL date_format函数的迁移指南
mysql·date_format·kingbasees·数据库兼容·函数迁移
醉颜凉42 分钟前
MySQL 8 忘记 root 密码?这两种方法帮你轻松解决
数据库·mysql·adb
刃神太酷啦1 小时前
Linux 系统 MySQL 完整安装配置教程:从卸载 MariaDB 到优化 my.cnf----《Hello MySQL!》(1)
android·linux·c语言·c++·mysql·leetcode·mariadb
RestCloud1 小时前
集成链路监控体系搭建:接口调用、数据流转与异常告警全覆盖
数据库·数据安全·ipaas·api管理·数据监控·集成平台·api 治理
xxwl5852 小时前
MySQL 基础学习笔记
数据库·mysql
SKH.2 小时前
Linux软件编程(6)线程间通信
java·开发语言·数据库
Rain的Java大神之路2 小时前
PC版网站被狂刷怎么处理
java·数据库·redis·后端·mysql·web安全·运维开发
闻哥2 小时前
小表驱动大表——SQL查询优化的核心原则(深度剖析+流程图)
数据库·sql·流程图
cmes_love2 小时前
港股Level2历史数据:逐笔成交与分钟线
数据库·oracle