PyCharm中连接MySQL服务报错【08001】

问题

[08001] Could not create connection to database server. Attempted reconnect 3 times. Giving up.

解决方案

时区问题,URL后面添加?serverTimezone=UTC

jdbc:mysql://10.36.172.81:3307/stu_db2?serverTimezone=UTC

猜你喜欢

转载自blog.csdn.net/mall_lucy/article/details/107424327