MySql.Data.MySqlClient.MySqlException:“主机本地主机不支持SSL连接." [英] MySql.Data.MySqlClient.MySqlException: “The host localhost does not support SSL connections.”

查看:502
本文介绍了MySql.Data.MySqlClient.MySqlException:“主机本地主机不支持SSL连接."的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用MySql.Data 8.08和.NET Core连接到MySql 5.7.18 但是会引发以下异常:

I use MySql.Data 8.08 and .NET Core to connect to MySql 5.7.18 but following exception is being thrown:

MySql.Data.MySqlClient.MySqlException:The host localhost does not support SSL connections.

如何处理?

推荐答案

我今天从MySql.Data 7.0.7迁移到8.0.8时遇到了同样的问题.我能够继续在连接字符串中添加"SslMode = none".

I had the same problem today when moving from MySql.Data 7.0.7 to 8.0.8. I was able to move forward adding the "SslMode=none" in the connection string.

您最终会遇到类似的事情:

You will endup with something like:

server={0};user id={1};password={2};persistsecurityinfo=True;port={3};database={4};SslMode=none

(用数据库详细信息替换值)

(replacing the values with your database details)

这篇关于MySql.Data.MySqlClient.MySqlException:“主机本地主机不支持SSL连接."的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆