After a low-level-tricky configuration update, I want to force
nfssrv kernel module to fully reload, as if the server just booted.
The obvious solution that I used on the pre-prod server is to reboot but bare-metal is slow to reboot and it introduces a couple of minutes of full service downtime which I want to minimize.
I tried to just restart the underlying service via
svcadm restart nfs/server but it does not reset the internal kernel module state.
I tried to
modunload -i <module id> but it exits with:
can't unload the module: Device busy
Shutting down all shares, all zfs exports and even zfs driver did not seem to help and I have no clue what makes it "busy" ?
Is there any way I can reset the driver with minimal downtime ? A couple of seconds would be perfectly acceptable.