-
Notifications
You must be signed in to change notification settings - Fork 8.3k
Support Replicated Database in ClickHouse Copier #35570
Copy link
Copy link
Closed
Labels
Description
Use case
ClickHouse copier doesn't currently work with replicated databases. It results in the following error:
2022.03.09 13:55:03.267739 [ 2160190 ] {} <Error> Application: Code: 80. DB::Exception: Received from k8s-ns179cef-c179cef1-da30ec77d6-0ae794c2c59d4061.elb.us-east-2.amazonaws.com:9440. DB::Exception: It's not initial query. ON CLUSTER is not allowed for Replicated database.. Stack trace:
0. DB::Exception::Exception(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, int, bool) @ 0xb06a5ba in /usr/bin/clickhouse
1. DB::DatabaseReplicated::tryEnqueueReplicatedDDL(std::__1::shared_ptr<DB::IAST> const&, std::__1::shared_ptr<DB::Context const>) @ 0x14f76371 in /usr/bin/clickhouse
2. DB::InterpreterCreateQuery::createTable(DB::ASTCreateQuery&) @ 0x15625b65 in /usr/bin/clickhouse
3. DB::InterpreterCreateQuery::execute() @ 0x1562d44b in /usr/bin/clickhouse
4. ? @ 0x15959c29 in /usr/bin/clickhouse
5. DB::executeQuery(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::shared_ptr<DB::Context>, bool, DB::QueryProcessingStage::Enum) @ 0x15957775 in /usr/bin/clickhouse
6. DB::TCPHandler::runImpl() @ 0x1649ddfa in /usr/bin/clickhouse
7. DB::TCPHandler::run() @ 0x164b1d99 in /usr/bin/clickhouse
8. Poco::Net::TCPServerConnection::start() @ 0x19768a4f in /usr/bin/clickhouse
9. Poco::Net::TCPServerDispatcher::run() @ 0x1976aea1 in /usr/bin/clickhouse
10. Poco::PooledThread::run() @ 0x19927ea9 in /usr/bin/clickhouse
11. Poco::ThreadImpl::runnableEntry(void*) @ 0x19925200 in /usr/bin/clickhouse
12. ? @ 0x7f9f93792609 in ?
13. clone @ 0x7f9f936b9293 in ?
. (INCORRECT_QUERY), Stack trace (when copying this message, always include the lines below):
Describe the solution you'd like
Remove ON_CLUSTER for replicated db.
Reactions are currently unavailable