mysql version  8.4 LTS

  • 8.4 변동사항 많아서 보류
  • 8.0.4 로 uprade
https://dev.mysql.com/blog-archive/introducing-mysql-innovation-and-long-term-support-lts-versions/

 

한대의 인스턴스 Minor Upgrade 순서

- MySQL 셧다운 → 엔진파일 덮어쓰기(변경) → MySQL 서버(mysqld) 시작 → MySQL upgrade 실행
- 업그레이드 시 mysqld vs mysql_upgrade
실제 업그레이드는 두가지 단계로 나뉘어서 처리 ( 1단계: mysqld, 2단계 : mysql_upgrade)

 

순서

 

  • mysql 8,0.4 download & 압축해제ll
wget https://dev.mysql.com/get/Downloads/MySQL-8.0/mysql-8.0.40-linux-glibc2.28-x86_64.tar.xz
sudo su
tar -xvf mysql-8.0.40-linux-glibc2.28-x86_64.tar.xz -C /usr/local​
  • 심볼릭 링크  해재 후 재설정
cd /usr/local
unlink mysql
ln -s mysql-8.0.40-linux-glibc2.28-x86_64 mysql​

 

  • mysql 중지
/usr/local/mysql/bin/mysqladmin -u root -p shutdown
  • upgrade 수행
/usr/local/mysql/bin/mysqld_safe --defaults-file=/etc/my.cnf &


업그레이드 프로그램 
8.0.16 미만 : mysql_upgrade
8.0.16 이상 : mysqld

로그 확인
2024-12-10T10:50:44.469133-00:00 4 [System] [MY-013381] [Server] Server upgrade from '80023' to '80200' started.
2024-12-10T10:50:51.334428-00:00 4 [System] [MY-013381] [Server] Server upgrade from '80023' to '80200' completed.
  • my.cnf 변경
expire_logs_days=7
-> binlog_expire_logs_seconds=604800
  • mysqlcheck
 /usr/local/mysql/bin/mysqlcheck -u root -p --all-databases --check-upgrade​
  • version 확인
SELECT @@version

'MySQL (Aurora) > Troubleshooting' 카테고리의 다른 글

메모리 Resize 장애 (MHA)  (3) 2024.09.25
Mysql 5.7 Online DDL varchar column size변경  (1) 2024.09.03

+ Recent posts