Note: "permalinks" may not be as permanent as we would like,
direct links of old sources may well be a few messages off.
Hallo Lars, Thanks for this reply, I got this thing working. Best Regards Lars Ellenberg wrote: > On Tue, Mar 18, 2008 at 06:58:18PM +0100, Emir Mahmutbegovic wrote: > >> Hallo, >> >> I am running one two node cluster with heartbeat 2.1.3 and drbd. I made >> update of drbd (from 8.2.4) to 8.2.5 version and since then i do find this >> in dmesg on both nodes (node with primary drbd does not print this out): >> >> drbd1: local disk flush failed with status -5 >> drbd1: local disk flush failed with status -5 >> drbd0: local disk flush failed with status -5 >> drbd1: local disk flush failed with status -5 >> drbd1: local disk flush failed with status -5 >> drbd1: local disk flush failed with status -5 >> drbd2: local disk flush failed with status -5 >> drbd1: local disk flush failed with status -5 >> drbd1: local disk flush failed with status -5 >> drbd1: local disk flush failed with status -5 >> drbd1: local disk flush failed with status -5 >> >> Could someone please tell me what does this error mean ? >> > > drbd 8.0.11 (and 8.2.5) uses barriers/flushes in certain places > to be able to work reliably even on io subsystems with volatile > - but flushable - caches. > > whether or not DRBD uses these features is decided by trying once, and > if that results in "sorry, I don't support that", never try again. > > on the way to 2.6.24, kernel.org did change the way how barriers and > flushes are handled, but forgot to properly pass the "not supported" > status back, returning a generic "IO error" instead (the -5 above). > > this was later fixed again, see below. > so please use a kernel that contains that fix, > or a kernel that does still use the old behaviour. > > commit cc66b4512cae8df4ed1635483210aabf7690ec27 > Author: Jens Axboe <jens.axboe at oracle.com> > Date: Tue Mar 4 11:47:46 2008 +0100 > > block: fix blkdev_issue_flush() not detecting and passing EOPNOTSUPP back > > This is important to eg dm, that tries to decide whether to stop using > barriers or not. > > Tested as working by Anders Henke <anders.henke at 1und1.de> > > Signed-off-by: Jens Axboe <jens.axboe at oracle.com> > > diff --git a/block/blk-barrier.c b/block/blk-barrier.c > index 6901eed..55c5f1f 100644 > --- a/block/blk-barrier.c > +++ b/block/blk-barrier.c > @@ -259,8 +259,11 @@ int blk_do_ordered(struct request_queue *q, struct request **rqp) > > static void bio_end_empty_barrier(struct bio *bio, int err) > { > - if (err) > + if (err) { > + if (err == -EOPNOTSUPP) > + set_bit(BIO_EOPNOTSUPP, &bio->bi_flags); > clear_bit(BIO_UPTODATE, &bio->bi_flags); > + } > > complete(bio->bi_private); > } > @@ -309,7 +312,9 @@ int blkdev_issue_flush(struct block_device *bdev, sector_t *error_sector) > *error_sector = bio->bi_sector; > > ret = 0; > - if (!bio_flagged(bio, BIO_UPTODATE)) > + if (bio_flagged(bio, BIO_EOPNOTSUPP)) > + ret = -EOPNOTSUPP; > + else if (!bio_flagged(bio, BIO_UPTODATE)) > ret = -EIO; > > bio_put(bio); > >