MySQL

MySQL 8.0 버전 root 비밀번호 변경하기

OS: uBuntu MySQL 8.0.28 1. 비밀번호 변경 예전 (5.7 이상 버전)에는 UPDATE mysql.user SET authentication_string=password(“변경할 비밀번호”) WHERE user=’root’ 형식을 사용하였는데, 지금 실행하면 에러가 발생한다. 2. 변경사항 저장 3. 종료후 다시 로그인 해본다. 성공적으로 비밀번호가 변경되었다.

Warning: Using a password on the command line interface can be insecure.

1. 문제상황 > mysql 백업스트립트 작성시 다음과 같은 경고가 발생하였다. Warning: Using a password on the command line interface can be insecure. 2. 문제확인 > mysql 5.6버전부터 mysqldump 명령시 mysql_config_editor를 이용한 로그인 설정이 필요하다고 한다. 3. 문제해결 > 설정하기 mysql_config_editor set –login-path={설정명} –host=localhost –user=root –password Enter password: {패스워드를 입력하여 저장} > 사용하기 mysqldump –login-path={설정명} {디비명} … Warning: Using a password on the command line interface can be insecure. 더 보기 »