AutoCAD 3DMAX C语言 Pro/E UG JAVA编程 PHP编程 Maya动画 Matlab应用 Android
Photoshop Word Excel flash VB编程 VC编程 Coreldraw SolidWorks A Designer Unity3D
 首页 > MySQL

Mysql学习点滴

51自学网 http://www.wanshiok.com

(二)在Windows2000 下的安装

  1。安装时选默认目录: c:/mysql
  2。把 c:/mysql/my-example.cnf copy 为 c:/my.cnf,并把 c:/mysql/lib/cygwinb19.dll copy 到 winnt/system32。
  3。启动 mysql的方法是:
    c:/mysql/bin/mysqld-shareware --install
    net start mysql
  这么简单,就可以启动了。
  4。更改 超级用户(root) 的密码:
    C:/mysql/bin/mysql mysql
    mysql> UPDATE user SET password=PASSWORD('your password') WHERE user='root';
    mysql> QUIT
    C:/mysql/bin/mysqladmin reload
    使用命令C:/mysql/bin/mysqlshow去看看检测一下。在这里应该显示:
    +-----------+
    | Databases |
    +-----------+
    | mysql |
    | test |
    +-----------+
    看到这些信息这一步就证明没问题了
    再来:
    C:/mysql/bin/mysqlshow --user=root --password=your password mysql
    在这里应该显示:
    Database: mysql
    +--------------+
    | Tables |
    +--------------+
    | columns_priv |
    | db |
    | host |
    | tables_priv |
    | user |
    +--------------+
    一切搞定!

  5。C:/mysql/bin/mysqladmin 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

 
 

上一篇:MySQL中修改密码及访问限制设置详解  下一篇:MySQL中文排序错误的解决方法