hana集群配置

本文档详细介绍了在Linux环境下配置HANA集群的步骤,包括主机名配置、SSH互信设置以及多路径配置。首先,通过编辑/etc/hosts文件确保主机间通信,然后通过ssh-keygen和authorized_keys实现节点间的免密登录。接着,配置多路径设备,包括安装相关软件包、创建配置文件multipath.conf,并检查多路径状态。最后,涉及Ocfs2的配置,包括安装相关软件、配置节点和文件系统,确保集群服务正常运行。
摘要由CSDN通过智能技术生成

1.1 配置主机名
分别在四个节点(linux001 linux002 linux003 linux004)上编辑/etc/hosts文件【每个节点内容一致】
1: [root@linux001 ~]# vi /etc/hosts
2: # Do not remove the following line, or various programs
3: # that require network functionality will fail.
4: 127.0.0.1 linux001 localhost.localdomain localhost
5: ::1 localhost6.localdomain6 localhost6i 172.23.176.103 linux001
6: 172.23.176.101 linux002
7: 172.23.176.104 linux003
8: 172.23.176.102 linux004
其中172.23.176.103 linux001;127.23.176.101 linux002;127.23.176.104 linux003;127.23.176.102 linux004.为所添加的内容,在每天服务器上执行同样的操作。编辑完以后安装Esc键后按shift +:建后输入wq!保存退出。
1.2配置ssh互信
以linux001和linux002为例。首先配置linux002免密码登录linux001.在linux001上执行:
1: [root@linux001]$ >ssh-keygen -t dsa
2: Generating public/private dsa key pair.
3: Enter file in which to save the key (/home/oracle/.ssh/id_dsa):
4: Created directory ‘/home/oracle/.ssh’.
5: Enter passphrase (empty for no passphrase):
6: Enter same passphrase again:
7: Your identification has been saved in /home/oracle/.ssh/id_dsa.
8: Your public key has been saved in /home/oracle/.ssh/id_dsa.pub.
9: [root@linux001]>cd /root/.ssh
10: [root@linux001]>mv id_dsa.pub linux001.pub
11: [root@linux001]>scp linux001.pub root@linux002:/root/.ssh
12: 在linux002上执行
13: [root@linux002]> cd /root/.ssh
14: [root@linux002]cat linux001.pub >> authorized_keys
15: [root@linux002]chmod 600 authorized_keys
16: [root@linux002]cd …
17: [root@linux002] chmod 700 .ssh
配置linux001免密码登录linux002,在linux002上执行:
1: [root@linux002]$ >ssh-keygen -t dsa
2: Generating public/private dsa key pair.
3: Enter file in which to save the key (/home/oracle/.ssh/id_dsa):
4: Created directory ‘/home/oracle/.ssh’.
5: Enter passphrase (empty for no passphrase):
6: Enter same passphrase again:
7: Your identification has been saved in /home/oracle/.ssh/id_dsa.
8: Your public key has been saved in /home/oracle/.ssh/id_dsa.pub.
9: [root@linux002]>cd /root/.ssh
10: [root@linux002]>mv id_dsa.pub linux001.pub
11: [root@linux002]>scp linux001.pub root@linux001:/root/.ssh
在linux001上执行
1: [root@linux001]> cd /root/.ssh
2: [root@linux001]cat linux001.pub >> authorized_keys
3: [root@linux001]chmod 600 authorized_keys
4: [root@linux002]cd …
5: [root@linux001] chmod 700 .ssh
其它机器linux001和linux003相互之间,linux001和linux004相互之间,linux002和linux004相互之间,linux002和linux003相互之间,linux003和linux004相互之间配置方法以此类似(一共需要配置12次)。
2 多路径配置
2.1 相关软件包
所需相关软件包
device-mapper-1.02.13-6.9.i586.rpm

该软件运行在底层,主要进行设备虚拟化和映射。

multipath-tools-0.4.7-34.18.i586.rpm,这个软件包可以在

多路径的管理和监控工具,主要进行路径状态的检测,管理工作

查看软件是否安装,如果没有则安装。(所有4台机器上操作)
[root@linux001] rpm -qa | grep device-mapper(查看device-mapper是否安装,如果没有任何提示,则通过zypper install 软件名安装)

[root@linux001] rpm -qa | grep multipath-tool(查看device-mapper是否安装,如果没有任何提示,则通过zypper install 软件名安装)

安装命令:
[root@linux001] zypper install device-mapper

[root@linux001] zypper install multipath

  • 0
    点赞
  • 3
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值