From owner-freebsd-jail@freebsd.org Sun Dec 13 16:16:59 2020 Return-Path: Delivered-To: freebsd-jail@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id C1C5B4BD72C; Sun, 13 Dec 2020 16:16:59 +0000 (UTC) (envelope-from kevans@freebsd.org) Received: from smtp.freebsd.org (smtp.freebsd.org [96.47.72.83]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "smtp.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Cv8mW55Nvz4c3G; Sun, 13 Dec 2020 16:16:59 +0000 (UTC) (envelope-from kevans@freebsd.org) Received: from mail-qk1-f178.google.com (mail-qk1-f178.google.com [209.85.222.178]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) (Authenticated sender: kevans) by smtp.freebsd.org (Postfix) with ESMTPSA id 9C7498AB8; Sun, 13 Dec 2020 16:16:59 +0000 (UTC) (envelope-from kevans@freebsd.org) Received: by mail-qk1-f178.google.com with SMTP id p14so4310275qke.6; Sun, 13 Dec 2020 08:16:59 -0800 (PST) X-Gm-Message-State: AOAM5313ohJflbWUANgMlhSvTha1S4HCTFmCb5by2qG4KB9vDEUiDRUp nX5uTO63GRGCYP6bOAes3r0uNLAIBBlVWO/yto4= X-Google-Smtp-Source: ABdhPJxb3kNtlshrSbcCHL9bvAKHqAQYIn1xu9q+1uf6mV6hngsghP6VDslUy3RlXS1h+xHbSh79C7zeN6nopRLDuTA= X-Received: by 2002:a05:620a:2010:: with SMTP id c16mr27280955qka.493.1607876219222; Sun, 13 Dec 2020 08:16:59 -0800 (PST) MIME-Version: 1.0 References: In-Reply-To: From: Kyle Evans Date: Sun, 13 Dec 2020 10:16:46 -0600 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: Questions about the output of jls To: mj-mailinglist@gmx.de Cc: FreeBSD Mailing List , freebsd-jail Content-Type: text/plain; charset="UTF-8" X-BeenThere: freebsd-jail@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: "Discussion about FreeBSD jail\(8\)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 13 Dec 2020 16:16:59 -0000 On Sun, Dec 13, 2020 at 10:04 AM wrote: > > Hi, > > I habe a current system, where i have current and 12.2-STABLE jails. Checking with jls, i get this output: > > root@fbsd13:~ # jls -h jid name ip4.addr host.hostname vnet osrelease path | column -t > jid name ip4.addr host.hostname vnet osrelease path > 8 j0 192.168.0.10 j0.local 2 13.0-CURRENT /jails/j0 > 10 j1 - j1.local 1 13.0-CURRENT /jails/j1 > 12 j2 - j2.local 1 13.0-CURRENT /jails/j2 > > the jails are running this versions: > > root@fbsd13:~ # jexec -l j0 freebsd-version -u > 12.2-STABLE > root@fbsd13:~ # jexec -l j1 freebsd-version -u > 13.0-CURRENT > root@fbsd13:~ # jexec -l j2 freebsd-version -u > 12.2-STABLE > > > What is "osrelease"? Looking at the name, i would have guessed, it is the > version of the freebsd userland, running in the jail. But it does't seem so. > j1 and j2 are VNET jails, so it seems the 1 in the vnet column signifies this, > j0 is a "standard" jail using the hosts network stack, so the 2 stands for standard? > Hi, osrelease is what the jail sees as kern.osrelease and uname -r (see: jail(8)) (i.e. kernel version); it's either specified during jail creation or inherited from the parent prison if none is specified. It looks like it's exporting a jailsys int for vnet, so these correspond to: JAIL_SYS_DISABLE=0 JAIL_SYS_NEW=1 JAIL_SYS_INHERIT=2 So 2 is 'use parent vnet', 1 is 'new one created' -- I don't see this described in either jls(1) or jail(8), it'd probably be nice if we translated jailsys ints into "new"/"inherit" since one specifies "new"/"inherit" for them during creation. Thanks, Kyle Evans