Ringkasan DRBD


vim /etc/drbd.conf

global {
dialog-refresh 1;
usage-count yes;
minor-count 5;
}
common {
syncer {
rate 10M;
}
}
resource r0 {
protocol C;
disk {
on-io-error detach;
}
syncer {
rate 10M;
al-extents 257;
}
on echo {
device /dev/drbd0;
address 192.168.1.235:7788;
meta-disk internal;
disk /dev/sdb;
}
on fanta {
device /dev/drbd0;
address 192.168.1.236:7788;
meta-disk internal;
disk /dev/sdb;
}
}

fanta:/etc/ha.d # vim haresources
echo IPaddr::192.168.1.243/24/eth0 drbddisk::r0 Filesystem::/dev/drbd0::/srv::ext3 apache2

fanta:/etc/ha.d # vim ha.cf

keepalive 2
warntime 5
deadtime 15
initdead 90
udpport 694
auto_failback on
bcast eth0
logfile /var/log/ha-log
node echo fanta

fanta:/etc/ha.d # vim authkeys
auth 2
2 crc

fanta:/etc/ha.d # chmod 600 ha.cf

vim /etc/hosts
127.0.0.2 fanta.example.com fanta
192.168.1.236 fanta.example.com fanta

fanta:/etc/ha.d # /etc/init.d/heartbeat (start on server fanta and echo)

fanta:/etc/ha.d # drbdadm create-md r0

fanta:/etc/ha.d # /etc/init.d/drbd status

golf IPaddr::192.168.1.244/24/eth0 drbddisk::r0 Filesystem::/dev/drbd0::/srv::ext3 apache2 smb mysql

mv /var/lib/mysql /srv/
ln -sf /srv/mysql /var/lib/mysql

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

shisdew

Listens until think alike

moses.spaceku@yahoo.com / voip ipbx

Hosted PBX, IP-PBX SOHO/ CALL CENTER, VOICE GATEWAY, VOICE CARD, COST EFECTIVE SOLUTIONS (LCR), GSM/CDMA GATEWAY

%d bloggers like this: