ユーザ用ツール

サイト用ツール


サイドバー



最近の更新



Tag Cloud

タグ#
6
10
1
3
1
2
17
7
1
1
6
12
4
1
2
205
1
6
2
7
14
5
1
27
3
3
1
6
1
1
42
1
3
3
1
1
1
1
1
1
24
46
7
9
10
5
10
3
3
2
8
2
2
6
5
1
1
4
9
4
3
3
2
1
8
2
4
1
5
27
2
12
2
3
1
1
2
2
1
1
1
4
3
2
4
2
2
1
1
2
1
2
1
2
1
27
2
1
2
2
2
1
1
2
3
14
5
8
1
1
2
12
1
5
1
2
7
1
1
1
1
1
8
1
5
2
1
1
1
3
3
10
1
2
1
1
7
3
1
10
1
1
4
1
2
1
2
7
2
2
3
1
1
3
1
2
1
2
2
2
1
2
3
1
2
3
4
1
3
1
3
3
2
1
1
7
1
3
3
1
1
1
1
5
1
33
2
1
2
1
2
2
3
1
1
1
3
1
2
1
1
1
3
1
1
1
2
4
2
1
1
1
3
1
2
4
2
1
2
1
2
1
1
2
1
1
1
2
1
1
2
01_linux:01_net:52_heartbeat_pacemaker_drbd

52 Heartbeat + Pacemaker + DRBD

host IP
nfs-110.0.0.31
nfs-210.0.0.32
               |
               | vip: 10.0.0.30
      +--------+--------+
      |                 |
      | eth0:10.0.0.31  | eth0:10.0.0.32
+-----+-----+     +-----+-----+
|   nfs-1   |     |   nfs-2   |
+-----+-----+     +-----+-----+

crm

property no-quorum-policy="ignore" \
    stonith-enabled="false" \
    crmd-transition-delay="2s"
rsc_defaults resource-stickiness="INFINITY" \
        migration-threshold="1"
primitive p_drbd_nfs ocf:linbit:drbd \
params drbd_resource="nfs" \
op monitor interval="30" role="Slave" timeout="60" \
op monitor interval="15" role="Master" timeout="60" \
op start interval="0" timeout="240" \
op stop interval="0" timeout="100"
ms ms_drbd_nfs p_drbd_nfs \
meta master-max="1" master-node-max="1" clone-max="2" \
clone-node-max="1" notify="true"
primitive p_lsb_nfsserver \
  lsb:nfs \
  op monitor interval="20s" timeout="60s"
primitive p_vip_nfs ocf:heartbeat:IPaddr2 \
  params ip="10.0.0.30" cidr_netmask="24" \
  op monitor interval="20" timeout="60"
primitive p_mount_nfs ocf:heartbeat:Filesystem \
  params device="/dev/drbd0" directory="/data"  fstype="xfs" \
  op monitor interval="40s" \
  op start interval="0" timeout="60s" \
  op stop interval="0" timeout="120s" \
  meta target-role="started"
primitive p_check_dummy ocf:heartbeat:Dummy \
    op start interval="0s" timeout="240s" on-fail="restart" \
    op monitor interval="20s" timeout="40s" on-fail="restart" \
    op stop interval="0s" timeout="240s" on-fail="block"
group group1 \
    p_mount_nfs \
    p_lsb_nfsserver \
    p_vip_nfs \
    p_check_dummy
location rsc_location1 group1 \
    rule 100: #uname eq nfs-1 \
    rule 200: #uname eq nfs-2
colocation rsc_colocation1 \
    inf: group1 ms_drbd_nfs:Master
order rsc_order1 \
    inf: ms_drbd_nfs:promote group1:start

DRBD確認

[root@fl8.jp ~]# /etc/init.d/drbd status
drbd driver loaded OK; device status:
version: 8.4.5 (api:1/proto:86-101)
GIT-hash: 1d360bde0e095d495786eaeb2a1ac76888e4db96 build by mockbuild@Build64R5, 2014-08-18 20:00:36
m:res     cs         ro                 ds                 p  mounted         fstype
0:zabbix  Connected  Primary/Secondary  UpToDate/UpToDate  C  /mnt/mysql      ext3
0:zabbix  Connected  Primary/Secondary  UpToDate/UpToDate  C  /var/lib/mysql  ext3
01_linux/01_net/52_heartbeat_pacemaker_drbd.txt · 最終更新: 2015/11/16 16:09 by matsui

Yesterday:1433 Today:009 Total:84739