728x90
1. SSL connection 오류
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 if explicit option isn't set. For compliance with existing applications not using SSL the verifyServerCertificate property is set to 'false'. You need either to explicitly disable SSL by setting useSSL=false, or set useSSL=true and provide truststore for server certificate verification.
11월 05, 2023 6:14:27 오후 org.apache.tomcat.jdbc.pool.ConnectionPool init
심각: Unable to create initial connections of pool.
com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure
에러 내용에 나와있는 대로 mysql URL 에 useSSL=false를 추가해주면 해결 된다.
"jdbc:mysql://localhost/spring5fs?characterEncoding=utf8&useSSL=false"
2. 인증 플러그인
unable to load authentication plugin 'caching_sha2_password'.
MySQL 8.0 이상 버전에서 발생하는 오류로 8.0 버전의 기본 인증 플러그인의 변경으로 인한 문제이다.
caching_sha2_password 를 사용하기 위해서는 SSL 보안 연결을 사용하거나, RSA 보안을 적용한 비암호 연결을 사용해야 하는데 이를 사용하지 않으면 해당 에러가 발생한다. (SSL connection 에러 해결을 위해 useSSL=false 를 적용하면 맞닥뜨릴 수 밖에 없다...)
이를 해결하는 가장 간단한 방법은 계정 비밀번호 암호화를 mysql_native_password 로 변경하는 것이다.
ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY '사용하는 패스워드'
'데이터베이스' 카테고리의 다른 글
DB 커넥션 풀 (Connection Pool) (1) | 2023.11.04 |
---|---|
[PostgreSQL] dual 과 같은 기능 사용하기 (0) | 2022.07.25 |
[Oracle] 오라클로 LIMIT 구현 하기 (0) | 2022.03.16 |
[프로그래머스] NULL 처리하기 (0) | 2021.11.28 |
[프로그래머스] 입양 시각 구하기(2) (0) | 2021.11.28 |