MySQL的root管理者設定密碼的問題!!! - Linux
By Rosalind
at 2010-07-11T13:00
at 2010-07-11T13:00
Table of Contents
鳥哥的網址
http://linux.vbird.org/linux_server/0360apache.php
[root@linux ~]# /etc/init.d/mysqld start
# 如果是初次使用這個指令來啟動,你的 /var/lib/mysql 會建立資料庫。
[root@linux ~]# netstat -tuln | grep ':3306'
tcp 0 0 0.0.0.0:3306 0.0.0.0:* LISTEN
# 底下在測試看能否以手動的方式連上 MySQL 資料庫!
[root@linux ~]# mysql -u root
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 2 to server version: 4.1.20
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql> quit
Bye
以上這部分已經順利完成
問題是出在下面部分
鳥哥版的是如此
[root@linux ~]# mysqladmin -u root password 'your.password'
# 從此以後 MySQL 的 root 帳號就需要密碼了!如下所示:
[root@linux ~]# mysql -u root -p
Enter password: <==你必須要在這裡輸入剛剛建立的密碼!
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 4 to server version: 4.1.20
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql>quit
但我的版本卻是如此
[root@124-8-89-25 ~]# mysqladmin -u root password 'your.password'
[root@124-8-89-25 ~]# mysql -u root -p
Enter password:
ERROR 1045 (28000): Access denied for user 'root'@'localhost'
(using password: YES)
密碼我也有打哩
然後按下Enter鍵
出來的卻不一樣
麻煩各位高手解惑哩
--
Tags:
Linux
All Comments
By Oscar
at 2010-07-11T23:00
at 2010-07-11T23:00
By Ida
at 2010-07-14T11:39
at 2010-07-14T11:39
By Caroline
at 2010-07-16T14:45
at 2010-07-16T14:45
Related Posts
MySQL啟動的問題
By Agnes
at 2010-07-10T22:20
at 2010-07-10T22:20
cygwin下找不到pkg-config的script
By Lily
at 2010-07-10T10:18
at 2010-07-10T10:18
kdenlive 改善
By Oliver
at 2010-07-10T10:01
at 2010-07-10T10:01
CentOS掛在VMware下的PHP問題
By Doris
at 2010-07-10T08:06
at 2010-07-10T08:06
CentOS掛在VMware下的PHP問題
By Barb Cronin
at 2010-07-10T01:10
at 2010-07-10T01:10