본문 바로가기
Mysql

my.cnf 수정 후 에러시

by ohrohi 2019. 10. 22.

에러 1.

[ERROR] You have enabled the binary log, but you haven't provided the mandatory serverid. Please refer to the proper server start-up parameters documentation

 

원인: my.cnf 안에 server-id 주석후 해당 에러 발생 

해결: server-id 설정 후 정상작동 완료

 

에러 2.

[ERROR] InnoDB: The innodb_system data file '/usr/local/mysql/data/ibdata1' is of a different size 768 pages (rounded down to MB) than the 131072 pages specified in the .cnf file!

 

- 원인: : InnoDB 실제 페이지값 (768 pages)과 my.cnf 설정의 innodb_data_file_path=ibdata1:2048M;:autoextend  

(색칠한부분)의 설정값이 틀려서 발생 

- 해결: InnoDB의 실제 페이지값과 동일하게 수정후 정상실행 (실제 InnoDB 페이지값은 에러로그에 표시된다)

-> innodb_data_file_path=ibdata1:12M;:autoextend

 

* 참고 *

1 page = memory 16Kbytes

-> 768  X 16 = 12,288Kbytes

-> 12,288 Kbyte = 12Mb

 

 

에러 3.

[ERROR] InnoDB: Plugin initialization aborted with error Generic error

 

- /data 폴더 안에 있는 ibdata1, ib_logfile0, ib_logfile1 세개파일을 이름변경 혹은 삭제하면 시작된다