Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 14 Nov 2017 10:52:55 +0100
From:      Harry Schmalzbauer <freebsd@omnilan.de>
To:        freebsd-net@freebsd.org
Subject:   userland shutdown(2)?
Message-ID:  <5A0ABCF7.6080606@omnilan.de>

next in thread | raw e-mail | index | archive | help
 Hello,

stoping jails leaves open sockets with no process attached.
(sockstat shows like this line:
?        ?          ?     ?  tcp6   2001:db8::fedc:389 2001:db8::abcd:15666
)

Since I make use of mount lines in jail.conf,
umounting the root filesystem of the jail fails because "device busy".
To avoid dirty filesystems after reboot of the host,
my modified rc.d/jail updates the corresponding filesystem
to be mounted readonly, but that's not a great solution.

I'd like to get all sockets killed before jail vanishes.

There's shutdown(2), which seems to do exactly what I want,
but where/how to implement?
Is there any userland tool utilizing shutdown(2)?

Thanks,

-Harry



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?5A0ABCF7.6080606>