WARN: Establishing SSL connection without server's identity verification is not recommended
0.要想用Java连接mysql数据库,首先装好JDK,配置好环境变量,将jdk*.*.*\lib放入classpath,将jdk*.*.*\bin放入path中(*.*.*表示版本号);其次安装好mysql数据库,然后下载连接数据库要用的驱动包,并配置环境变量(配置方法,将驱动包的路径放入classpath中)。
1.Java使用mysql-jdbc连接MySQL出现如下警告:
Establishing SSL connection without server's identityverification is not recommended. According to MySQL 5.5.45+, 5.6.26+ and 5.7.6+requirements SSL connection must be established by default if explicit optionisn't set. For compliance with existing applications not using SSL theverifyServerCertificate property is set to 'false'. You need either toexplicitly disable SSL by setting useSSL=false, or set useSSL=true and providetruststore for server certificate verification.
原因是MySQL在高版本需要指明是否进行SSL连接。解决方案如下:
在mysql连接字符串url中加入ssl=true或者false即可,如下所示。
url=jdbc:mysql://127.0.0.1:3306/framework?characterEncoding=utf8&useSSL=true
2.对于错误:
要在url中加入serverTimezone=America/New_York,如下所示:
publicstatic final StringDBURL="jdbc:mysql://localhost:3306/d1?useSSL=true&useLegacyDatetimeCode=false&serverTimezone=America/New_York";
(解决网址:http://stackoverflow.com/questions/7605953/how-to-change-mysql-timezone-in-java-connection)
WARN: Establishing SSL connection without server's identity verification is not recommended的更多相关文章
- MySQL 警告WARN: Establishing SSL connection without server's identity verification is not recommended.解决办法
Fri Jun 17 13:46:54 CST 2016 WARN: Establishing SSL connection without server's identity verificatio ...
- WARN: Establishing SSL connection without server's identity verification is not recommended. According to MySQL 5.5.45+, 5.6.26+ and 5.7.6+ requirements SSL connection must be established by default i
jdbc连接数据库候,对数据进行访问,访问正常当出现如下警告: WARN: Establishing SSL connection without server's identity verifica ...
- C3P0 WARN: Establishing SSL connection without server's identity verification is not recommended
c3p0的出现,是为了大大提高应用程序和数据库之间访问效率的. 它的特性: 编码的简单易用 连接的复用 连接的管理 今天在配置C3p0的时候出现了这个warn 原因是因为要验证SSL Wed Se ...
- Wed Sep 19 20:48:46 CST 2018 WARN: Establishing SSL connection without server's identity verification is not recommended. According to MySQL 5.5.45+, 5.6.26+ and 5.7.6+ requirements SSL connection mus
Wed Sep 19 20:48:46 CST 2018 WARN: Establishing SSL connection without server's identity verificatio ...
- SpringBoot+mybatis:报错Fri Oct 19 14:29:24 CST 2018 WARN: Establishing SSL connection without server's identity verification is not recommended. According to MySQL 5.5.45+, 5.6.26+ and 5.7.6+ requiremen
报错:Fri Oct 19 14:29:24 CST 2018 WARN: Establishing SSL connection without server's identity verifica ...
- Java连接MySQL报出警告 WARN: Establishing SSL connection without server's identity verification is not recommended.
很多人使用JDBC连接MySQL时报出警告: WARN: Establishing SSL connection without server's identity verification is n ...
- 【警告】WARN: Establishing SSL connection without server's identity verification is not recommended.
1.Java访问Mysql时出现如下警告: 2019-04-02 10:30:50.545 INFO 1290 --- [nio-8080-exec-1] com.zaxxer.hikari.Hika ...
- Wed Jul 04 18:01:38 CST 2018 WARN: Establishing SSL connection without server's identity verification is not recommended
Wed Jul 04 18:01:38 CST 2018 WARN: Establishing SSL connection without server's identity verificatio ...
- 使用Mybatis连接到Mysql报错,WARN: Establishing SSL connection without server's identity verification is not recommended. According to MySQL 5.5.45+, 5.6.26+ and 5.7.6+ requirements SSL connection must be esta
在Eclipse中使用springboot整合Mybatis,连接到5.7版本Mysql报错WARN: Establishing SSL connection without server's ide ...
- MYSQL:WARN: Establishing SSL connection without server's identity verification is not recommended.
WARN: Establishing SSL connection without server's identity verification is not recommended. Accordi ...
随机推荐
- Android NDK开发三:java和C\C++交互
转自:http://www.cnblogs.com/shangdahao/archive/2013/05/02/3053971.html 1.定义native方法并加载动态链接库: public cl ...
- windows linux—unix 跨平台通信集成控制系统----系统硬件信息获取
控制集成系统需要了解系统的各项硬件信息,之前我们设计的时候,习惯使用c函数来搞,后来可能发现程序的移植性收到了一些影响,比如unix内核的一些c函数在linux下面是没有的: 比如 苹果达尔文内核的如 ...
- UnityEditor下文件操作方法汇总(Unity3D开发之二十四)
猴子原创,欢迎转载.转载请注明: 转载自Cocos2Der-CSDN,谢谢! 原文地址: http://blog.csdn.net/cocos2der/article/details/50595585 ...
- android Native堆
Android 应用开发大家都知道可以通过DDMS来查看应用程序进程占用的内存大小:然而Native 内存并不能在虚拟堆上看到:Android系统基于Linux,这样的话其具备Linux的大多数特性: ...
- linux下利用ruby做系统备份与还原
啥都不说了,都在代码里 :) #!/usr/bin/ruby BAK_PATH = "/media/backup.tar.xz" def to_backup exclude_fil ...
- 译文:ovs+dpdk中的“vHost User NUMA感知”特性
本文描述了"vHost User NUMA感知"的概念,该特性的测试表现,以及该特性为ovs+dpdk带来的性能提升.本文的目标受众是那些希望了解ovs+dpdk底层细节的人,如果 ...
- iOS使用第三方管理工具
1.安装cocoaPods 移除当前镜像,因为需要FQ跨域访问 001.gem source --remove https://rubygems.org/ 使用淘宝镜像安装 002.https://r ...
- jdk1.7 tomcat-7安装
由于软件下载地址经常有变动,所以不能直接wget,还是直接到网上点击下载 下载jdk http://www.oracle.com/technetwork/java/javase/downloads/j ...
- 浅入javascript正则表达式的规则.
今天在看jQuery源码的时候,到处都是正则的用法,一气之下就狠下心来.重新回顾了一下正则.下面是做的笔记.非常浅的入门. /* i:表示不区分大小写 g:表示可以全局配置 m:表示可以多行配置 */ ...
- parted分区详解 查看UUID两种方式 blkid 和 ls -l /dev/disk/by-uuid
通常我们用的比较多的一般都是fdisk工具来进行分区,但是现在由于磁盘越来越廉价,而且磁盘空间越来越大:而fdisk工具他对分区是有大小限制的,它只能划分小于2T的磁盘.但是现在的磁盘空间很多都已经是 ...