Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

after exiting, lsblk still shows /dev/nbd0 #29

Open
MagicJoeZ opened this issue Oct 16, 2018 · 1 comment
Open

after exiting, lsblk still shows /dev/nbd0 #29

MagicJoeZ opened this issue Oct 16, 2018 · 1 comment

Comments

@MagicJoeZ
Copy link

Hey,
I recently ran into an incident. I ran
./loopback /dev/loop0 /dev/nbd0.
Then I ran lsblk. It shows:
nbd0 43:0 0 30M 0 disk
Then I
mount /dev/nbd0 /mnt
I wrote some files on /mnt.
Then I
umount -l /mnt
Then I use ctr + C to terminate ./loopback. I lsblk again, it still shows:
nbd0 43:0 0 30M 0 disk
However, /dev/nbd0 should not appear on lsblk at this moment.
Is this a bug or I should not use lazy umount?

@SupraSummus
Copy link
Contributor

It looks like a bug to me although I couldn't reproduce it (tried with kernel 4.18.14). So I got few questions to help me debug this:

  • Which kernel version are you using?
  • Are there related messages in kernel log?
  • What is the result of running nbd-client -c /dev/nbd0 on a "zombie" blockdev (output and exit status)?
  • Does requesting disconnect manually by nbd-client -d /dev/nbd0 fix "zombie" blockdev?

I remember I had issues with terminating BUSE once (some time ago, now they are gone). It occurred randomly, so I suspect race condition. I wrote a fix for this - check it out and try if you want. Rev 3d5ca36 (not merged into master)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants