<div dir="ltr">I spent some more time looking into this with another developer and I can see while running &quot;drbdsetup events2 r0&quot; that there is a quick blip when I add the drbd r0 resource to my pool as the log device:<div><br></div><div>change resource name:r0 role:Primary<br>change resource name:r0 role:Secondary<br></div><div><br></div><div>However, if I export and/or import the pool, the event never registers again.  When I write to a vdisk on this pool I can see the nr:11766480 dw:11766452 counts increase on the peer which leads me to believe blocks are being written, yet the state never changes.</div><div><br></div><div>I also tried to run dd to the &quot;peer&quot; side drbd device while the &quot;active&quot; side was writing data and found a message stating the peer may not become primary while the device is opened read-only in my syslog which doesn&#39;t make sense.  The device is being written to, so how is the block device state being tricked to thinking it is read only?</div><div><br></div><div>=========in the log from the node I&#39;m writing to the drbd resource</div><div>drbd r0 dccdx0: Preparing remote state change 892694821<br>drbd r0: State change failed: Peer may not become primary while device is opened read-only<br>kernel: [92771.927574] drbd r0 dccdx0: Aborting remote state change 892694821<br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Nov 14, 2019 at 10:39 AM Doug Cahill &lt;<a href="mailto:handruin@gmail.com">handruin@gmail.com</a>&gt; wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div dir="ltr"></div><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Nov 14, 2019 at 4:52 AM Roland Kammerer &lt;<a href="mailto:roland.kammerer@linbit.com" target="_blank">roland.kammerer@linbit.com</a>&gt; wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On Wed, Nov 13, 2019 at 03:08:37PM -0500, Doug Cahill wrote:<br>
&gt; I&#39;m configuring a two node setup with drbd 9.0.20-1 on CentOS 7<br>
&gt; (3.10.0-957.1.3.el7.x86_64) with a single resource backed by an SSDs.  I&#39;ve<br>
&gt; explicitly enabled auto-promote in my resource configuration to use this<br>
&gt; feature.<br>
&gt; <br>
&gt; The drbd device is being used in a single-primary configuration as a zpool<br>
&gt; SLOG device.  The zpool is only ever imported on one node at a time and the<br>
&gt; import is successful during cluster failover events between nodes.  I<br>
&gt; confirmed through zdb that the zpool includes the configured drbd device<br>
&gt; path.<br>
&gt; <br>
&gt; My concern is that the drbdadm status output shows the Role of the drbd<br>
&gt; resource as &quot;Secondary&quot; on both sides.  The documentations reads that the<br>
&gt; drbd resource will be auto promoted to primary when it is opened for<br>
&gt; writing.<br>
<br>
But also demoted when closed (don&#39;t know if this happens in your<br>
scenario).<br>
<br>
&gt; drbdadm status<br>
&gt; r0 role:Secondary<br>
&gt;   disk:UpToDate<br>
&gt;   dccdx0 role:Secondary<br>
&gt;     peer-disk:UpToDate<br>
<br>
Maybe it is closed and demoted again and you look at it at the wrong<br>
points in time? Better look into the syslog for role changes, or monitor<br>
with &quot;drbdsetup events2 r0&quot;. Do you see switches to Primary there?<br></blockquote><div><br></div><div>I checked the drbdadm status while my dd write session was in progress and I see no change from Secondary to Primary.   I also checked the stats under /sys/class and it looks the same.</div><div><br></div><div>cat /sys/kernel/debug/drbd/resources/r0/connections/dccdx0/0/proc_drbd<br> 0: cs:Established ro:Secondary/Secondary ds:UpToDate/UpToDate C r-----<br>    ns:3330728 nr:0 dw:20103080 dr:26292 al:131 bm:0 lo:0 pe:[0;0] ua:0 ap:[0;0] ep:1 wo:1 oos:0<br>        resync: used:0/61 hits:64 misses:4 starving:0 locked:0 changed:2<br>        act_log: used:0/1237 hits:28951 misses:536 starving:0 locked:0 changed:132<br>        blocked on activity log: 0/0/0</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<br>
Best, rck<br>
_______________________________________________<br>
Star us on GITHUB: <a href="https://github.com/LINBIT" rel="noreferrer" target="_blank">https://github.com/LINBIT</a><br>
drbd-user mailing list<br>
<a href="mailto:drbd-user@lists.linbit.com" target="_blank">drbd-user@lists.linbit.com</a><br>
<a href="https://lists.linbit.com/mailman/listinfo/drbd-user" rel="noreferrer" target="_blank">https://lists.linbit.com/mailman/listinfo/drbd-user</a><br>
</blockquote></div></div>
</blockquote></div>