https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=224479

--- Comment #15 from Andriy Gapon <a...@freebsd.org> ---
(In reply to Konstantin Belousov from comment #14)
On the other hand, if the kernel knows that a vnode is used for swap and the
kernel knows that the force reclaim of that vnode will lead to a panic, then
why should the kernel allow that?

I see several possibilities, but not sure if any of them makes sense from the
FreeBSD architecture and design point of view.

1. When vgone-ing the swap vnode somehow perform an equivalent of swap off on
it.

2. Do not allow even the force unmount of a filesystem if there is a vnode used
for swap.

3. "Orphan" the swap vnode such that it is removed from its mount list, the
name cache, etc, but it is still alive and is owned by the swap pager. I feel
that this is impossible to do, however.

Also, I am not sure about any "race", but it seems that during a shutdown we
should first turn off all the file-backed swap and only then start unmounting
filesystems.  From comment #0 it seems that we do not follow this order.

-- 
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
freebsd-bugs@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-bugs
To unsubscribe, send any mail to "freebsd-bugs-unsubscr...@freebsd.org"

Reply via email to