一:为什么CDH?
二:CDH是什么?
三:CDH怎么操作?
1. 按照步骤
- 设置打开最大文件数。
- [root@123 ~]# vim /etc/security/limits.conf
* soft nofile 32728
* hard nofile 1024999
* soft nproc 65535
* hard nproc unlimited
* soft memlock unlimited
* hard memlock unlimited
- 设置swap空间
[root@123 ~]# echo "vm.swappiess = 10" >> /etc/sysctl.conf
[root@123 ~]# sysctl vm.swappiness=10
- 关闭大页面压缩
[root@123 ~]# echo never > /sys/kernel/mm/transparent_hugepage/enabled
[root@123 ~]# echo never > /sys/kernel/mm/transparent_hugepage/defrag
[root@123 ~]# echo never > /etc/rc.local
- yum安装依赖包
[root@123 ~]# wget http://www.percona.com/redir/downloads/Percona-XtraDB-Cluster/5.5.37- 25.10/RPM/rhel6/x86_64/Percona-XtraDB-Cluster-shared-55-5.5.37-25.10.756.el6.x86_64.rpm
[root@123 ~]# rpm -ivh Percona-XtraDB-Cluster-shared-55-5.5.37-25.10.756.el6.x86_64.rpm
- yum安装依赖包
[root@123 ~]# yum -y install chkconfig python bind-utils psmisc libxslt zlib sqlite cyrus-sasl-plain cyrus-sasl-gssapi fuse fuse-libs redhat-lsb postgresql* portmap mod_ssl openssl-devel python-psycopg2 MySQL-python python-devel telnet pcre-devel gcc gcc-c++
- 安装mysql
参考一下文档
https://blog.csdn.net/weixin_43446246/article/details/124673744?spm=1001.2014.3001.5501
启动mysql,调整参数。
- 拷贝mysql驱动,三台机器都需要。