Comment 148 for bug 1505564

Revision history for this message
Dan Streetman (ddstreet) wrote :

> Overall, as far as nova logs show, there is 0 write on the nbd device and very few reads (probably just the MBR ?).
> Could that still cause inflight I/O when qemu-nbd -d is ran ?

"very few" > 0
:-)

and it could be coming from elsewhere...but we don't need to account for where the IO is coming from, as the simple fact that it's there is enough. Also it's not just data IO, it's any "request", including metadata/control requests. Network-backed devices can disappear at any time, and the driver must be able to handle that. Spamming endless messages to the log isn't a good idea in that case.

To clarify the exact code in this situation:

while ((req = blk_fetch_request(q)) != NULL) {
...
  if (unlikely(!nbd->sock)) {
                        dev_err(disk_to_dev(nbd->disk), "Attempted send on closed socket\n");
...
                        continue;
         }

so, as soon as the connection (socket) is gone, there will be an "Attempted..." message printed for every request in the queue, as the queue is cleared.

> I'll happily test your kernel PPA, but as far as I can see, you don't mention where it actually is :)

ha, forgot to paste it in, sorry :-)

https://launchpad.net/~ddstreet/+archive/ubuntu/lp1505564