[Bug 1743026] Re: qemu-nbd -c /dev/nbd0 fails to map partitions
** Tags added: cscc -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1743026 Title: qemu-nbd -c /dev/nbd0 fails to map partitions To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1743026/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1743026] Re: qemu-nbd -c /dev/nbd0 fails to map partitions
there is a way to workaround it, use partprobe it is the original solution: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=824553 ** Bug watch added: Debian Bug tracker #824553 https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=824553 -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1743026 Title: qemu-nbd -c /dev/nbd0 fails to map partitions To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1743026/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1743026] Re: qemu-nbd -c /dev/nbd0 fails to map partitions
is there a way to workaround this problems? -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1743026 Title: qemu-nbd -c /dev/nbd0 fails to map partitions To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1743026/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1743026] Re: qemu-nbd -c /dev/nbd0 fails to map partitions
Just a note the patch in #2 is most likely not correct, just a way for me to narrow down the problem. Perhaps we missed a patch (or there is a fix) that makes nbd_is_connected to the correct thing. -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1743026 Title: qemu-nbd -c /dev/nbd0 fails to map partitions To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1743026/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1743026] Re: qemu-nbd -c /dev/nbd0 fails to map partitions
** Changed in: linux (Ubuntu) Importance: Undecided => High ** Changed in: linux (Ubuntu Xenial) Importance: Undecided => High ** Changed in: linux (Ubuntu Xenial) Status: Incomplete => Triaged ** Changed in: linux (Ubuntu) Status: Incomplete => Triaged ** Tags added: kernel-da-key -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1743026 Title: qemu-nbd -c /dev/nbd0 fails to map partitions To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1743026/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1743026] Re: qemu-nbd -c /dev/nbd0 fails to map partitions
This patch seems to fix the issue: ``` diff --git a/drivers/block/nbd.c b/drivers/block/nbd.c index 5f807a6..b761971 100644 --- a/drivers/block/nbd.c +++ b/drivers/block/nbd.c @@ -98,11 +98,6 @@ static inline struct device *nbd_to_dev(struct nbd_device *nbd) return disk_to_dev(nbd->disk); } -static bool nbd_is_connected(struct nbd_device *nbd) -{ - return !!nbd->task_recv; -} - static const char *nbdcmd_to_ascii(int cmd) { switch (cmd) { @@ -126,9 +121,6 @@ static int nbd_size_clear(struct nbd_device *nbd, struct block_device *bdev) static void nbd_size_update(struct nbd_device *nbd, struct block_device *bdev) { - if (!nbd_is_connected(nbd)) - return; - bdev->bd_inode->i_size = nbd->bytesize; set_capacity(nbd->disk, nbd->bytesize >> 9); kobject_uevent(_to_dev(nbd)->kobj, KOBJ_CHANGE); ``` -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1743026 Title: qemu-nbd -c /dev/nbd0 fails to map partitions To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1743026/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs