(二)在Windows2000下的安裝
1。安裝時選默認目錄:c:MySQL
2。把c:mysqlmy-example.cnf copy為c:my.cnf,並把c:MySQLibgwinb19.dll copy到winntsystem32。
3。啟動MySQL的方法是:
c:mysqlinMySQLd-shareware --install
net start MySQL
這麼簡單,就可以啟動了。
4。更改超級用戶(root)的密碼:
C:mysqlinmysql MySQL
MySQL> UPDATE user SET password=PASSWORD('your passWord')swheresuser='root';
MySQL> QUIT
C:mysqlinMySQLadmin reload
使用命令C:mysqlinMySQLshow去看看檢測一下。在這裡應該顯示:
+-----------+
| Databases |
+-----------+
| MySQL |
| test |
+-----------+
看到這些信息這一步就證明沒問題了
再來:
C:mysqlinmysqlshow --user=root --password=your passWord MySQL
在這裡應該顯示:
Database: MySQL
+--------------+
| Tables |
+--------------+
| columns_priv |
| db |
| host |
| tables_priv |
| user |
+--------------+
一切搞定!
5。C:mysqlinMySQLadmin version status proc
應該可以看到這些版本信息的:
MySQLadmin Ver 8.0 Distrib 3.22.32, for Win95/Win98 on i586
TCX Datakonsult AB, by Monty
Server version 3.22.32-shareware-debug
Protocol version 10
Connection localhost via TCP/IP
TCP port 3306
Uptime: 1 hour 29 min 30 sec
Threads: 1 Questions: 72 Slow querIEs: 0 Opens: 16 Flush tables: 1 Open tables: 0 Memory in use: 16423K Max memory used: 16490K
Uptime: 5370 Threads: 1 Questions: 72 Slow querIEs: 0 Opens: 16 Flush tables: 1 Open tables: 0 Memory in use: 16423K Max memory used: 16490K
+----+------+-----------+----+---------+------+-------+------------------+
| Id | User | Host | db | Command | Time | State | Info |
+----+------+-----------+----+---------+------+-------+------------------+
| 35 | ODBC | localhost | | Query | 0 | | show processlist |
+----+------+-----------+----+---------+------+-------+------------------+
接著,用show databases命令可以將安裝的數據庫列出來:
MySQL> show databases;
你就可以看到:
+----------+
| Database |
+----------+
| MySQL |
| test |
+----------+
2 rows in set (0.00 sec)
如果一切正常的話,那說明MySQL可以完全工作了!如果要退出程序,輸入:exit
MySQL> exit;
Bye