root@localhost:/opt/mysql/scripts# ./mysql_install_db --base-dir=/opt/mysql --datadir=/opt/mysql/data




FATAL ERROR: Could not find ./bin/my_print_defaults




If you compiled from source, you need to run 'make install' to


copy the software into the correct location ready for operation.




If you are using a binary release, you must either be at the top


level of the extracted archive, or pass the --basedir option


pointing to that location.






FATAL ERROR: Could not find ./bin/my_print_defaults


위 에러 처럼 경로를 제대로 못찾고있다.


해결은


vi로 ./mysql_install_db 열어서


 21 basedir="/opt/mysql"

 22 builddir=""

 23 ldata="/opt/mysql/data"



위 라인에 직접 basedir ldata 에 직접 경로 넣어주고


./mysql_install_db


위에처럼 basedir 이나 datadir 옵션 주지말고 그냥 실행하면됨

+ Recent posts