|
飞鸿无痕_cu 发表于 2011-11-14 16:30 ![]()
那你在从上能查询到在主上插入的对应数据吗?
可以的啊:
C:\Documents and Settings\Skyman.Man>mysql -h192.168.250.20 -uskyman.man -pmanchungood
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 2066667
Server version: 5.1.53-log Source distribution
Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
mysql> show databases;
+--------------------+
| Database |
+--------------------+
| information_schema |
| csf |
| csf_check |
| csf_cms |
| csf_home |
| csf_maec |
| csf_private |
| csf_pub |
| csf_sector |
| mysql |
| reuters_dss |
| reuters_interface |
| reuters_rkd |
+--------------------+
13 rows in set (0.00 sec)
mysql> use csf;
Database changed
mysql> insert into csf_cms.t(id,name) select 1,'name';
Query OK, 1 row affected (0.00 sec)
Records: 1 Duplicates: 0 Warnings: 0
mysql> exit
Bye
C:\Documents and Settings\Skyman.Man>mysql -h192.168.250.40 -uskyman.man -pmanchungood
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 263
Server version: 5.1.53-log Source distribution
Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
mysql> show slave status\G;
*************************** 1. row ***************************
Slave_IO_State: Waiting for master to send event
Master_Host: 192.168.250.20
Master_User: rel
Master_Port: 3306
Connect_Retry: 60
Master_Log_File: mysql-bin.000893
Read_Master_Log_Pos: 1020576681
Relay_Log_File: relay-bin.001146
Relay_Log_Pos: 1020576826
Relay_Master_Log_File: mysql-bin.000893
Slave_IO_Running: Yes
Slave_SQL_Running: Yes
Replicate_Do_DB:
Replicate_Ignore_DB:
Replicate_Do_Table:
Replicate_Ignore_Table:
Replicate_Wild_Do_Table:
Replicate_Wild_Ignore_Table:
Last_Errno: 0
Last_Error:
Skip_Counter: 0
Exec_Master_Log_Pos: 1020576681
Relay_Log_Space: 1020577018
Until_Condition: None
Until_Log_File:
Until_Log_Pos: 0
Master_SSL_Allowed: No
Master_SSL_CA_File:
Master_SSL_CA_Path:
Master_SSL_Cert:
Master_SSL_Cipher:
Master_SSL_Key:
Seconds_Behind_Master: 0
Master_SSL_Verify_Server_Cert: No
Last_IO_Errno: 0
Last_IO_Error:
Last_SQL_Errno: 0
Last_SQL_Error:
1 row in set (0.00 sec)
ERROR:
No query specified
mysql> select * from csf_cms.t;
+----+------+
| id | name |
+----+------+
| 1 | name |
+----+------+
1 row in set (0.00 sec)
mysql>
|
|