Upgrade to FreeBSD 13.1

This article illustrates the upgrade from FreeBSD 13.0 to FreeBSD 13.1

Please take a full backup or create a snapshot before upgrading.

The whole upgrade process will take about 30 minutes. This first 20 minutes will take for download. During this time all applications are available for the users.

# uname -a
FreeBSD ava2105 13.0-RELEASE-p11 FreeBSD 13.0-RELEASE-p11 #0: Tue Apr  5 18:54:35 UTC 2022     root@amd64-builder.daemonology.net:/usr/obj/usr/src/amd64.amd64/sys/GENERIC  amd64

# freebsd-update fetch
Looking up update.FreeBSD.org mirrors... 2 mirrors found.
Fetching metadata signature for 13.0-RELEASE from update1.freebsd.org... done.
Fetching metadata index... done.
Inspecting system... done.
Preparing to download files... done.
No updates needed to update system to 13.0-RELEASE-p11.

# date
Fri May 20 11:26:43 UTC 2022

# freebsd-update upgrade -r 13.1-RELEASE
Looking up update.FreeBSD.org mirrors... 2 mirrors found.
Fetching metadata signature for 13.0-RELEASE from update2.freebsd.org... done.
Fetching metadata index... done.
Fetching 1 metadata files... done.
Inspecting system... done.

The following components of FreeBSD seem to be installed:
kernel/generic kernel/generic-dbg world/base world/lib32

The following components of FreeBSD do not seem to be installed:
world/base-dbg world/lib32-dbg

Does this look reasonable (y/n)? y

Fetching metadata signature for 13.1-RELEASE from update2.freebsd.org... done.
Fetching metadata index... done.
Fetching 1 metadata patches. done.
Applying metadata patches... done.
Fetching 1 metadata files... done.
Inspecting system... done.
Fetching files from 13.0-RELEASE for merging... done.
Preparing to download files... 
Fetching 5191 patches.....
done.
Applying patches...

Applying patches... done.
Fetching 504 files... ....10....20....30....40....50....60....70....80....90....100....110....120....130....140....150....160....170....180....190....200....210....220....230....240....250....260....270....280....290....300....310....320....330....340....350....360....370....380....390....400....410....420....430....440....450....460....470....480....490....500.. done.
Attempting to automatically merge changes in files... done.

The following changes, which occurred between FreeBSD 13.0-RELEASE and
FreeBSD 13.1-RELEASE have been merged into /etc/freebsd-update.conf:
--- current version
+++ new version
@@ -72,5 +72,8 @@
 # directory.
 # BackupKernelDir /boot/kernel.old
 
 # When backing up a kernel also back up debug symbol files?
 # BackupKernelSymbolFiles no
+
+# Create a new boot environment when installing patches
+# CreateBootEnv yes
Does this look reasonable (y/n)? y

The following changes, which occurred between FreeBSD 13.0-RELEASE and
FreeBSD 13.1-RELEASE have been merged into /etc/group:
--- current version
+++ new version
@@ -16,10 +16,12 @@
 sshd:*:22:
 smmsp:*:25:
 mailnull:*:26:
 guest:*:31:
 video:*:44:
+realtime:*:47:
+idletime:*:48:
 bind:*:53:
 unbound:*:59:
 proxy:*:62:
 authpf:*:63:
 _pflogd:*:64:
Does this look reasonable (y/n)? y

The following changes, which occurred between FreeBSD 13.0-RELEASE and
FreeBSD 13.1-RELEASE have been merged into /etc/ssh/sshd_config:
--- current version
+++ new version
@@ -1,6 +1,6 @@
-#      $OpenBSD: sshd_config,v 1.103 2018/04/09 20:41:22 tj Exp $
+#      $OpenBSD: sshd_config,v 1.104 2021/07/02 05:11:21 dtucker Exp $
 #      $FreeBSD$
 
 # This is the sshd server system-wide configuration file.  See
 # sshd_config(5) for more information.
 
@@ -60,11 +60,11 @@
 # Change to yes to enable built-in password authentication.
 #PasswordAuthentication no
 #PermitEmptyPasswords no
 
 # Change to no to disable PAM authentication
-#ChallengeResponseAuthentication yes
+#KbdInteractiveAuthentication yes
 
 # Kerberos options
 #KerberosAuthentication no
 #KerberosOrLocalPasswd yes
 #KerberosTicketCleanup yes
@@ -74,17 +74,17 @@
 #GSSAPIAuthentication no
 #GSSAPICleanupCredentials yes
 
 # Set this to 'no' to disable PAM authentication, account processing,
 # and session processing. If this is enabled, PAM authentication will
-# be allowed through the ChallengeResponseAuthentication and
+# be allowed through the KbdInteractiveAuthentication and
 # PasswordAuthentication.  Depending on your PAM configuration,
-# PAM authentication via ChallengeResponseAuthentication may bypass
+# PAM authentication via KbdInteractiveAuthentication may bypass
 # the setting of "PermitRootLogin without-password".
 # If you just want the PAM account and session checks to run without
 # PAM authentication, then enable this but set PasswordAuthentication
-# and ChallengeResponseAuthentication to 'no'.
+# and KbdInteractiveAuthentication to 'no'.
 #UsePAM yes
 
 #AllowAgentForwarding yes
 #AllowTcpForwarding yes
 #GatewayPorts no
@@ -103,11 +103,11 @@
 #PidFile /var/run/sshd.pid
 #MaxStartups 10:30:100
 #PermitTunnel no
 #ChrootDirectory none
 #UseBlacklist no
-#VersionAddendum FreeBSD-20200214
+#VersionAddendum FreeBSD-20211221
 
 # no default banner path
 #Banner none
 
 # override default of no subsystems
Does this look reasonable (y/n)?  y

To install the downloaded upgrades, run "/usr/sbin/freebsd-update install".

# /usr/sbin/freebsd-update install


Installing updates...
Kernel updates have been installed.  Please reboot and run
"/usr/sbin/freebsd-update install" again to finish installing updates.

# shutdown -r now

# /usr/sbin/freebsd-update install

Installing updates...Scanning //usr/share/certs/blacklisted for certificates...
Scanning //usr/share/certs/trusted for certificates...
Scanning //usr/local/share/certs for certificates...
 done.

# pkg update ; pkg upgrade
Updating FreeBSD repository catalogue...
Fetching packagesite.pkg: 100%    6 MiB   6.7MB/s    00:01    
Processing entries: 100%
FreeBSD repository update completed. 31416 packages processed.
All repositories are up to date.
Updating FreeBSD repository catalogue...
FreeBSD repository is up to date.
All repositories are up to date.
Checking for upgrades (19 candidates): 100%
Processing candidates (19 candidates): 100%
The following 20 package(s) will be affected (of 0 checked):

New packages to be INSTALLED:
        libpsl: 0.21.1_4

Installed packages to be UPGRADED:
        ca_root_nss: 3.76 -> 3.77
        curl: 7.82.0 -> 7.83.1
        freetype2: 2.11.1 -> 2.12.0
        fribidi: 1.0.11 -> 1.0.12
        glib: 2.70.4_2,2 -> 2.70.4_6,2
        harfbuzz: 4.2.0 -> 4.2.1
        icu: 70.1_1,1 -> 71.1,1
        lcms2: 2.12 -> 2.13.1
        libffi: 3.3_1 -> 3.4.2
        libnghttp2: 1.46.0 -> 1.47.0
        libxml2: 2.9.13 -> 2.9.13_2
        llvm11: 11.0.1_5 -> 11.0.1_6
        postgresql14-client: 14.2 -> 14.3
        postgresql14-server: 14.2 -> 14.3
        py38-pillow: 9.0.1_1 -> 9.1.0
        python37: 3.7.13 -> 3.7.13_2
        python38: 3.8.13 -> 3.8.13_2
        rsync: 3.2.3_1 -> 3.2.4_1
        sqlite3: 3.37.2,1 -> 3.38.2,1

Number of packages to be installed: 1
Number of packages to be upgraded: 19

The process will require 2 MiB more space.
182 MiB to be downloaded.   y

[19/20] Upgrading postgresql14-server from 14.2 to 14.3...
===> Creating groups.
Using existing group 'postgres'.
===> Creating users
Using existing user 'postgres'.
===> Creating homedir(s)

  =========== BACKUP YOUR DATA! =============
  As always, backup your data before
  upgrading. If the upgrade leads to a higher
  major revision (e.g. 9.6 -> 10), a dump
  and restore of all databases is
  required. This is *NOT* done by the port!
  See https://www.postgresql.org/docs/current/upgrading.html
  ===========================================
[19/20] Extracting postgresql14-server-14.3: 100%
[20/20] Upgrading curl from 7.82.0 to 7.83.1...
[20/20] Extracting curl-7.83.1: 100%
Compiling glib schemas
No schema files found: doing nothing.

Cleanup after some days:

# find /var/db/freebsd-update/files -type f -mtime +10d -delete

Published: May 20, 2022

Change Content