当前位置:网站首页>Linux system uninstall, install, upgrade, migrate clickHouse database
Linux system uninstall, install, upgrade, migrate clickHouse database
2022-08-02 09:55:00 【night rain】
1. View the clickhouse version
rpm -qa|grep clickhouse2. View clickhouse service
service clickhouse-server status3. Close the clickhouse service
sudo service clickhouse-server stop//or simply end the processps -ef|grep clickkill -9 process code4. Uninstall clickhouse
yum remove -y clickhouse-common-staticyum remove -y clickhouse-server-commonrm -rf /var/lib/clickhouserm -rf /etc/clickhouse-*rm -rf /var/log/clickhouse-server5. Install clickhouse
Download three clickHouse files
Select the same version for three files, and versions below 21 may not be supportedclickhouse window function, I chose version 21.3.4.25
//Install clickhouse components in orderrpm -ivh clickhouse-common-static-21.3.4.25-2.x86_64.rpmrpm -ivh clickhouse-server-21.3.4.25-2.noarch.rpmrpm -ivh clickhouse-client-21.3.4.25-2.noarch.rpmModify config and users configuration


Modify the configuration vim /etc/clickhouse-server/config.xml Change to the location where data is stored after this line/var/lib/clickhouse/ Modify the configuration vim /etc/clickhouse-server/users.xml database username and passworddefault default default 6. Start the clickhouse service
sudo service clickhouse-server start7. Migrate clickhouse data

First check where the clickhouse data existscat /etc/clickhouse-server/config.xmlView The path after this lineThe path defaults to /var/lib/clickhouseCompress data, metadata, store folder data (data: database name, metadata: database table sql, store: data)tar -zcvf filenametar -xvf filename.gazUnzip and overwrite the three files in the /var/lib/clickhouse path of clickhouse in the new serverstart clickhouse servicesudo service clickhouse-server startNext, let's connect and test itUninstalling, installing, upgrading, and migrating the clickHouse database have all been explained here!
If the article is wrong or in doubt, please leave a message to discuss~
边栏推荐
猜你喜欢

HCIA动态主机配置协议实验(dhcp)

瑞萨RZ/G2L处理器详细测评

Facebook's automated data analysis solution saves worry and effort in advertising

瑞吉外卖项目剩余功能补充

堪称神级的阿里巴巴“高并发”教程《基础+实战+源码+面试+架构》

每天花2小时恶补腾讯T8纯手打688页SSM框架和Redis,成功上岸美团

从零开始入门单片机(一):必会背景知识总结

高效时代,电商运营如何靠RPA快速提效?

Nodejs3day(express简介,express创建基本Web服务器,托管静态资源,nodemon下载及出现的问题,中间件,编写GET,POST,JSONP接口)

Spend 2 hours a day to make up for Tencent T8, play 688 pages of SSM framework and Redis, and successfully land on Meituan
随机推荐
Chapter 15 Generics
【并发编程】- 线程池使用DiscardOldestPolicy策略、DiscardPolicy策略
cococreator dynamically set sprite
图形化矩阵,矩阵到底长什么样?
R语言ggplot2可视化:使用ggpubr包的ggtexttable函数可视化表格数据(直接绘制表格图或者在图像中添加表格数据)、使用tbody_add_border为表格中的表头添加外侧框线
练习16-两道模拟题
【Redis】通用命令
CFdiv2-The Number of Imposters-(两种点集图上染色问题总结)
R语言ggplot2可视化:使用ggpubr包的ggbarplot函数可视化水平柱状图(条形图)、使用orientation参数设置柱状图转置为条形图
转转反爬攻防战
智能网络安全网卡|这是不是你要的安全感
Re22:读论文 HetSANN An Attention-based Graph Neural Network for Heterogeneous Structural Learning
mysql连接池的实现
堪称神级的阿里巴巴“高并发”教程《基础+实战+源码+面试+架构》
leetcode 62. Unique Paths(独特的路径)
8月份的.NET Conf 活动 专注于 .NET MAUI
Redis数据结构
Naive Bayesian Method of Li Hang's "Statistical Learning Methods" Notes
The 17th day of the special assault version of the sword offer
向量点积(Dot Product),向量叉积(Cross Product)