Bug 262301 - [ctl] Cannot "kldunload ctl"
Summary: [ctl] Cannot "kldunload ctl"
Status: New
Alias: None
Product: Base System
Classification: Unclassified
Component: kern (show other bugs)
Version: 13.0-STABLE
Hardware: Any Any
: --- Affects Many People
Assignee: freebsd-bugs (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-03-02 16:46 UTC by Alan Somers
Modified: 2023-11-03 15:25 UTC (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alan Somers freebsd_committer freebsd_triage 2022-03-02 16:46:19 UTC
The ctl module cannot be unloaded if ctld has ever started.  A simple "kldload ctl; kldunload ctl" works, but after starting ctld with "service ctld onestart", then the module cannot be unloaded.

somers@fbsd-head /u/h/somers> sudo kldunload ctl
kldunload: can't unload file: Device busy
somers@fbsd-head /u/h/somers [1]> dmesg | tail -n1
kldunload: attempt to unload file that was loaded by the kernel

This problem means that there's no way for ctl to handle SIGKILL except a reboot.  If you ever send SIGKILL to that process, it will stay in the process's pending list forever.