本帖最后由 yueliangdao0608 于 2007-12-14 20:20:44 编辑

解决方案 »

  1.   

    1、不是所有的。有些是不记录的。只记录当前数据库的语句。如果切换数据库。也就记录其他数据库。(里面记录的是二进制内容)
    2、
    [mysqld]
    log-bin
    然后重新启动MYSQL
    3、不能那样导入。看我做的实验。
    http://blog.chinaunix.net/u/29134/showart_434296.html
      

  2.   

     谢谢一楼的朋友,我仔细看了你的东西  但是我还上有些问题 麻烦你帮忙一下
       1 我是在linux下操作的 show binlog events;这个命令根本不识别
       2 我问的问题 就是[mysqld] log-bin 是在my.ini还是 my,cnf里配置的  由于我对mysql不是很熟悉,不过我在的linux服务 器中没有找到my.ini的文件 只找到my.cnf 但是没有对这个的设置
       不过还要谢谢你的blog 对我很有启发 先谢谢了 
      

  3.   


    1、show binlog events 命令不是在SHELL下执行的,是在MYSQL的SHEll中执行的。
    [root@localhost ~]# mysql -uroot -p
    Enter password: 
    Welcome to the MySQL monitor.  Commands end with ; or \g.
    Your MySQL connection id is 214
    Server version: 5.1.21-beta MySQL Community Server (GPL)Type 'help;' or '\h' for help. Type '\c' to clear the buffer.mysql> show binlog events\G
    Empty set (0.00 sec)
    这个是没有开启BINLOG前的。
    开启步骤见下面:
    开启后的是这样的:
    [root@localhost ~]# mysql -uroot -p
    Enter password: 
    Welcome to the MySQL monitor.  Commands end with ; or \g.
    Your MySQL connection id is 7
    Server version: 5.1.21-beta-log MySQL Community Server (GPL)Type 'help;' or '\h' for help. Type '\c' to clear the buffer.mysql> show binlog events\G
    *************************** 1. row ***************************
       Log_name: localhost-bin.000001
            Pos: 4
     Event_type: Format_desc
      Server_id: 1
    End_log_pos: 106
           Info: Server ver: 5.1.21-beta-log, Binlog ver: 4
    1 row in set (0.00 sec)mysql> 2、BINLOG的开启:
    [root@localhost ~]# vi /etc/my.cnf 
    [mysqld]
    basedir=/usr/local/mysql/
    datadir=/usr/local/mysql/data/
    port=3306
    user=nobody
    socket=/tmp/mysql.sock
    default-character-set=utf8log-bin这里就可以了。
    "/etc/my.cnf" 36L, 558C written
    [root@localhost ~]# service mysqld restart
    Shutting down MySQL.. SUCCESS! 
    Starting MySQL. SUCCESS! 
      

  4.   

    还有,
    MY.INI是WINDOWS下的默认配置文件。
    MY.CNF 是LINUX下的默认配置文件。