userland utilites for specific version use the current kernel API

Julian Elischer julian at freebsd.org
Sat Mar 12 08:00:13 UTC 2011


On 3/10/11 9:13 PM, Subbsd wrote:
> Hi.
>
> i have a server with FreeBSD-current (9) kernel and core system that
> runs a dozen JAIL-s - some of them is FreeBSD 8x environment , and
> part is surrounded on FreeBSD 7x.
> My question - despite on COMPAT_FREEBSD{4-7} in the kernel, utilities
> do not use those structures in the nucleus, which belong to their
> release. For example, the utility in
> jail shows:
>
> sockstat: struct xtcpcb size mismatch
> USER     COMMAND    PID   FD PROTO  LOCAL ADDRESS         FOREIGN ADDRESS
>
> The COMPAT_FREEBSD is not transparent for utilites? is it possible to
> have the newer kernel with the minimum of the system, but have JAIL
> with earlier versions of FreeBSD environments, where it will work
> sockstat (and perhaps some others)? Thanks
> _______________________________________________
> freebsd-hackers at freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe at freebsd.org"
>
yes there is a small set of system utilities for which this is true.
the answer is generally to compile up some staticly linked versions of 
those tools
and supply them in the jail as replacements for the standard ones.

a very quick way to do this is to use the ones in /rescue.
(note they are all the same binary, don't make multiple copies..)


More information about the freebsd-virtualization mailing list