2010-06-06 2 views
7

이 질문은 MySQL 바이너리 로그에 관한 것입니다.MySQL의 바이너리 로그를 다른 하드 디스크로 옮기기

바이너리 로그를 다른 하드 디스크로 옮겨야합니다.

MySQL에서 필요한 구성 변경 사항은 무엇입니까?

현재 바이너리 로그는 ibdata와 동일한 폴더에 저장되며 바이너리 로그가 필요한 복제 슬레이브가 실행됩니다.

답변

2

the doc을 읽는 방식에서 log-bin 구성에 경로를 지정할 수 있습니다.

To enable the binary log, start the server with the --log-bin[=base_name] option. If no base_name value is given, the default name is the value of the pid-file option (which by default is the name of host machine) followed by -bin. If the basename is given, the server writes the file in the data directory unless the basename is given with a leading absolute path name to specify a different directory. It is recommended that you specify a basename; see Section C.5.8, “Known Issues in MySQL”, for the reason.

7

로그 bin 변경. 그러나 log-bin 파일을 먼저 새 위치로 복사하고 색인 파일을 수정해야합니다. 당신이 dont'do 경우 오류와 원격 슬레이브을 깰 것이다

있어 바이너리 로그에서 데이터를 읽는 마스터에서 치명적인 오류 1236 :

'바이너리 로그 인덱스 파일의 첫 번째 로그 파일 이름을 찾을 수 없습니다'

자세한 정보는 여기를 참조하십시오 : http://freebsd.down-to-details.com/sys-admin/relocating-moving-mysql-binlogs/

+0

멀티 마스터 복제 설정이라면 어떻습니까? – shorif2000

+0

게시판에 같은 내용이 적용됩니까? 내가 마스터 마스터 설정의 컨텍스트에 있었지만 아무런 차이가 없어야합니다 ... – Rodo

관련 문제