[DRBD-user] slab.c

Philipp Reisner philipp.reisner at linbit.com
Wed May 12 16:09:15 CEST 2004

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


On Wednesday 12 May 2004 14:51, Stephan Rattai wrote:
> Hi,
>
> I'm having a bit trouble with drbd-0.7_pre7.
>
> I'm testing with kernel 2.6.6 on a Dual PIII-800 with 512 Megs and a single
> Xeon 2,4G and 1Gig connected via Gbe.
>
> First Problem: I can create a filesystem on /dev/nb0 but when I try to
> mount it on the secondary node, mount whines about /dev/nb0 already being
> mounted or the mountpoint being in use which is definetely not the case.
> dmesg says
>
> drbd0: ASSERT( mdev->state == Primary )
> in /root/src/drbd-0.7_pre7/drbd/drbd_main.c:1134.
>
> /proc/drbd says:
>
> version: 0.7-pre7 (api:72/proto:72)
> 0: cs:Connected st:Secondary/Primary ld:Consistent
>     ns:258 nr:629686 dw:629945 dr:606 al:2 bm:2 lo:0 pe:0 ua:0
>
> when I strace the mount I get:
>
> mount("/dev/nb0", "/mnt/replika/", "ext2", MS_RDONLY|0xc0ed0000, 0x8085d80)
> = -1 EBUSY (Device or resource busy)
>
> I have absolutely no idea why. On the primary node everything works just
> fine.

Have a look at the first item in the Q&A at http://www.drbd.org/316.html

> The other problem is that the module seems to crash the machine when I try
> to reload it after it has been unloaded. After having unloaded the module I
> get:
>
> drbd0: short read expecting header on sock: r=-512
> drbd0: worker terminated
> drbd0: asender terminated
> drbd0: Connection lost.
> drbd0: receiver terminated
> drbd0: worker terminated
> drbd0: ASSERT( mdev->ee_vacant==0 )
> in /root/src/drbd-0.7_pre7/drbd/drbd_main.c:1417
> slab error in kmem_cache_destroy(): cache `drbd_ee_cache': Can't free all
> objects
> Call Trace:
>  [<c0147595>] kmem_cache_destroy+0xd5/0x120
>  [<e1108ab8>] drbd_destroy_mempools+0x58/0x90 [drbd]
>  [<e1115f15>] drbd_cleanup+0x215/0x4b5 [drbd]
>  [<c01383db>] sys_delete_module+0x15b/0x1b0
>  [<c015264e>] do_munmap+0x16e/0x1f0
>  [<c01062db>] syscall_call+0x7/0xb
>
> drbd: kmem_cache_destroy(drbd_ee_cache) FAILED
>

This is interesting! Only the assertion in drbd_main.c:1417 fires,
but not the ERR() statements above. Where is this ee ?

Could you please retry with this patch applied ?

RCS file: /var/lib/cvs/drbd/drbd/drbd/drbd_main.c,v
retrieving revision 1.73.2.171
diff -u -p -u -r1.73.2.171 drbd_main.c
--- drbd/drbd_main.c    12 May 2004 10:00:47 -0000      1.73.2.171
+++ drbd/drbd_main.c    12 May 2004 14:07:57 -0000
@@ -1417,6 +1417,7 @@ ONLY_IN_26(
                        if(rr) ERR("%d: %d EEs in read list found!\n",i,rr);

                        D_ASSERT(mdev->ee_vacant==0);
+                       D_ASSERT(list_empty(&mdev->data.work.q));

                        if (mdev->md_io_page)
                                __free_page(mdev->md_io_page);


If this new assertion triggers, then at least we know where this
missing ee is.

>
> When I try to reload I get:
>
[...]

Yes, this is a follow-up-bug, since we try to recreate that slab-cache...

-Philipp
-- 
: Dipl-Ing Philipp Reisner                      Tel +43-1-8178292-50 :
: LINBIT Information Technologies GmbH          Fax +43-1-8178292-82 :
: Schönbrunnerstr 244, 1120 Vienna, Austria    http://www.linbit.com :



More information about the drbd-user mailing list