블로그 이미지
내게 능력 주시는 자 안에서 내가 모든것을 할수 있느니라 - 빌립보서 4 : 13 - happydong

카테고리

Happydong (1363)
프로그래밍 (156)
MUSIC (16)
인물 (3)
Utility (10)
세미나 소식&내용 (22)
IT뉴스 (18)
운동 (830)
CAFE (10)
Life (282)
Total
Today
Yesterday



[원본 출처 : http://www.apmsetup.com/database.php?tutid=138&uid=291]

Windows 플랫폼 일단 실행되고 있는 MySQL 데몬을 종료 하여야 합니다. 작업 관리자(Ctrl+Shift+Esc) 또는 Ctrl+Alt+Del 을 실행시켜서 mysqld.exe 또는 mysqld-nt.exe 를 찾아서 프로세스 종료 해주신 다음 아래의 방법대로 작업 하시기 바랍니다. MS-DOS 창을 열어서 Windows 98 :: 시작 -> 실행 -> command Windows NT :: 시작 -> 실행 -> cmd MySQL 이 설치된 디렉토리로 이동하신다음

mysqld.exe --skip-grant
다음과 같이 승인 절차를 거치지 않도록 MySQL 데몬을 실행합니다. 또 다른 MS-DOS 창을 열어서 MySQL 이 설치된 디렉토리에서 아래와 같이 실행 합니다.
mysql.exe Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 1 to server version: 4.0.14-max-debug Type 'help;' or '\h' for help. Type '\c' to clear the buffer. mysql> use mysql; Database changed mysql> UPDATE user SET password=PASSWORD('변경할패스워드') where user='root'; Query OK, 0 rows affected (0.14 sec) Rows matched: 1 Changed: 0 Warnings: 0 mysql> FLUSH PRIVILEGES; Query OK, 0 rows affected (0.11 sec) mysql> quit Bye
이젠 먼저 MySQL 데몬을 실행한 도스창을 닫으시고 정상적으로 MySQL 데몬을 실행하시면 변경할패스워드 로 MySQL root 패스워드가 변경되 었습니다. ■ UNIX 플랫폼 MySQL 이 실행되고 있다면
[root@ns /root]# mysql.server stop
또는
[root@ns /root]# killall mysqld
위와 같은 방법으로 MySQL 데몬을 종료 합니다. 이제 승인 절차를 거치지 않도록 MySQL 데몬을 실행합니다.
[root@ns /root]# safe_mysqld --skip-grant &
이제 MySQL root 패스워드를 변경합니다.
[root@ns /root]# mysql Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 2918080 to server version: 4.0.16 Type 'help;' or '\h' for help. Type '\c' to clear the buffer. mysql> use mysql; Database changed mysql> UPDATE user SET password=PASSWORD('변경할패스워드') where user='root'; Query OK, 0 rows affected (0.14 sec) Rows matched: 1 Changed: 0 Warnings: 0 mysql> FLUSH PRIVILEGES; Query OK, 0 rows affected (0.11 sec) mysql> quit Bye
이제 MySQL 데몬을
[root@ns /root]# killall safe_mysqld
위와 같이 종료 하시고 다시 실행시켜 주시면 변경된 패스워드로 동작 합니다.


Posted by happydong
, |