From nobody Fri Apr 18 10:47:01 2025 X-Original-To: dev-commits-doc-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4ZfBKL05cHz5sb9m for ; Fri, 18 Apr 2025 10:47:02 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (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 "mxrelay.nyi.freebsd.org", Issuer "R10" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4ZfBKK6cDMz3sbb; Fri, 18 Apr 2025 10:47:01 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1744973222; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=rWns0+eDwC9QVYBODzZAaeZ2nr3J05qvlAY1f7M2w6E=; b=cEPGIdfqQxydWFnQ5v6Qhj1a7JCcnu72ReJCoo0rXCVjzuZrO0Tr8PJ7Ftx5aw0wPOw9an PfrJL2sOLx8sxLXuKQQuk5SvfM6t2Y6bVPgxsd/tOapY0Y7uxMoQN5/7tq+y/b9fq2jytY bW7FfRqrgexxrajOEIabWc0J0pCPOCqw4thKUIRanA+P837AIGPwi2x1Zdsepmhx/TvnMm 5hKgfkKZvRiwl0qAyH1/q4lJ9saeU+z3b4PVeLjU6Cvmm6332YEMvuoNIWmZuAm8iFpC5J 2P8UCeXgOkjHu7/yzUHLG3FDKoWrK9m/tOvAfuXRcqJ+oHIBkMr/HPsrbNuOAw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1744973221; a=rsa-sha256; cv=none; b=cKXQQF7USOZT5JPFeeKMEoasXqKNsRVnmOh1rNrKG20EyJyqbKxTtkO+Ym/oJmCFS+Hzjg fbSYme8i9wjkHYidkkvXdOpdlIRTqX4d05TcoXAG/nX9c0mfFfkO4LEPh2R6KEi5sbFXQx W6uupJjYQGfbBGN7hNRaSSAHx/fqFqTrr7HdOdgs4Uk0rUC8nI4ZkeAfDtUrZwnolD8vOD rrh/i7geLJB2eNqZLudHmqTaqRGX8yfrcYofYIJqBUJPcp1lvd9+iSfmVOF88yCm6eBjpu z40uU0i/4fVEsdsTUmYcoDjMdGwkoR+u+28EguvJpUi1p3+GoIZea9M7Mog8gA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1744973221; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=rWns0+eDwC9QVYBODzZAaeZ2nr3J05qvlAY1f7M2w6E=; b=hbXAf6oJ368zcpm++9xtr89/pMWrx2sv3O24buN1FUbqypubsTMZNHbs7DMuVX4V0vEMMm jcLB6r3kWDn9B/xy47LNkPiQbAZVe0yvCp20cnYrXRJ1eLdXs87R8xtwftMrt3EYy1LZAM nMK62EWVf2t9yQ29k2dCSCg16NyavE5S46x0Y1b1AyRHlF+Y2KGpgw/rygjaakz4abRNDr YGE2d91dt9Mx2HdO4Cxw9fgFrZ1o6keaFlXBytqGTVNg8e5XM0yKs4ILtSlK5dIMEWNRYL Ae6tEhqf+uo8lKc/3E46gdUXlPM/A6uL9RVrPLu6bCIUHoEOi5r9vjYS2YNjWA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (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 did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4ZfBKK69DtzWTk; Fri, 18 Apr 2025 10:47:01 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 53IAl1CS059981; Fri, 18 Apr 2025 10:47:01 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 53IAl10J059978; Fri, 18 Apr 2025 10:47:01 GMT (envelope-from git) Date: Fri, 18 Apr 2025 10:47:01 GMT Message-Id: <202504181047.53IAl10J059978@gitrepo.freebsd.org> To: doc-committers@FreeBSD.org, dev-commits-doc-all@FreeBSD.org From: Benedict Reuschling Subject: git: e4fc6b8657 - main - Update jails chapter for FreeBSD version 14.2 in examples List-Id: Commit messages for all branches of the doc repository List-Archive: https://lists.freebsd.org/archives/dev-commits-doc-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-doc-all@freebsd.org Sender: owner-dev-commits-doc-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: bcr X-Git-Repository: doc X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: e4fc6b8657422d02cb1eddb166b928cf851be5ac Auto-Submitted: auto-generated The branch main has been updated by bcr: URL: https://cgit.FreeBSD.org/doc/commit/?id=e4fc6b8657422d02cb1eddb166b928cf851be5ac commit e4fc6b8657422d02cb1eddb166b928cf851be5ac Author: Benedict Reuschling AuthorDate: 2025-04-18 10:41:43 +0000 Commit: Benedict Reuschling CommitDate: 2025-04-18 10:46:01 +0000 Update jails chapter for FreeBSD version 14.2 in examples This reflects the latest version of FreeBSD at this time and provides paths with that version to create the jail. PR: 275685 Event: Easterhegg 2025 --- .../content/en/books/handbook/jails/_index.adoc | 62 +++++++++++----------- 1 file changed, 31 insertions(+), 31 deletions(-) diff --git a/documentation/content/en/books/handbook/jails/_index.adoc b/documentation/content/en/books/handbook/jails/_index.adoc index 94647932f2..8c8ffd6f0d 100644 --- a/documentation/content/en/books/handbook/jails/_index.adoc +++ b/documentation/content/en/books/handbook/jails/_index.adoc @@ -343,7 +343,7 @@ Execute the following command to download the userland: [source,shell] .... -# fetch https://download.freebsd.org/ftp/releases/amd64/amd64/13.2-RELEASE/base.txz -o /usr/local/jails/media/13.2-RELEASE-base.txz +# fetch https://download.freebsd.org/ftp/releases/amd64/amd64/14.2-RELEASE/base.txz -o /usr/local/jails/media/14.2-RELEASE-base.txz .... Once the download is complete, it will be necessary to extract the contents into the jail directory. @@ -353,7 +353,7 @@ Execute the following commands to extract the userland into the jail's directory [source,shell] .... # mkdir -p /usr/local/jails/containers/classic -# tar -xf /usr/local/jails/media/13.2-RELEASE-base.txz -C /usr/local/jails/containers/classic --unlink +# tar -xf /usr/local/jails/media/14.2-RELEASE-base.txz -C /usr/local/jails/containers/classic --unlink .... With the userland extracted in the jail directory, it will be necessary to copy the timezone and DNS server files: @@ -431,36 +431,36 @@ To create the dataset for the template, execute the following command: [source,shell] .... -# zfs create -p zroot/jails/templates/13.2-RELEASE +# zfs create -p zroot/jails/templates/14.2-RELEASE .... Then execute the following command to download the userland: [source,shell] .... -# fetch https://download.freebsd.org/ftp/releases/amd64/amd64/13.2-RELEASE/base.txz -o /usr/local/jails/media/13.2-RELEASE-base.txz +# fetch https://download.freebsd.org/ftp/releases/amd64/amd64/14.2-RELEASE/base.txz -o /usr/local/jails/media/14.2-RELEASE-base.txz .... Once the download is complete, it will be necessary to extract the contents in the template directory by executing the following command: [source,shell] .... -# tar -xf /usr/local/jails/media/13.2-RELEASE-base.txz -C /usr/local/jails/templates/13.2-RELEASE --unlink +# tar -xf /usr/local/jails/media/14.2-RELEASE-base.txz -C /usr/local/jails/templates/14.2-RELEASE --unlink .... With the userland extracted in the templates directory, it will be necessary to copy the timezone and DNS server files to the template directory by executing the following command: [source,shell] .... -# cp /etc/resolv.conf /usr/local/jails/templates/13.2-RELEASE/etc/resolv.conf -# cp /etc/localtime /usr/local/jails/templates/13.2-RELEASE/etc/localtime +# cp /etc/resolv.conf /usr/local/jails/templates/14.2-RELEASE/etc/resolv.conf +# cp /etc/localtime /usr/local/jails/templates/14.2-RELEASE/etc/localtime .... The next thing to do is update to the latest patch level by executing the following command: [source,shell] .... -# freebsd-update -b /usr/local/jails/templates/13.2-RELEASE/ fetch install +# freebsd-update -b /usr/local/jails/templates/14.2-RELEASE/ fetch install .... Once the update is finished, the template is ready. @@ -469,7 +469,7 @@ To create an OpenZFS Snapshot from the template, execute the following command: [source,shell] .... -# zfs snapshot zroot/jails/templates/13.2-RELEASE@base +# zfs snapshot zroot/jails/templates/14.2-RELEASE@base .... Once the OpenZFS Snapshot has been created, infinite jails can be created using the OpenZFS clone function. @@ -478,7 +478,7 @@ To create a Thin Jail named `thinjail`, execute the following command: [source,shell] .... -# zfs clone zroot/jails/templates/13.2-RELEASE@base zroot/jails/containers/thinjail +# zfs clone zroot/jails/templates/14.2-RELEASE@base zroot/jails/containers/thinjail .... The last step is to configure the jail. @@ -528,43 +528,43 @@ The first step is to create the dataset to save the template, execute the follow [source,shell] .... -# zfs create -p zroot/jails/templates/13.2-RELEASE-base +# zfs create -p zroot/jails/templates/14.2-RELEASE-base .... Or this one if using UFS: [source,shell] .... -# mkdir /usr/local/jails/templates/13.2-RELEASE-base +# mkdir /usr/local/jails/templates/14.2-RELEASE-base .... Then execute the following command to download the userland: [source,shell] .... -# fetch https://download.freebsd.org/ftp/releases/amd64/amd64/13.2-RELEASE/base.txz -o /usr/local/jails/media/13.2-RELEASE-base.txz +# fetch https://download.freebsd.org/ftp/releases/amd64/amd64/14.2-RELEASE/base.txz -o /usr/local/jails/media/14.2-RELEASE-base.txz .... Once the download is complete, it will be necessary to extract the contents in the template directory by executing the following command: [source,shell] .... -# tar -xf /usr/local/jails/media/13.2-RELEASE-base.txz -C /usr/local/jails/templates/13.2-RELEASE-base --unlink +# tar -xf /usr/local/jails/media/14.2-RELEASE-base.txz -C /usr/local/jails/templates/14.2-RELEASE-base --unlink .... Once the userland is extracted in the templates directory, it will be necessary to copy the timezone and DNS server files to the template directory by executing the following command: [source,shell] .... -# cp /etc/resolv.conf /usr/local/jails/templates/13.2-RELEASE-base/etc/resolv.conf -# cp /etc/localtime /usr/local/jails/templates/13.2-RELEASE-base/etc/localtime +# cp /etc/resolv.conf /usr/local/jails/templates/14.2-RELEASE-base/etc/resolv.conf +# cp /etc/localtime /usr/local/jails/templates/14.2-RELEASE-base/etc/localtime .... With the files moved to the template, the next thing to do is update to the latest patch level by executing the following command: [source,shell] .... -# freebsd-update -b /usr/local/jails/templates/13.2-RELEASE-base/ fetch install +# freebsd-update -b /usr/local/jails/templates/14.2-RELEASE-base/ fetch install .... In addition to the base template, it is also necessary to create a directory where the `skeleton` will be located. @@ -574,14 +574,14 @@ Execute the following command to create the dataset for the `skeleton` in case o [source,shell] .... -# zfs create -p zroot/jails/templates/13.2-RELEASE-skeleton +# zfs create -p zroot/jails/templates/14.2-RELEASE-skeleton .... Or this one in case of using UFS: [source,shell] .... -# mkdir /usr/local/jails/templates/13.2-RELEASE-skeleton +# mkdir /usr/local/jails/templates/14.2-RELEASE-skeleton .... Then create the `skeleton` directories. @@ -591,20 +591,20 @@ Execute the following commands to create the directories: [source,shell] .... -# mkdir -p /usr/local/jails/templates/13.2-RELEASE-skeleton/home -# mkdir -p /usr/local/jails/templates/13.2-RELEASE-skeleton/usr -# mv /usr/local/jails/templates/13.2-RELEASE-base/etc /usr/local/jails/templates/13.2-RELEASE-skeleton/etc -# mv /usr/local/jails/templates/13.2-RELEASE-base/usr/local /usr/local/jails/templates/13.2-RELEASE-skeleton/usr/local -# mv /usr/local/jails/templates/13.2-RELEASE-base/tmp /usr/local/jails/templates/13.2-RELEASE-skeleton/tmp -# mv /usr/local/jails/templates/13.2-RELEASE-base/var /usr/local/jails/templates/13.2-RELEASE-skeleton/var -# mv /usr/local/jails/templates/13.2-RELEASE-base/root /usr/local/jails/templates/13.2-RELEASE-skeleton/root +# mkdir -p /usr/local/jails/templates/14.2-RELEASE-skeleton/home +# mkdir -p /usr/local/jails/templates/14.2-RELEASE-skeleton/usr +# mv /usr/local/jails/templates/14.2-RELEASE-base/etc /usr/local/jails/templates/14.2-RELEASE-skeleton/etc +# mv /usr/local/jails/templates/14.2-RELEASE-base/usr/local /usr/local/jails/templates/14.2-RELEASE-skeleton/usr/local +# mv /usr/local/jails/templates/14.2-RELEASE-base/tmp /usr/local/jails/templates/14.2-RELEASE-skeleton/tmp +# mv /usr/local/jails/templates/14.2-RELEASE-base/var /usr/local/jails/templates/14.2-RELEASE-skeleton/var +# mv /usr/local/jails/templates/14.2-RELEASE-base/root /usr/local/jails/templates/14.2-RELEASE-skeleton/root .... The next step is to create the symlinks to the `skeleton` by executing the following commands: [source,shell] .... -# cd /usr/local/jails/templates/13.2-RELEASE-base/ +# cd /usr/local/jails/templates/14.2-RELEASE-base/ # mkdir skeleton # ln -s skeleton/etc etc # ln -s skeleton/home home @@ -620,15 +620,15 @@ In case of using OpenZFS, OpenZFS snapshots can be used to easily create as many [source,shell] .... -# zfs snapshot zroot/jails/templates/13.2-RELEASE-skeleton@base -# zfs clone zroot/jails/templates/13.2-RELEASE-skeleton@base zroot/jails/containers/thinjail +# zfs snapshot zroot/jails/templates/14.2-RELEASE-skeleton@base +# zfs clone zroot/jails/templates/14.2-RELEASE-skeleton@base zroot/jails/containers/thinjail .... In case of using UFS the man:cp[1] program can be used by executing the following command: [source,shell] .... -# cp -R /usr/local/jails/templates/13.2-RELEASE-skeleton /usr/local/jails/containers/thinjail +# cp -R /usr/local/jails/templates/14.2-RELEASE-skeleton /usr/local/jails/containers/thinjail .... Then create the directory in which the base template and the skeleton will be mounted: @@ -670,7 +670,7 @@ Then the create the [.filename]#/usr/local/jails/thinjail-nullfs-base.fstab# fil [.programlisting] .... -/usr/local/jails/templates/13.2-RELEASE-base /usr/local/jails/thinjail-nullfs-base/ nullfs ro 0 0 +/usr/local/jails/templates/14.2-RELEASE-base /usr/local/jails/thinjail-nullfs-base/ nullfs ro 0 0 /usr/local/jails/containers/thinjail /usr/local/jails/thinjail-nullfs-base/skeleton nullfs rw 0 0 ....