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

how to boost insert select from remote table #30479

Closed
674345386 opened this issue Oct 21, 2021 · 1 comment
Closed

how to boost insert select from remote table #30479

674345386 opened this issue Oct 21, 2021 · 1 comment

Comments

@674345386
Copy link

674345386 commented Oct 21, 2021

hi, when i run query :

insert into db.tb1_local select * from remote ('11.60.#.#',db.tb1_local,'username','passwd') where partition_col = '2021-10-10 23:00:00' SETTINGS max_execution_time=650,max_insert_threads=300,max_threads=300;

it took almost : Elapsed: 482.117 sec. Processed 17.26 million rows, 228.62 GB (35.80 thousand rows/s., 474.19 MB/s.)
500sec ,
it looks like it was a little bit slow than the common INSERT ,
how can i boost this INSERT SELECT FROM REMOTE ?

thx ~

@674345386 674345386 added the question Question? label Oct 21, 2021
@den-crane
Copy link
Contributor

den-crane commented Oct 21, 2021

35.80 thousand rows/s., 474.19 MB/s.

35.80 thousand rows/s., 474.19 MB/s. ~ 13kb row. It kinda wide rows.

474.19 MB/s -- Check the network bandwidth, 474.19 MB/s * 8 ~ 4 Gbit/s
Clickhouse does not compress data for remote queries. You may limited by a network.

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

No branches or pull requests

3 participants