Dear all,
Any idea for this ?
regards,
Edward
From: guohuai...@hotmail.com
To: james.mas...@tradefair.com; drbd-user@lists.linbit.com;
guohuailee0...@gmail.com; lichangl...@hisense.com
Subject: allow doubal primary and the notice
Date: Wed, 9 Dec 2009 09:00:35 +0800
Dear all,
sometimes, I found "drbdadm secondary resource" blocks or does not works.
For example, when the primary "Diskless", "drbdadm secondary resource" will not
works.
So, the standby can't become DRBD primary.
I spent several hours to solve this problem.
At last, I think "allow-two-primaries", it may work around for the "drbdadm
secondary resource".
In this solution, the DRBD block device works like a shared disk with network
raid1.
And the heartbeat will control which machine will become primary.
Only the primary machine will mount the block device of DRBD, so only the
primary machine will access
the data in DRBD block device(exclude manually mount the block device on the
secondary machine).
I think this is a good idea.
Would you help to give me suggestion for this idea ? Does it has any problem
or potential risk ?
Also, I found the comments below for "allow-two-primaries".
And the file system I used is ext2 or ext3 of linux.
I don't know why ext2 or ext3 filesystem must not use "allow-two-primaries".
Although, it has no distributed lock manager like GFS to control concurrent
access to the data.
But, I used heartbeat(2.1.3) and DRBD8.3.0 together, and heartbeat will control
and make Only
the primary machine will mount the block device of DRBD.
So, if no one hostility or make mistake to mount the DRBD block device on the
secondary machine,
concurrent access will not happen.
Your suggestion is highly appreciated.
:-)
best wishes,
Edward
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
In dual-primary mode, any resource is, at any given time, in the primary role
on both cluster nodes.
Since concurrent access to the data is thus possible, this mode requires the
use of a shared cluster file system that utilizes
a distributed lock manager. Examples include GFS and OCFS2.
++++++++++++++++++++++++++++++++++++++++++++
# The highest number of data blocks between two write barriers.
# If you set this < 10 you might decrease your performance.
# max-epoch-size 2048;
# if some block send times out this many times, the peer is
# considered dead, even if it still answers ping requests.
# ko-count 4;
# If you want to use OCFS2/openGFS on top of DRBD enable
# this optione, and only enable it if you are going to use
# one of these filesystems. Do not enable it for ext2,
# ext3,reiserFS,XFS,JFS etc...
allow-two-primaries;
From: guohuai...@hotmail.com
To: james.mas...@tradefair.com; drbd-user@lists.linbit.com;
guohuailee0...@gmail.com; guohuai...@hotmail.com
Subject: how to make the resource secondary mandatorily
Date: Fri, 4 Dec 2009 12:20:52 +0800
Dear all,
Would you help to tell me how to make the resource secondary mandatorily ?
Now I use DRBD8.3.0.
And the primary node is diskless, so I "umount /dev/drbd0" and try to issue
command
"drbdadm secondary r0" to make the resource secondary.
But it not works, the detail info is like below.
I suggest DRBD provide a command to make the resource secondary mandatorilly,
especially while "Diskless".
Maybe I didn't know such command.
thanks for your help,
Regards,
Edward
+++++++++++++++++++++++++++++++++++
linux-10:~ # drbdadm secondary r0
unlink: Read-only file system
open(/var/lock/drbd-147-0): Read-only file system
Command 'drbdsetup /dev/drbd0 secondary' terminated with exit code 20
drbdadm secondary r0: exited with code 20
linux-10:~ # cat /proc/drbd
version: 8.3.0 (api:88/proto:86-89)
GIT-hash: 9ba8b93e24d842f0dd3fb1f9b90e8348ddb95829 build by r...@linux-10,
2009-02-18 16:33:17
0: cs:Connected ro:Primary/Secondary ds:Diskless/UpToDate C r---
ns:7924 nr:0 dw:3304 dr:321 al:16 bm:0 lo:0 pe:0 ua:0 ap:0 ep:1 wo:b oos:0
1: cs:Connected ro:Primary/Secondary ds:UpToDate/UpToDate C r---
ns:0 nr:0 dw:0 dr:0 al:0 bm:0 lo:0 pe:0 ua:0 ap:0 ep:1 wo:b oos:0
2: cs:Connected ro:Primary/Secondary ds:UpToDate/UpToDate C r---
ns:0 nr:0 dw:0 dr:0 al:0 bm:0 lo:0 pe:0 ua:0 ap:0 ep:1 wo:b oos:0
linux-10:~ #
Windows Live Hotmail: Your friends can get your Facebook updates, right from
HotmailĀ®.
Windows Live: Keep your friends up to date with what you do online.
_________________________________________________________________
Windows Live: Friends get your Flickr, Yelp, and Digg updates when they e-mail
you.
http://www.microsoft.com/middleeast/windows/windowslive/see-it-in-action/social-network-basics.aspx?ocid=PID23461::T:WLMTAGL:ON:WL:en-xm:SI_SB_3:092010
_______________________________________________
drbd-user mailing list
drbd-user@lists.linbit.com
http://lists.linbit.com/mailman/listinfo/drbd-user