[sheepdog] Call to sd_truncate()

Hadrien KOHL hadrien.kohl at gmail.com
Thu Dec 12 11:36:06 CET 2013


Hi,

Thanks, that's interesting. I don't have any component I can think of that
does this though.
Could it be possible that the kernel/filesystem of the host is doing it on
it's own?

Hadrien


2013/12/12 Liu Yuan <namei.unix at gmail.com>

> On Thu, Dec 12, 2013 at 11:16:58AM +0100, Hadrien KOHL wrote:
> > Hi,
> >
> > I have been running sheepdog on a cluster of three nodes for some time
> now.
> > I sometime experience errors on the guest and host sides.
> >
> > On the guest side I read:
> > [TIMESTAMP] Buffer I/O error on device vda1, logical block XXXXXX
> > ...
> > [TIMESTAMP] end_request: I/O error, dev vda, sector XXXXXX
> >
> > On the host side (qemu log) I read:
> > qemu-system-x86_64: shrinking is not supported
> >
> > If I'm not mistaken, this message is writen in the block/sheepdog.c file
> in
> > qemu:
> >
> > static int sd_truncate(BlockDriverState *bs, int64_t offset)
> > {
> >     BDRVSheepdogState *s = bs->opaque;
> >     int ret, fd;
> >     unsigned int datalen;
> >
> >     if (offset < s->inode.vdi_size) {
> >         error_report("shrinking is not supported");
> >         return -EINVAL;
> >     } else if (offset > SD_MAX_VDI_SIZE) {
> >         error_report("too big image size");
> >         return -EINVAL;
> >     }
> >
> >     fd = connect_to_sdog(s);
> >     if (fd < 0) {
> >         return fd;
> >     }
> > ...
> > }
> >
> > I tried to find the call graph for this function but I am no C/C++
> > developer.
> >
> > Anyone have had this problem?
> >
>
> This errors mean that someone is trying to resize the volume downwards
> while
> VM is running. This actually cause problems:
>
> - sheepdog dosesn't support resize the volume while VM is running
> - we don't support shrink of volume, meaning that you can only enlarge the
> volume
>   if you want to resize the volume
>
> Thanks
> Yuan
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.wpkg.org/pipermail/sheepdog/attachments/20131212/6d97de67/attachment-0004.html>


More information about the sheepdog mailing list