Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

clickhouse-mysql real time insert data from MySQL into ClickHouse don't work #185

Open
zhituanchen opened this issue Sep 10, 2020 · 4 comments

Comments

@zhituanchen
Copy link

hi,team:
There is a situation:
1.Automatically create target table in ClickHouse and migrate existing data from MySQL to ClickHouse is ok:
clickhouse-mysql
--src-server-id=166
--src-wait
--nice-pause=1
--src-host=127.0.0.1
--src-user=clickhousereader
--src-password=12345
--src-tables=airline.ontime
--dst-host=127.0.0.1
--dst-create-table
--migrate-table
--pump-data
--csvpool
2.The script is runing . other session insert a data on mysql.But in ClickHouse can't select the data.
info:
[root@mytestuse clickhouse]# clickhouse-mysql \

--src-server-id=166 \
--src-wait \
--nice-pause=1 \
--src-host=127.0.0.1 \
--src-user=clickhousereader \
--src-password=12345 \
--src-tables=airline.ontime \
--dst-host=127.0.0.1 \
--dst-create-table \
--migrate-table \
--pump-data \
--csvpool

2020-09-10 16:12:26,348/1599725546.348313:INFO:Starting
2020-09-10 16:12:26,348/1599725546.348550:DEBUG:{'app': {'binlog_position_file': None,
'config_file': '/etc/clickhouse-mysql/clickhouse-mysql.conf',
......
2020-09-10 16:12:26,498/1599725546.498071:INFO:PoolWriter()
2020-09-10 16:12:26,498/1599725546.498164:DEBUG:Check events in binlog stream
2020-09-10 16:12:26,498/1599725546.498232:DEBUG:undef
2020-09-10 16:12:26,501/1599725546.501361:WARNING:Got an exception, skip it in blocking mode
2020-09-10 16:12:26,501/1599725546.501451:WARNING:'Connection' object has no attribute 'wfile'
2020-09-10 16:12:27,502/1599725547.502636:DEBUG:Check events in binlog stream
2020-09-10 16:12:27,502/1599725547.502819:DEBUG:Pre-start binlog position: mysqlbin.000032:4086
2020-09-10 16:12:27,506/1599725547.506407:WARNING:Got an exception, skip it in blocking mode
2020-09-10 16:12:27,506/1599725547.506510:WARNING:'Connection' object has no attribute 'wfile'
2020-09-10 16:12:28,507/1599725548.507796:DEBUG:Check events in binlog stream
.....
2020-09-10 16:12:39,565/1599725559.565709:DEBUG:Pre-start binlog position: mysqlbin.000032:4086
2020-09-10 16:12:39,570/1599725559.570876:WARNING:Got an exception, skip it in blocking mode
2020-09-10 16:12:39,571/1599725559.571060:WARNING:'Connection' object has no attribute 'wfile'
^C2020-09-10 16:12:39,715/1599725559.715296:INFO:SIGINT received. Time to exit.
2020-09-10 16:12:39,715/1599725559.715575:INFO:start 1599725546
2020-09-10 16:12:39,715/1599725559.715738:INFO:end 1599725559
2020-09-10 16:12:39,715/1599725559.715876:INFO:len 13
[root@mytestuse clickhouse]#

@SpikeWong
Copy link

I have encountered the same problem, after existing data has been migrated to clickhouse, the new insert event was not replicated to clickhouse.

@SpikeWong
Copy link

@zhituanchen Have you find a solution to solve this issue?

@SpikeWong
Copy link

@sunsingerus

@SpikeWong
Copy link

I may find the cause, in my case, I have not set the binlog_format as row

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants