[DRBD-user] [DRBD9] DRBD client and dual-primary mode

Hiroshi Fujishima h-fujishima at sakura.ad.jp
Fri Nov 6 13:06:48 CET 2015

Note: "permalinks" may not be as permanent as we would like,
direct links of old sources may well be a few messages off.


Hi,

I found the follwing promblem.

- enable dual-primary mode.
- issue IO by DRBD client node and another Primary node.
- DRBD client IO stall.
- rebooting DRBD client node does not solve problem.

the detail instruction is below.

[root at drbd0 ~]# drbdmanage list-nodes
+------------------------------------------------------------------------------+
| Name  | Pool Size | Pool Free | Site |                          |      State |
|------------------------------------------------------------------------------|
| drbd0 |   unknown |   unknown |  N/A |                          | no storage |
| drbd1 |     20476 |     20468 |  N/A |                          |         ok |
| drbd2 |     20476 |     20468 |  N/A |                          |         ok |
+------------------------------------------------------------------------------+
[root at drbd0 ~]# drbdmanage list-assignments
No assignments defined
[root at drbd0 ~]# drbdmanage add-volume test 100mb --deploy 2
Operation completed successfully
Operation completed successfully
[root at drbd0 ~]# drbdmanage list-assignments
+------------------------------------------------------------------------------+
| Node  | Resource | Vol ID |                                          | State |
|------------------------------------------------------------------------------|
| drbd1 | test     |      * |                                          |    ok |
| drbd2 | test     |      * |                                          |    ok |
+------------------------------------------------------------------------------+
[root at drbd0 ~]# drbdmanage assign-resource --client test drbd0
Operation completed successfully
[root at drbd0 ~]# drbdmanage list-assignments
+------------------------------------------------------------------------------+
| Node  | Resource | Vol ID |                                         |  State |
|------------------------------------------------------------------------------|
| drbd0 | test     |      * |                                         | client |
| drbd1 | test     |      * |                                         |     ok |
| drbd2 | test     |      * |                                         |     ok |
+------------------------------------------------------------------------------+
[root at drbd0 ~]# drbdmanage net-options --allow-two-primaries y --resource test

Issuing IO on drbd0 (DRBD client).

[root at drbd0 ~]# fio --name=test --filename=/dev/drbd/by-res/test/0 --direct=1 --rw=randwrite --time_based --runtime=1d

Issuing IO on drbd1 (not DRBD client).

[root at drbd1 ~]# fio --name=test --filename=/dev/drbd/by-res/test/0 --direct=1 --rw=randwrite --time_based --runtime=1d

In this timing, drbd0's IO stall.
it can't kill fio process on drbd0.

[root at drbd0 ~]# ps ax | grep '[f]io'
 3110 ?        Ds     0:00 fio --name=test --filename=/dev/drbd/by-res/test/0 --direct=1 --rw=randwrite --time_based --runtime=1d
[root at drbd0 ~]# kill -9 3110
[root at drbd0 ~]# ps ax | grep '[f]io'
 3110 ?        Ds     0:00 fio --name=test --filename=/dev/drbd/by-res/test/0 --direct=1 --rw=randwrite --time_based --runtime=1d

Killing fio process runnning on drbd1 and rebooting drbd0.

[root at drbd1 ~]# fio --name=test --filename=/dev/drbd/by-res/test/0 --direct=1 --rw=randwrite --time_based --runtime=1d
^C
[root at drbd0 ~]# reboot -f

Issuning IO on drbd0 stall.
(drbd1/drbd2 is Secondary/Secondary)

[root at drbd0 ~]# systemctl start drbd.service
[root at drbd0 ~]# drbd-overview
  0:.drbdctrl/0  Connected(3*) Secondary(3*) UpTo(drbd0)/UpTo(drbd1,drbd2)
  1:.drbdctrl/1  Connected(3*) Secondary(3*) UpTo(drbd0)/UpTo(drbd1,drbd2)
100:test/0       Connected(3*) Secondary(3*) Disk(drbd0)/UpTo(drbd1,drbd2)
[root at drbd0 ~]# fio --name=test --filename=/dev/drbd/by-res/test/0 --direct=1 --rw=randwrite
=> stall

Regards.

-- 
Hiroshi Fujishima
-------------- next part --------------
A non-text attachment was scrubbed...
Name: drbd0.log.gz
Type: application/octet-stream
Size: 18958 bytes
Desc: not available
URL: <http://lists.linbit.com/pipermail/drbd-user/attachments/20151106/db28f40a/attachment.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: drbd1.log.gz
Type: application/octet-stream
Size: 4386 bytes
Desc: not available
URL: <http://lists.linbit.com/pipermail/drbd-user/attachments/20151106/db28f40a/attachment-0001.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: drbd2.log.gz
Type: application/octet-stream
Size: 4355 bytes
Desc: not available
URL: <http://lists.linbit.com/pipermail/drbd-user/attachments/20151106/db28f40a/attachment-0002.obj>


More information about the drbd-user mailing list