作者: 弦乐之花 | 可以转载, 但必须以超链接形式标明文章原始出处和作者信息及版权声明
链接http://shiri512003.itpub.net/post/37713/499500
[@more@]1.版本确认
echo ocfs2-`uname -r`
2.下载版本
http://oss.oracle.com/projects/ocfs2-tools/files/RedHat/RHEL5/x86_64/1.4.4-1/
http://oss.oracle.com/projects/ocfs2/files/RedHat/RHEL5/x86_64/1.4.7-1/
3.安装
rpm -ivh *rpm
4.
命令行工具
/etc/init.d/o2cb
o2cb_ctl
ocfs2_hb_ctl
cluster配置:
/etc/ocfs2/cluster.conf
cluster:
node_count = 3
name = webcluster
node:
ip_port = 7777
ip_address = 192.168.0.107
number = 7
name = node7
cluster = webcluster
node:
ip_port = 7777
ip_address = 192.168.0.106
number = 6
name = node6
cluster = webcluster
node:
ip_port = 7777
ip_address = 192.168.0.110
number = 10
name = node10
cluster = webcluster
超时配置
service o2cb configure
Heartbeat Dead Threshold O2CB_HEARTBEAT_THRESHOLD = (((timeout in seconds) / 2) + 1)
Network Idle Timeout It defaults to 30000 ms
Network Keepalive Delay defaults to 2000 ms
Network Reconnect Delay defaults to 2000 ms
service o2cb status
Kernel Configuration
$ echo 1 > /proc/sys/kernel/panic_on_oops
$ echo 30 > /proc/sys/kernel/panic
kernel.panic_on_oops = 1
kernel.panic = 30
disable SELINUX and iptables
mkfs.ocfs2 -b 4K -M local --fs-features=nobackup-super,local,sparse,unwritten,inline-data -T mail -L /dataocfs /dev/vg_data/lv_binlog
tunefs.ocfs2 -Q "Label: %VnFeatures: %H %On" /dev/vg_data/lv_binlog
mount -o barrier=0,localflocks,noatime,datavolume,data=writeback /dev/vg_data/lv_binlog /dataocfs
来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/7591490/viewspace-1033119/ ,如需转载,请注明出处,否则将追究法律责任。