当前位置: 首页 > news >正文

dede新手做网站多久郴州网站建设

dede新手做网站多久,郴州网站建设,做网站卖狗挣钱吗,头像设计集群环境下,在任意一个节点创建数据库,如果加上了ON CLUSTER clustername,则在集群环境的所有节点上都创建了该数据库,并在集群环境的所有节点上都创建了该数据库对应的目录,且数据库的metadata_path对应的目录路径在所…

集群环境下,在任意一个节点创建数据库,如果加上了ON CLUSTER clustername,则在集群环境的所有节点上都创建了该数据库,并在集群环境的所有节点上都创建了该数据库对应的目录,且数据库的metadata_path对应的目录路径在所有节点都是一致的
集群环境下,在任意一个节点创建数据库,如果不加ON CLUSTER clustername,则只在当前节点建立了这个数据库,其他节点没有自动建立,需要在其他节点也执行创建一遍,且数据库的metadata_path对应的目录在各个节点各不相同
CREATE DATABASE lukestest1 ON CLUSTER cluster_2shared2replicas;
CREATE DATABASE lukestest2;

集群环境下,在任意一个节点删除数据库,如果加上了ON CLUSTER clustername,则在集群环境的所有节点上都删除了该数据库,并在集群环境的所有节点上都删除了数据库对应的目录
集群环境下,在任意一个节点删除数据库,如果不加ON CLUSTER clustername,则只在当前节点删除了该数据库,也只在当前节点删除了该数据库对应的目录,其他节点不受影响
drop database lukestest1 ON CLUSTER cluster_2shared2replicas;
drop database testlukes202306;

在节点1上创建数据库加ON CLUSTER cluster_2shared2replicas的输出结果

DAILACHDBUD001 :) CREATE DATABASE lukestest1 ON CLUSTER cluster_2shared2replicas;
CREATE DATABASE lukestest1 ON CLUSTER cluster_2shared2replicas
Query id: 54163214-009c-4362-9b51-d5e61f9c1767
┌─host───────────┬─port─┬─status─┬─error─┬─num_hosts_remaining─┬─num_hosts_active─┐
│ DAILACHDBUD001 │ 90000 │       │                   30 │
│ DAILACHDBUD004 │ 90000 │       │                   20 │
└────────────────┴──────┴────────┴───────┴─────────────────────┴──────────────────┘
┌─host───────────┬─port─┬─status─┬─error─┬─num_hosts_remaining─┬─num_hosts_active─┐
│ DAILACHDBUD003 │ 90000 │       │                   11 │
└────────────────┴──────┴────────┴───────┴─────────────────────┴──────────────────┘
┌─host───────────┬─port─┬─status─┬─error─┬─num_hosts_remaining─┬─num_hosts_active─┐
│ DAILACHDBUD002 │ 90000 │       │                   00 │
└────────────────┴──────┴────────┴───────┴─────────────────────┴──────────────────┘
4 rows in set. Elapsed: 0.927 sec.

在节点1上创建数据库不加ON CLUSTER cluster_2shared2replicas的输出结果

DAILACHDBUD001 :) CREATE DATABASE lukestest2;
CREATE DATABASE lukestest2
Query id: 670adde2-f104-443e-bba9-42dca3fbbdd1
Ok.
0 rows in set. Elapsed: 0.009 sec.

在四个节点上查询新建的数据库路径
备注:发现使用ON CLUSTER关键字在所有节点上同时创建的数据库,数据库的metadata_path在所有节点都是一致的;每个节点上单独创建的数据库,数据库的metadata_path在各个节点各不相同

DAILACHDBUD001 :) select name,engine,data_path,metadata_path from system.databases;
┌─name───────────────┬─engine─┬─data_path──────────────────────┬─metadata_path───────────────────────────────────────────────────────────┐
│ INFORMATION_SCHEMA │ Memory │ /chdata/clickhouse/data/       │                                                                         │
│ default            │ Atomic │ /chdata/clickhouse/data/store//chdata/clickhouse/data/store/9a9/9a92deeb-da20-4395-9200-3ede0acb203a/ │
│ information_schema │ Memory │ /chdata/clickhouse/data/       │                                                                         │
│ lukestest1         │ Atomic │ /chdata/clickhouse/data/store//chdata/clickhouse/data/store/91a/91aa06cd-96c3-4586-af6f-4e6587d7b368/ │
│ lukestest2         │ Atomic │ /chdata/clickhouse/data/store//chdata/clickhouse/data/store/0df/0dff644a-40ac-4138-8c0d-1b7f0c382454/ │
│ sentry             │ Atomic │ /chdata/clickhouse/data/store//chdata/clickhouse/data/store/24a/24a5aa06-54b5-4606-8c27-5e3adfd11049/ │
│ system             │ Atomic │ /chdata/clickhouse/data/store//chdata/clickhouse/data/store/ccd/ccda574b-2524-4045-91ae-5c4490452d50/ │
│ testlukes202306    │ Atomic │ /chdata/clickhouse/data/store//chdata/clickhouse/data/store/6b4/6b439484-c011-48f9-8d05-339ea2cd7961/ │
└────────────────────┴────────┴────────────────────────────────┴─────────────────────────────────────────────────────────────────────────┘root@DAILACHDBUD001:~# ll /chdata/clickhouse/data/store/91a/91aa06cd-96c3-4586-af6f-4e6587d7b368/
total 140
drwxr-x--- 2 clickhouse clickhouse 4096 Oct 26 08:44 ./
drwxr-x--- 3 clickhouse clickhouse   50 Oct 23 02:56 ../
-rw-r----- 1 clickhouse clickhouse  172 Oct 26 08:37 %2Einner_id%2E3150ecef%2D55fb%2D41c9%2Da8c1%2D7f9028b344ab.sql
-rw-r----- 1 clickhouse clickhouse  172 Oct 26 08:38 %2Einner_id%2E409529be%2Dadf3%2D40c2%2Dad9c%2Dacd4b88f069d.sql
-rw-r----- 1 clickhouse clickhouse  172 Oct 26 08:44 %2Einner_id%2E8260d608%2Dfb5e%2D4252%2Da3ed%2De205626288d1.sql
-rw-r----- 1 clickhouse clickhouse  172 Oct 26 08:44 %2Einner_id%2E95151d8d%2D0b0a%2D4671%2D9fe6%2D49e3429f8452.sql
-rw-r----- 1 clickhouse clickhouse  198 Oct 25 10:18 table_distributed1.sql
-rw-r----- 1 clickhouse clickhouse  198 Oct 26 03:46 table_Distributed_mergetree3.sql
-rw-r----- 1 clickhouse clickhouse  197 Oct 24 09:49 table_Distributed_mergetree.sql
-rw-r----- 1 clickhouse clickhouse  208 Oct 26 02:47 table_Distributed_ReplicatedMergeTree2.sql
-rw-r----- 1 clickhouse clickhouse  208 Oct 26 03:23 table_Distributed_ReplicatedMergeTree3.sql
-rw-r----- 1 clickhouse clickhouse  207 Oct 24 09:50 table_Distributed_ReplicatedMergeTree.sql
-rw-r----- 1 clickhouse clickhouse  172 Oct 26 06:25 table_mergetest12.sql
-rw-r----- 1 clickhouse clickhouse  157 Oct 26 06:28 table_mergetest1_Merge.sql
-rw-r----- 1 clickhouse clickhouse  172 Oct 26 06:24 table_mergetest1.sql
-rw-r----- 1 clickhouse clickhouse  172 Oct 26 06:26 table_mergetest23.sql
-rw-r----- 1 clickhouse clickhouse  302 Oct 26 08:44 table_mergetest2_materialized1.sql
-rw-r----- 1 clickhouse clickhouse  302 Oct 26 08:44 table_mergetest2_materialized_nopopulate1.sql
-rw-r----- 1 clickhouse clickhouse  302 Oct 26 08:38 table_mergetest2_materialized_nopopulate.sql
-rw-r----- 1 clickhouse clickhouse  302 Oct 26 08:37 table_mergetest2_materialized.sql
-rw-r----- 1 clickhouse clickhouse  157 Oct 26 06:28 table_mergetest2_Merge.sql
-rw-r----- 1 clickhouse clickhouse  172 Oct 26 08:35 table_mergetest2.sql
-rw-r----- 1 clickhouse clickhouse  172 Oct 25 05:42 tableMergeTree1.sql
-rw-r----- 1 clickhouse clickhouse  192 Oct 25 05:57 tableMergeTree1_view2.sql
-rw-r----- 1 clickhouse clickhouse  192 Oct 25 05:57 tableMergeTree1_view3.sql
-rw-r----- 1 clickhouse clickhouse  197 Oct 25 05:57 tableMergeTree1_view_round.sql
-rw-r----- 1 clickhouse clickhouse  189 Oct 25 05:43 tableMergeTree1_view.sql
-rw-r----- 1 clickhouse clickhouse  172 Oct 26 03:46 table_mergetree3.sql
-rw-r----- 1 clickhouse clickhouse  172 Oct 23 08:02 table_mergetree.sql
-rw-r----- 1 clickhouse clickhouse  278 Oct 24 04:14 table_ReplicatedAggregatingMergeTree.sql
-rw-r----- 1 clickhouse clickhouse  267 Oct 25 06:18 table_ReplicatedMergeTree1.sql
-rw-r----- 1 clickhouse clickhouse  208 Oct 25 06:25 table_ReplicatedMergeTree1_view.sql
-rw-r----- 1 clickhouse clickhouse  267 Oct 26 02:47 table_ReplicatedMergeTree2.sql
-rw-r----- 1 clickhouse clickhouse  267 Oct 26 03:22 table_ReplicatedMergeTree3.sql
-rw-r----- 1 clickhouse clickhouse  267 Oct 23 10:24 table_ReplicatedMergeTree.sql
-rw-r----- 1 clickhouse clickhouse  276 Oct 24 04:10 table_ReplicatedReplacingMergeTree.sqlroot@DAILACHDBUD001:~# ll /chdata/clickhouse/data/store/0df/0dff644a-40ac-4138-8c0d-1b7f0c382454/
total 24
drwxr-x--- 2 clickhouse clickhouse 252 Oct 24 09:51 ./
drwxr-x--- 3 clickhouse clickhouse  50 Oct 23 02:56 ../
-rw-r----- 1 clickhouse clickhouse 197 Oct 24 09:51 table_Distributed_mergetree.sql
-rw-r----- 1 clickhouse clickhouse 207 Oct 24 09:51 table_Distributed_ReplicatedMergeTree.sql
-rw-r----- 1 clickhouse clickhouse 172 Oct 23 08:04 table_mergetree.sql
-rw-r----- 1 clickhouse clickhouse 278 Oct 24 04:14 table_ReplicatedAggregatingMergeTree.sql
-rw-r----- 1 clickhouse clickhouse 267 Oct 23 10:25 table_ReplicatedMergeTree.sql
-rw-r----- 1 clickhouse clickhouse 276 Oct 24 04:11 table_ReplicatedReplacingMergeTree.sqlDAILACHDBUD002 :) select name,engine,data_path,metadata_path from system.databases;
┌─name───────────────┬─engine─┬─data_path──────────────────────┬─metadata_path───────────────────────────────────────────────────────────┐
│ INFORMATION_SCHEMA │ Memory │ /chdata/clickhouse/data/       │                                                                         │
│ default            │ Atomic │ /chdata/clickhouse/data/store//chdata/clickhouse/data/store/d35/d35e18e6-f03d-41f9-8cc0-537be187ad21/ │
│ information_schema │ Memory │ /chdata/clickhouse/data/       │                                                                         │
│ lukestest1         │ Atomic │ /chdata/clickhouse/data/store//chdata/clickhouse/data/store/91a/91aa06cd-96c3-4586-af6f-4e6587d7b368/ │
│ lukestest2         │ Atomic │ /chdata/clickhouse/data/store//chdata/clickhouse/data/store/ec4/ec480a66-3d57-4ee9-a194-74fa7b7bb705/ │
│ sentry             │ Atomic │ /chdata/clickhouse/data/store//chdata/clickhouse/data/store/24a/24a5aa06-54b5-4606-8c27-5e3adfd11049/ │
│ system             │ Atomic │ /chdata/clickhouse/data/store//chdata/clickhouse/data/store/af6/af67a94d-23e8-4a24-9d8f-97e4a8ec8e63/ │
│ testlukes202306    │ Atomic │ /chdata/clickhouse/data/store//chdata/clickhouse/data/store/6b4/6b439484-c011-48f9-8d05-339ea2cd7961/ │
└────────────────────┴────────┴────────────────────────────────┴─────────────────────────────────────────────────────────────────────────┘root@DAILACHDBUD002:~# ll /chdata/clickhouse/data/store/91a/91aa06cd-96c3-4586-af6f-4e6587d7b368/
total 84
drwxr-x--- 2 clickhouse clickhouse 4096 Oct 27 05:50 ./
drwxr-x--- 3 clickhouse clickhouse   50 Oct 23 02:56 ../
-rw-r----- 1 clickhouse clickhouse  198 Oct 25 10:18 table_distributed1.sql
-rw-r----- 1 clickhouse clickhouse  198 Oct 26 03:46 table_Distributed_mergetree3.sql
-rw-r----- 1 clickhouse clickhouse  197 Oct 24 09:49 table_Distributed_mergetree.sql
-rw-r----- 1 clickhouse clickhouse  208 Oct 26 02:47 table_Distributed_ReplicatedMergeTree2.sql
-rw-r----- 1 clickhouse clickhouse  208 Oct 26 03:23 table_Distributed_ReplicatedMergeTree3.sql
-rw-r----- 1 clickhouse clickhouse  207 Oct 24 09:50 table_Distributed_ReplicatedMergeTree.sql
-rw-r----- 1 clickhouse clickhouse  172 Oct 25 05:42 tableMergeTree1.sql
-rw-r----- 1 clickhouse clickhouse  192 Oct 25 05:57 tableMergeTree1_view2.sql
-rw-r----- 1 clickhouse clickhouse  192 Oct 25 05:57 tableMergeTree1_view3.sql
-rw-r----- 1 clickhouse clickhouse  197 Oct 25 05:57 tableMergeTree1_view_round.sql
-rw-r----- 1 clickhouse clickhouse  189 Oct 25 05:43 tableMergeTree1_view.sql
-rw-r----- 1 clickhouse clickhouse  172 Oct 26 03:46 table_mergetree3.sql
-rw-r----- 1 clickhouse clickhouse  172 Oct 23 08:02 table_mergetree.sql
-rw-r----- 1 clickhouse clickhouse  278 Oct 24 04:14 table_ReplicatedAggregatingMergeTree.sql
-rw-r----- 1 clickhouse clickhouse  267 Oct 25 06:18 table_ReplicatedMergeTree1.sql
-rw-r----- 1 clickhouse clickhouse  208 Oct 25 06:25 table_ReplicatedMergeTree1_view.sql
-rw-r----- 1 clickhouse clickhouse  267 Oct 26 02:47 table_ReplicatedMergeTree2.sql
-rw-r----- 1 clickhouse clickhouse  267 Oct 26 03:22 table_ReplicatedMergeTree3.sql
-rw-r----- 1 clickhouse clickhouse  267 Oct 23 10:24 table_ReplicatedMergeTree.sql
-rw-r----- 1 clickhouse clickhouse  276 Oct 24 04:10 table_ReplicatedReplacingMergeTree.sqlroot@DAILACHDBUD002:~# ll /chdata/clickhouse/data/store/ec4/ec480a66-3d57-4ee9-a194-74fa7b7bb705/
total 24
drwxr-x--- 2 clickhouse clickhouse 252 Oct 24 09:51 ./
drwxr-x--- 3 clickhouse clickhouse  50 Oct 23 05:53 ../
-rw-r----- 1 clickhouse clickhouse 197 Oct 24 09:51 table_Distributed_mergetree.sql
-rw-r----- 1 clickhouse clickhouse 207 Oct 24 09:51 table_Distributed_ReplicatedMergeTree.sql
-rw-r----- 1 clickhouse clickhouse 172 Oct 23 08:04 table_mergetree.sql
-rw-r----- 1 clickhouse clickhouse 278 Oct 24 04:14 table_ReplicatedAggregatingMergeTree.sql
-rw-r----- 1 clickhouse clickhouse 267 Oct 23 10:25 table_ReplicatedMergeTree.sql
-rw-r----- 1 clickhouse clickhouse 276 Oct 24 04:11 table_ReplicatedReplacingMergeTree.sqlDAILACHDBUD003 :) select name,engine,data_path,metadata_path from system.databases;
┌─name───────────────┬─engine─┬─data_path──────────────────────┬─metadata_path───────────────────────────────────────────────────────────┐
│ INFORMATION_SCHEMA │ Memory │ /chdata/clickhouse/data/       │                                                                         │
│ default            │ Atomic │ /chdata/clickhouse/data/store//chdata/clickhouse/data/store/fb8/fb81d157-e9cc-43f1-9eeb-61c52011363d/ │
│ information_schema │ Memory │ /chdata/clickhouse/data/       │                                                                         │
│ lukestest1         │ Atomic │ /chdata/clickhouse/data/store//chdata/clickhouse/data/store/91a/91aa06cd-96c3-4586-af6f-4e6587d7b368/ │
│ lukestest2         │ Atomic │ /chdata/clickhouse/data/store//chdata/clickhouse/data/store/b26/b26b894a-44a7-470e-b860-6524655b0cbc/ │
│ sentry             │ Atomic │ /chdata/clickhouse/data/store//chdata/clickhouse/data/store/24a/24a5aa06-54b5-4606-8c27-5e3adfd11049/ │
│ system             │ Atomic │ /chdata/clickhouse/data/store//chdata/clickhouse/data/store/f51/f5122fb5-b2c4-4a1b-bb16-1e5383aa7c6a/ │
│ testlukes202306    │ Atomic │ /chdata/clickhouse/data/store//chdata/clickhouse/data/store/6b4/6b439484-c011-48f9-8d05-339ea2cd7961/ │
└────────────────────┴────────┴────────────────────────────────┴─────────────────────────────────────────────────────────────────────────┘root@DAILACHDBUD003:~# ll /chdata/clickhouse/data/store/91a/91aa06cd-96c3-4586-af6f-4e6587d7b368/
total 84
drwxr-x--- 2 clickhouse clickhouse 4096 Oct 26 06:23 ./
drwxr-x--- 3 clickhouse clickhouse   50 Oct 23 02:56 ../
-rw-r----- 1 clickhouse clickhouse  198 Oct 25 10:18 table_distributed1.sql
-rw-r----- 1 clickhouse clickhouse  198 Oct 26 03:46 table_Distributed_mergetree3.sql
-rw-r----- 1 clickhouse clickhouse  197 Oct 24 09:49 table_Distributed_mergetree.sql
-rw-r----- 1 clickhouse clickhouse  208 Oct 26 02:47 table_Distributed_ReplicatedMergeTree2.sql
-rw-r----- 1 clickhouse clickhouse  208 Oct 26 03:23 table_Distributed_ReplicatedMergeTree3.sql
-rw-r----- 1 clickhouse clickhouse  207 Oct 24 09:50 table_Distributed_ReplicatedMergeTree.sql
-rw-r----- 1 clickhouse clickhouse  172 Oct 25 05:42 tableMergeTree1.sql
-rw-r----- 1 clickhouse clickhouse  192 Oct 25 05:57 tableMergeTree1_view2.sql
-rw-r----- 1 clickhouse clickhouse  192 Oct 25 05:57 tableMergeTree1_view3.sql
-rw-r----- 1 clickhouse clickhouse  197 Oct 25 05:57 tableMergeTree1_view_round.sql
-rw-r----- 1 clickhouse clickhouse  189 Oct 25 05:43 tableMergeTree1_view.sql
-rw-r----- 1 clickhouse clickhouse  172 Oct 26 03:46 table_mergetree3.sql
-rw-r----- 1 clickhouse clickhouse  172 Oct 23 08:02 table_mergetree.sql
-rw-r----- 1 clickhouse clickhouse  278 Oct 24 04:14 table_ReplicatedAggregatingMergeTree.sql
-rw-r----- 1 clickhouse clickhouse  267 Oct 25 06:18 table_ReplicatedMergeTree1.sql
-rw-r----- 1 clickhouse clickhouse  208 Oct 25 06:25 table_ReplicatedMergeTree1_view.sql
-rw-r----- 1 clickhouse clickhouse  267 Oct 26 02:47 table_ReplicatedMergeTree2.sql
-rw-r----- 1 clickhouse clickhouse  267 Oct 26 03:22 table_ReplicatedMergeTree3.sql
-rw-r----- 1 clickhouse clickhouse  267 Oct 23 10:24 table_ReplicatedMergeTree.sql
-rw-r----- 1 clickhouse clickhouse  276 Oct 24 04:10 table_ReplicatedReplacingMergeTree.sqlroot@DAILACHDBUD003:~# ll /chdata/clickhouse/data/store/b26/b26b894a-44a7-470e-b860-6524655b0cbc/
total 24
drwxr-x--- 2 clickhouse clickhouse 252 Oct 24 09:51 ./
drwxr-x--- 3 clickhouse clickhouse  50 Oct 23 05:56 ../
-rw-r----- 1 clickhouse clickhouse 197 Oct 24 09:51 table_Distributed_mergetree.sql
-rw-r----- 1 clickhouse clickhouse 207 Oct 24 09:51 table_Distributed_ReplicatedMergeTree.sql
-rw-r----- 1 clickhouse clickhouse 172 Oct 23 08:04 table_mergetree.sql
-rw-r----- 1 clickhouse clickhouse 278 Oct 24 04:14 table_ReplicatedAggregatingMergeTree.sql
-rw-r----- 1 clickhouse clickhouse 267 Oct 23 10:25 table_ReplicatedMergeTree.sql
-rw-r----- 1 clickhouse clickhouse 276 Oct 24 04:11 table_ReplicatedReplacingMergeTree.sqlDAILACHDBUD004 :) select name,engine,data_path,metadata_path from system.databases;
┌─name───────────────┬─engine─┬─data_path──────────────────────┬─metadata_path───────────────────────────────────────────────────────────┐
│ INFORMATION_SCHEMA │ Memory │ /chdata/clickhouse/data/       │                                                                         │
│ default            │ Atomic │ /chdata/clickhouse/data/store//chdata/clickhouse/data/store/f91/f91dcc2d-e6f6-4948-a4a6-356cb74339ec/ │
│ information_schema │ Memory │ /chdata/clickhouse/data/       │                                                                         │
│ lukestest1         │ Atomic │ /chdata/clickhouse/data/store//chdata/clickhouse/data/store/91a/91aa06cd-96c3-4586-af6f-4e6587d7b368/ │
│ lukestest2         │ Atomic │ /chdata/clickhouse/data/store//chdata/clickhouse/data/store/d5c/d5c04c61-2e1f-4624-801d-b121f2f50365/ │
│ sentry             │ Atomic │ /chdata/clickhouse/data/store//chdata/clickhouse/data/store/24a/24a5aa06-54b5-4606-8c27-5e3adfd11049/ │
│ system             │ Atomic │ /chdata/clickhouse/data/store//chdata/clickhouse/data/store/bdc/bdc336ca-96d2-4103-ab01-6a209278ccd2/ │
│ testlukes202306    │ Atomic │ /chdata/clickhouse/data/store//chdata/clickhouse/data/store/6b4/6b439484-c011-48f9-8d05-339ea2cd7961/ │
└────────────────────┴────────┴────────────────────────────────┴─────────────────────────────────────────────────────────────────────────┘root@DAILACHDBUD004:~# ll /chdata/clickhouse/data/store/91a/91aa06cd-96c3-4586-af6f-4e6587d7b368/
total 84
drwxr-x--- 2 clickhouse clickhouse 4096 Oct 26 06:23 ./
drwxr-x--- 3 clickhouse clickhouse   50 Oct 23 02:56 ../
-rw-r----- 1 clickhouse clickhouse  198 Oct 25 10:18 table_distributed1.sql
-rw-r----- 1 clickhouse clickhouse  198 Oct 26 03:46 table_Distributed_mergetree3.sql
-rw-r----- 1 clickhouse clickhouse  197 Oct 24 09:49 table_Distributed_mergetree.sql
-rw-r----- 1 clickhouse clickhouse  208 Oct 26 02:47 table_Distributed_ReplicatedMergeTree2.sql
-rw-r----- 1 clickhouse clickhouse  208 Oct 26 03:23 table_Distributed_ReplicatedMergeTree3.sql
-rw-r----- 1 clickhouse clickhouse  207 Oct 24 09:50 table_Distributed_ReplicatedMergeTree.sql
-rw-r----- 1 clickhouse clickhouse  172 Oct 25 05:42 tableMergeTree1.sql
-rw-r----- 1 clickhouse clickhouse  192 Oct 25 05:57 tableMergeTree1_view2.sql
-rw-r----- 1 clickhouse clickhouse  192 Oct 25 05:57 tableMergeTree1_view3.sql
-rw-r----- 1 clickhouse clickhouse  197 Oct 25 05:57 tableMergeTree1_view_round.sql
-rw-r----- 1 clickhouse clickhouse  189 Oct 25 05:43 tableMergeTree1_view.sql
-rw-r----- 1 clickhouse clickhouse  172 Oct 26 03:46 table_mergetree3.sql
-rw-r----- 1 clickhouse clickhouse  172 Oct 23 08:02 table_mergetree.sql
-rw-r----- 1 clickhouse clickhouse  278 Oct 24 04:14 table_ReplicatedAggregatingMergeTree.sql
-rw-r----- 1 clickhouse clickhouse  267 Oct 25 06:18 table_ReplicatedMergeTree1.sql
-rw-r----- 1 clickhouse clickhouse  208 Oct 25 06:25 table_ReplicatedMergeTree1_view.sql
-rw-r----- 1 clickhouse clickhouse  267 Oct 26 02:47 table_ReplicatedMergeTree2.sql
-rw-r----- 1 clickhouse clickhouse  267 Oct 26 03:22 table_ReplicatedMergeTree3.sql
-rw-r----- 1 clickhouse clickhouse  267 Oct 23 10:24 table_ReplicatedMergeTree.sql
-rw-r----- 1 clickhouse clickhouse  276 Oct 24 04:10 table_ReplicatedReplacingMergeTree.sqlroot@DAILACHDBUD004:~# ll /chdata/clickhouse/data/store/d5c/d5c04c61-2e1f-4624-801d-b121f2f50365/
total 24
drwxr-x--- 2 clickhouse clickhouse 252 Oct 24 09:51 ./
drwxr-x--- 3 clickhouse clickhouse  50 Oct 23 05:57 ../
-rw-r----- 1 clickhouse clickhouse 197 Oct 24 09:51 table_Distributed_mergetree.sql
-rw-r----- 1 clickhouse clickhouse 207 Oct 24 09:51 table_Distributed_ReplicatedMergeTree.sql
-rw-r----- 1 clickhouse clickhouse 172 Oct 23 08:04 table_mergetree.sql
-rw-r----- 1 clickhouse clickhouse 278 Oct 24 04:14 table_ReplicatedAggregatingMergeTree.sql
-rw-r----- 1 clickhouse clickhouse 267 Oct 23 10:25 table_ReplicatedMergeTree.sql
-rw-r----- 1 clickhouse clickhouse 276 Oct 24 04:11 table_ReplicatedReplacingMergeTree.sql

删除数据库,可以直接delete on cluster在四个节点上一起删除,四个节点的数据库都删除后,数据库对应的目录也在四个节点上被删除了

DAILACHDBUD001 :) drop database lukestest1 ON CLUSTER cluster_2shared2replicas;
Query id: 914d41e0-3bac-4d75-a068-0d19783a3a2b
┌─host───────────┬─port─┬─status─┬─error─┬─num_hosts_remaining─┬─num_hosts_active─┐
│ DAILACHDBUD001 │ 90000 │       │                   31 │
│ DAILACHDBUD002 │ 90000 │       │                   21 │
│ DAILACHDBUD004 │ 90000 │       │                   11 │
└────────────────┴──────┴────────┴───────┴─────────────────────┴──────────────────┘
┌─host───────────┬─port─┬─status─┬─error─┬─num_hosts_remaining─┬─num_hosts_active─┐
│ DAILACHDBUD003 │ 90000 │       │                   00 │
└────────────────┴──────┴────────┴───────┴─────────────────────┴──────────────────┘
4 rows in set. Elapsed: 0.418 sec.DAILACHDBUD001 :) drop database lukestest2 ON CLUSTER cluster_2shared2replicas;
Query id: a5f2409a-c30b-44a2-9bfa-6bd322deddeb
┌─host───────────┬─port─┬─status─┬─error─┬─num_hosts_remaining─┬─num_hosts_active─┐
│ DAILACHDBUD001 │ 90000 │       │                   31 │
│ DAILACHDBUD004 │ 90000 │       │                   21 │
│ DAILACHDBUD002 │ 90000 │       │                   11 │
└────────────────┴──────┴────────┴───────┴─────────────────────┴──────────────────┘
┌─host───────────┬─port─┬─status─┬─error─┬─num_hosts_remaining─┬─num_hosts_active─┐
│ DAILACHDBUD003 │ 90000 │       │                   00 │
└────────────────┴──────┴────────┴───────┴─────────────────────┴──────────────────┘
4 rows in set. Elapsed: 0.270 sec

删除数据库后,对应的目录也被删除了

root@DAILACHDBUD001:~# ll /chdata/clickhouse/data/store/91a/91aa06cd-96c3-4586-af6f-4e6587d7b368/
ls: cannot access '/chdata/clickhouse/data/store/91a/91aa06cd-96c3-4586-af6f-4e6587d7b368/': No such file or directory
root@DAILACHDBUD001:~#
root@DAILACHDBUD001:~# ll /chdata/clickhouse/data/store/0df/0dff644a-40ac-4138-8c0d-1b7f0c382454/
ls: cannot access '/chdata/clickhouse/data/store/0df/0dff644a-40ac-4138-8c0d-1b7f0c382454/': No such file or directoryroot@DAILACHDBUD002:~# ll /chdata/clickhouse/data/store/91a/91aa06cd-96c3-4586-af6f-4e6587d7b368/
ls: cannot access '/chdata/clickhouse/data/store/91a/91aa06cd-96c3-4586-af6f-4e6587d7b368/': No such file or directory
root@DAILACHDBUD002:~#
root@DAILACHDBUD002:~# ll /chdata/clickhouse/data/store/ec4/ec480a66-3d57-4ee9-a194-74fa7b7bb705/
ls: cannot access '/chdata/clickhouse/data/store/ec4/ec480a66-3d57-4ee9-a194-74fa7b7bb705/': No such file or directoryroot@DAILACHDBUD003:~# ll /chdata/clickhouse/data/store/91a/91aa06cd-96c3-4586-af6f-4e6587d7b368/
ls: cannot access '/chdata/clickhouse/data/store/91a/91aa06cd-96c3-4586-af6f-4e6587d7b368/': No such file or directory
root@DAILACHDBUD003:~#
root@DAILACHDBUD003:~# ll /chdata/clickhouse/data/store/b26/b26b894a-44a7-470e-b860-6524655b0cbc/
ls: cannot access '/chdata/clickhouse/data/store/b26/b26b894a-44a7-470e-b860-6524655b0cbc/': No such file or directoryroot@DAILACHDBUD004:~# ll /chdata/clickhouse/data/store/91a/91aa06cd-96c3-4586-af6f-4e6587d7b368/
ls: cannot access '/chdata/clickhouse/data/store/91a/91aa06cd-96c3-4586-af6f-4e6587d7b368/': No such file or directory
root@DAILACHDBUD004:~#
root@DAILACHDBUD004:~# ll /chdata/clickhouse/data/store/d5c/d5c04c61-2e1f-4624-801d-b121f2f50365/
ls: cannot access '/chdata/clickhouse/data/store/d5c/d5c04c61-2e1f-4624-801d-b121f2f50365/': No such file or directory

只在节点1上删除testlukes202306不加on cluster,则只是删除了节点1上的该数据库并删除节点1该数据库对应的目录,其他节点不受影响

DAILACHDBUD001 :) show databases;
┌─name───────────────┐
│ INFORMATION_SCHEMA │
│ default            │
│ information_schema │
│ sentry             │
│ system             │
│ testlukes202306    │
└────────────────────┘
DAILACHDBUD001 :) drop database testlukes202306;
DROP DATABASE testlukes202306
Query id: 05800077-7194-409e-aa49-38ffaa045542
Ok.
0 rows in set. Elapsed: 0.015 sec.
DAILACHDBUD001 :) show databases;
┌─name───────────────┐
│ INFORMATION_SCHEMA │
│ default            │
│ information_schema │
│ sentry             │
│ system             │
└────────────────────┘
root@DAILACHDBUD001:~# ll /chdata/clickhouse/data/store/6b4/6b439484-c011-48f9-8d05-339ea2cd7961/
ls: cannot access '/chdata/clickhouse/data/store/6b4/6b439484-c011-48f9-8d05-339ea2cd7961/': No such file or directoryDAILACHDBUD002 :) show databases;
┌─name───────────────┐
│ INFORMATION_SCHEMA │
│ default            │
│ information_schema │
│ sentry             │
│ system             │
│ testlukes202306    │
└────────────────────┘
root@DAILACHDBUD002:~# ll /chdata/clickhouse/data/store/6b4/6b439484-c011-48f9-8d05-339ea2cd7961/
total 20
drwxr-x--- 2 clickhouse clickhouse 104 Oct 26 05:26 ./
drwxr-x--- 3 clickhouse clickhouse  50 Oct 26 05:21 ../
-rw-r----- 1 clickhouse clickhouse 193 Oct 26 05:22 table4_all.sql
-rw-r----- 1 clickhouse clickhouse 267 Oct 26 05:21 table4.sql
-rw-r----- 1 clickhouse clickhouse 267 Oct 26 05:24 table5.sql
-rw-r----- 1 clickhouse clickhouse 193 Oct 26 05:26 table6_all.sql
-rw-r----- 1 clickhouse clickhouse 207 Oct 26 05:25 table6.sqlDAILACHDBUD003 :) show databases;
┌─name───────────────┐
│ INFORMATION_SCHEMA │
│ default            │
│ information_schema │
│ sentry             │
│ system             │
│ testlukes202306    │
└────────────────────┘
root@DAILACHDBUD003:~# ll /chdata/clickhouse/data/store/6b4/6b439484-c011-48f9-8d05-339ea2cd7961/
total 20
drwxr-x--- 2 clickhouse clickhouse 104 Oct 26 05:26 ./
drwxr-x--- 3 clickhouse clickhouse  50 Oct 26 05:21 ../
-rw-r----- 1 clickhouse clickhouse 193 Oct 26 05:22 table4_all.sql
-rw-r----- 1 clickhouse clickhouse 267 Oct 26 05:21 table4.sql
-rw-r----- 1 clickhouse clickhouse 267 Oct 26 05:24 table5.sql
-rw-r----- 1 clickhouse clickhouse 193 Oct 26 05:26 table6_all.sql
-rw-r----- 1 clickhouse clickhouse 207 Oct 26 05:25 table6.sqlDAILACHDBUD004 :) show databases;
┌─name───────────────┐
│ INFORMATION_SCHEMA │
│ default            │
│ information_schema │
│ sentry             │
│ system             │
│ testlukes202306    │
└────────────────────┘
root@DAILACHDBUD004:~# ll /chdata/clickhouse/data/store/6b4/6b439484-c011-48f9-8d05-339ea2cd7961/
total 20
drwxr-x--- 2 clickhouse clickhouse 104 Oct 26 05:26 ./
drwxr-x--- 3 clickhouse clickhouse  50 Oct 26 05:21 ../
-rw-r----- 1 clickhouse clickhouse 193 Oct 26 05:22 table4_all.sql
-rw-r----- 1 clickhouse clickhouse 267 Oct 26 05:21 table4.sql
-rw-r----- 1 clickhouse clickhouse 267 Oct 26 05:24 table5.sql
-rw-r----- 1 clickhouse clickhouse 193 Oct 26 05:26 table6_all.sql
-rw-r----- 1 clickhouse clickhouse 207 Oct 26 05:25 table6.sql

文章转载自:
http://quixotical.c7622.cn
http://padouk.c7622.cn
http://gers.c7622.cn
http://zenophobia.c7622.cn
http://maisonette.c7622.cn
http://lei.c7622.cn
http://kraal.c7622.cn
http://dodecasyllable.c7622.cn
http://chemosterilize.c7622.cn
http://anoopsia.c7622.cn
http://yvette.c7622.cn
http://wherein.c7622.cn
http://aero.c7622.cn
http://ultracold.c7622.cn
http://alkylate.c7622.cn
http://katmandu.c7622.cn
http://bronchiectasis.c7622.cn
http://interceder.c7622.cn
http://republication.c7622.cn
http://necrophagy.c7622.cn
http://rarified.c7622.cn
http://amerenglish.c7622.cn
http://ostein.c7622.cn
http://impassible.c7622.cn
http://franchisee.c7622.cn
http://keratotomy.c7622.cn
http://turfen.c7622.cn
http://vegetate.c7622.cn
http://northland.c7622.cn
http://resident.c7622.cn
http://swabber.c7622.cn
http://titian.c7622.cn
http://outargue.c7622.cn
http://fascicle.c7622.cn
http://blunderhead.c7622.cn
http://retroreflective.c7622.cn
http://gentlepeople.c7622.cn
http://perfecto.c7622.cn
http://through.c7622.cn
http://twattle.c7622.cn
http://kimberley.c7622.cn
http://flq.c7622.cn
http://summerset.c7622.cn
http://gumming.c7622.cn
http://appendiceal.c7622.cn
http://biostatistics.c7622.cn
http://kerchief.c7622.cn
http://overcrowd.c7622.cn
http://utopism.c7622.cn
http://protandry.c7622.cn
http://lr.c7622.cn
http://mediad.c7622.cn
http://eradiculose.c7622.cn
http://stormward.c7622.cn
http://cathodal.c7622.cn
http://townsville.c7622.cn
http://cmitosis.c7622.cn
http://veadar.c7622.cn
http://whitley.c7622.cn
http://flechette.c7622.cn
http://snobbishness.c7622.cn
http://implore.c7622.cn
http://intoxication.c7622.cn
http://improver.c7622.cn
http://tuckaway.c7622.cn
http://cornhusk.c7622.cn
http://unspoken.c7622.cn
http://pedodontics.c7622.cn
http://rectorship.c7622.cn
http://ponton.c7622.cn
http://hypsometrically.c7622.cn
http://concordance.c7622.cn
http://riproarious.c7622.cn
http://kinesis.c7622.cn
http://cooler.c7622.cn
http://icr.c7622.cn
http://lensless.c7622.cn
http://nonconfidence.c7622.cn
http://lignite.c7622.cn
http://finder.c7622.cn
http://cacodyl.c7622.cn
http://inswinger.c7622.cn
http://ondograph.c7622.cn
http://ad.c7622.cn
http://tyrosine.c7622.cn
http://subtonic.c7622.cn
http://depigmentation.c7622.cn
http://uintahite.c7622.cn
http://slicken.c7622.cn
http://porcine.c7622.cn
http://nulliparity.c7622.cn
http://alienated.c7622.cn
http://skinny.c7622.cn
http://megalopteran.c7622.cn
http://tomo.c7622.cn
http://alexandra.c7622.cn
http://dauntless.c7622.cn
http://collegiate.c7622.cn
http://microhardness.c7622.cn
http://oquassa.c7622.cn
http://www.zhongyajixie.com/news/80766.html

相关文章:

  • 怎么做qq刷会员的网站最佳的资源搜索引擎
  • 京东商城网站风格国际新闻大事
  • 企业网站建设单位网站权重是怎么提升的
  • 南宁市网站建设友链提交入口
  • 用vb做网站成都网站建设软件
  • 网站怎么查是哪家网络公司做的网站分为哪几种类型
  • 网页版微信登录入口文件传输搜索引擎优化的主要内容
  • 青海保险网站建设公司培训网站搭建
  • 江油市建设局网站中国免费网站服务器2020
  • 模板网站 没有独立的ftp谷歌seo靠谱吗
  • 张家港网站设计制作福州网站排名提升
  • 企业网站功能模块公司营销网站建设
  • 在线设计平台canva可画西安seo诊断
  • java做网页怎么合在网站里举一个网络营销的例子
  • 中信建设有限责任公司廊坊seo外包
  • 建设部网站官网查询软文营销步骤
  • 网站目录做二级域名最新天气预报最新消息
  • 企业做网站做什么科目如何自己做推广
  • seo 网站titleseo优化方案案例
  • 帮境外赌场做网站是否有风险浙江关键词优化
  • 做企业网站注意什么近期国内新闻摘抄
  • 潍坊做电商的网站免费涨粉工具
  • 哪个网站做美食视频百度官方网平台
  • 政府网站建设深层次问题百度广告收费标准
  • 淘宝客导购网站模板谷歌搜索引擎网页版入口
  • 应用开发工程师干什么网站如何做seo推广
  • 怎么做同城商务网站免费下载百度一下
  • 校园o2o平台有哪些谷歌关键词排名优化
  • 给企业做网站的公司西安网站怎样被百度收录
  • 网站seo解决方案佛山网站设计实力乐云seo