Debian

Available patches from Ubuntu

To see Ubuntu differences wrt. to Debian, write down a grep-dctrl query identifying the packages you're interested in:
grep-dctrl -n -sPackage Sources.Debian
(e.g. -FPackage linux-ntfs or linux-ntfs)

Modified packages are listed below:

Debian ( Changelog | PTS | Bugs ) Ubuntu ( Changelog | txt | LP | Bugs ) | Diff from Ubuntu

Source: network-manager

network-manager (1.26.0-1ubuntu1) groovy; urgency=medium * Resynchronize on Debian, remaining changes: - Use systemd-resolved instead of dnsmasq - debian/control: + Depend on isc-dhcp-client instead of recommends + Recommend network-manager-pptp + Suggest avahi-autoipd for IPv4LL support - debian/rules, debian/network-manager.postinst: + Don't restart NetworkManager on upgrade but recommend restarting the computer - debian/rules, debian/network-manager.postinst: + Don't install sysvinit scripts or migrate from sysvinit - debian/network-manager.postinst: + Don't add the netdev group. + drop in an empty override file for NetworkManager to manage all devices for upgrade from any version, as long as there is no netplan configuration yet. - debian/default-wifi-powersave-on.conf, debian/rules: + Install a config file to enable WiFi powersave - Enable build tests - Add autopkgtests - debian/source_network-manager.py, debian/network-manager.install, debian/network-manager.links: Add apport hook - Add network-manager-config-connectivity-ubuntu package - NetworkManager.conf: disable MAC randomization feature. There is no easy way for desktop users to disable this feature yet. And there are reports that it doesn't work well with some systems. - Update Vcs links to point to Ubuntu branch - Add patches. See patch descriptions for more details: + Provide-access-to-some-of-NM-s-interfaces-to-whoopsie.patch + Update-dnsmasq-parameters.patch + Disable-general-with-expect.patch + libnm-Check-self-still-NMManager-or-not.patch + dns-manager-don-t-merge-split-DNS-search-domains.patch (but disabled) + Read-system-connections-from-run.patch - debian/tests/urfkill-integration - don't stop/start network manager -- Sebastien Bacher <seb128@ubuntu.com> Mon, 27 Jul 2020 17:09:03 +0200

Modifications :
  1. Download patch debian/network-manager.install

    --- 1.26.0-1/debian/network-manager.install 2020-07-13 20:34:27.000000000 +0000 +++ 1.26.0-1ubuntu1/debian/network-manager.install 2020-07-27 15:09:03.000000000 +0000 @@ -24,5 +24,7 @@ lib/systemd/system/NetworkManager-dispat lib/systemd/system/NetworkManager-wait-online.service debian/NetworkManager.conf etc/NetworkManager/ debian/org.freedesktop.NetworkManager.pkla var/lib/polkit-1/localauthority/10-vendor.d/ +debian/10-*.conf usr/lib/NetworkManager/conf.d/ debian/60-network-manager.rules usr/share/polkit-1/rules.d/ debian/01-ifupdown etc/NetworkManager/dispatcher.d/ +debian/source_network-manager.py /usr/share/apport/package-hooks/
  2. Download patch debian/default-wifi-powersave-on.conf

    --- 1.26.0-1/debian/default-wifi-powersave-on.conf 1970-01-01 00:00:00.000000000 +0000 +++ 1.26.0-1ubuntu1/debian/default-wifi-powersave-on.conf 2020-07-27 15:09:03.000000000 +0000 @@ -0,0 +1,2 @@ +[connection] +wifi.powersave = 3
  3. Download patch debian/network-manager.links
  4. Download patch debian/tests/control

    --- 1.26.0-1/debian/tests/control 1970-01-01 00:00:00.000000000 +0000 +++ 1.26.0-1ubuntu1/debian/tests/control 2020-07-27 15:09:03.000000000 +0000 @@ -0,0 +1,15 @@ +Tests: wpa-dhclient +Depends: python3, hostapd, dnsmasq-base, wpasupplicant, isc-dhcp-client, iw +Restrictions: needs-root allow-stderr isolation-machine skippable + +Tests: nm.py +Depends: python3, dnsmasq-base, isc-dhcp-client, gir1.2-nm-1.0, network-manager, hostapd, iw, python3-dbusmock, python3-netaddr +Restrictions: needs-root isolation-machine skippable + +Tests: killswitches-no-urfkill +Depends: network-manager, build-essential, linux-headers-generic [!i386], rfkill +Restrictions: needs-root allow-stderr isolation-machine skippable + +Tests: urfkill-integration +Depends: network-manager, build-essential, linux-headers-generic [!i386], rfkill, urfkill +Restrictions: needs-root allow-stderr isolation-machine skippable
  5. Download patch debian/tests/network_test_base.py
  6. Download patch debian/rules

    --- 1.26.0-1/debian/rules 2020-07-13 20:34:27.000000000 +0000 +++ 1.26.0-1ubuntu1/debian/rules 2020-07-27 15:09:03.000000000 +0000 @@ -2,12 +2,20 @@ include /usr/share/dpkg/architecture.mk +# Without that the tests fail, cannot register existing type 'NMAgentManagerError' +LDFLAGS=$(shell echo $$LDFLAGS | sed -e 's/-Wl,-Bsymbolic-functions//') +export LDFLAGS + +ifeq ($(shell dpkg-vendor --is Ubuntu && echo yes) $(DEB_HOST_ARCH), yes i386) + BUILD_PACKAGES += -Nnetwork-manager +endif + export PYTHON=/usr/bin/python3 PPPD_PLUGIN_DIR := $(shell dh_ppp --plugin-dir) %: - dh $@ --with gir,ppp + dh $@ --with gir,ppp $(BUILD_PACKAGES) autoreconf: gtkdocize --copy @@ -23,7 +31,7 @@ override_dh_auto_configure: --runstatedir=/run \ --with-pppd-plugin-dir=$(PPPD_PLUGIN_DIR) \ --with-pppd=/usr/sbin/pppd \ - --with-resolvconf=/sbin/resolvconf \ + --with-resolvconf=no \ --with-dhclient=/sbin/dhclient \ --with-iptables=/usr/sbin/iptables \ --with-dnsmasq=/usr/sbin/dnsmasq \ @@ -38,6 +46,7 @@ override_dh_auto_configure: --with-nmtui \ --with-nmcli \ --with-selinux \ + --with-tests \ --with-libaudit \ --with-iwd \ --without-dhcpcanon \ @@ -59,11 +68,19 @@ override_dh_auto_configure: override_dh_install: find debian/tmp -name '*.la' -print -delete + rm -vf $(CURDIR)/debian/tmp/etc/init.d/NetworkManager dh_install override_dh_missing: dh_missing --fail-missing + # copy powersave configuration + mkdir -p debian/network-manager/etc/NetworkManager/conf.d + cp debian/default-wifi-powersave-on.conf debian/network-manager/etc/NetworkManager/conf.d/ + +override_dh_installinit: + dh_installinit --noscripts + override_dh_makeshlibs: dh_makeshlibs -X/usr/lib/$(DEB_HOST_MULTIARCH)/NetworkManager/ -X/usr/lib/pppd/ @@ -73,3 +90,8 @@ override_dh_installsystemd: override_dh_ppp: dh_ppp --breaks + +override_dh_auto_test: +ifeq (, $(filter nocheck, $(DEB_BUILD_OPTIONS))) + make check || ( find . -name test-suite.log -exec cat {} \;; exit 1; ) +endif
  7. Download patch debian/tests/killswitches-no-urfkill

    --- 1.26.0-1/debian/tests/killswitches-no-urfkill 1970-01-01 00:00:00.000000000 +0000 +++ 1.26.0-1ubuntu1/debian/tests/killswitches-no-urfkill 2020-07-27 15:09:03.000000000 +0000 @@ -0,0 +1,67 @@ +#!/bin/sh + +if dpkg --print-architecture | grep s390; then + echo "Skipping rfkill tests on s390 (LP: #1855009)" + exit 77 +fi + +if dpkg --print-architecture | grep i386; then + echo "Skipping rfkill tests on i386 (LP: #1855183)" + exit 77 +fi + +set -e + +make -f debian/tests/Makefile fake-rfkill +# poor man's dependency resolver +DEPS=$(modinfo debian/tests/fake-rfkill.ko | sed -n '/depends:/ {s/^.*://; s/[[:space:]]*$//; p}') +[ -z "$DEPS" ] || modprobe "$DEPS" +insmod debian/tests/fake-rfkill.ko + +fake_id=$(rfkill list | grep fake | awk -F: '{ print $1; }') + +service NetworkManager start +sleep 30 + +# test blocking the device +rfkill block $fake_id +if ! rfkill list $fake_id | grep 'Soft' | awk '{ print $3; }' | grep -qc yes; then + echo "ERROR: could not block fake device" + rmmod fake-rfkill || true + exit 1 +fi + +# The systemd-rfkill service starts up whenever rfkill changes state, so on a +# 1-cpu system that might delay the event change from reaching nm before the +# check below, causing this test to fail. The settle added here delays the +# nmcli check until after the rfkill uevent has definitely been processed. +udevadm settle + +if ! LC_MESSAGES=C nmcli radio wifi | grep -qc disabled; then + echo "ERROR: NM could not track device state." + rmmod fake-rfkill || true + exit 1 +fi + +# test unblocking the device +rfkill unblock $fake_id +if ! rfkill list $fake_id | grep 'Soft' | awk '{ print $3; }' | grep -qc no; then + echo "ERROR: could not unblock fake device" + rmmod fake-rfkill || true + exit 1 +fi + +# same reason as above, however since systemd-rfkill stays running for 30 secs or so +# it's unlikely that it would start up again here, but it's still safer to call settle +udevadm settle + +if ! LC_MESSAGES=C nmcli radio wifi | grep -qc enabled; then + echo "ERROR: NM could not track device state to enabled." + rmmod fake-rfkill || true + exit 1 +fi + +rmmod fake-rfkill +make -f debian/tests/Makefile clean-rfkill + +echo OK
  8. Download patch debian/control

    --- 1.26.0-1/debian/control 2020-07-13 20:34:27.000000000 +0000 +++ 1.26.0-1ubuntu1/debian/control 2020-07-27 15:09:03.000000000 +0000 @@ -1,7 +1,8 @@ Source: network-manager Section: net Priority: optional -Maintainer: Utopia Maintenance Team <pkg-utopia-maintainers@lists.alioth.debian.org> +Maintainer: Ubuntu Developers <ubuntu-devel-discuss@lists.ubuntu.com> +XSBC-Original-Maintainer: Utopia Maintenance Team <pkg-utopia-maintainers@lists.alioth.debian.org> Uploaders: Michael Biebl <biebl@debian.org>, Sjoerd Simons <sjoerd@debian.org>, Aron Xu <aron@debian.org> @@ -41,8 +42,10 @@ Build-Depends: debhelper-compat (= 13), python3-dbus <!nocheck> Standards-Version: 4.5.0 Rules-Requires-Root: no -Vcs-Git: https://salsa.debian.org/utopia-team/network-manager.git -Vcs-Browser: https://salsa.debian.org/utopia-team/network-manager +XS-Debian-Vcs-Git: https://salsa.debian.org/utopia-team/network-manager.git +XS-Debian-Vcs-Browser: https://salsa.debian.org/utopia-team/network-manager +Vcs-Git: https://git.launchpad.net/network-manager +Vcs-Browser: https://git.launchpad.net/network-manager Homepage: https://wiki.gnome.org/Projects/NetworkManager Package: network-manager @@ -61,8 +64,10 @@ Recommends: ppp, dnsmasq-base, iptables, modemmanager, + network-manager-pptp, crda, -Suggests: libteam-utils, +Suggests: avahi-autoipd, + libteam-utils, isc-dhcp-client, Breaks: ${misc:Breaks} Description: network management framework (daemon and userspace tools) @@ -76,6 +81,8 @@ Description: network management framewor interact with NetworkManager. . Optional dependencies: + * avahi-autoipd: Used for IPv4LL, a protocol for automatic Link-Local IP + address configuration. * ppp: Required for establishing dial-up connections (e.g. via GSM). * dnsmasq-base/iptables: Required for creating Ad-hoc connections and connection sharing. @@ -165,3 +172,21 @@ Description: NetworkManager configuratio No user data is transmitted in the connectivity checks, but merely contacting the Debian connectivity check servers reveals that the user is running a Debian(-based) operating system with NetworkManager. + +Package: network-manager-config-connectivity-ubuntu +Architecture: all +Multi-Arch: foreign +Depends: ${misc:Depends}, + network-manager (>= ${source:Version}) +Description: NetworkManager configuration to enable connectivity checking + This package contains a configuration file which enables NetworkManager's + connectivity checking functionality. + . + NetworkManager will try to connect to an Ubuntu server to determine the + connection status. + . + This is particularly useful for captive portal detection. + . + No user data is transmitted in the connectivity checks, but merely contacting + the Ubuntu connectivity check servers reveals that the user is running an + Ubuntu(-based) operating system with NetworkManager.
  9. Download patch debian/tests/urfkill-integration

    --- 1.26.0-1/debian/tests/urfkill-integration 1970-01-01 00:00:00.000000000 +0000 +++ 1.26.0-1ubuntu1/debian/tests/urfkill-integration 2020-07-27 15:09:03.000000000 +0000 @@ -0,0 +1,108 @@ +#!/bin/sh + +if dpkg --print-architecture | grep s390; then + echo "Skipping rfkill tests on s390 (LP: #1855009)" + exit 77 +fi + +if dpkg --print-architecture | grep i386; then + echo "Skipping rfkill tests on i386 (LP: #1855183)" + exit 77 +fi + +set -e + +echo "+++ Building / adding fake-rfkill.ko" +make -f debian/tests/Makefile fake-rfkill +# poor man's dependency resolver +DEPS=$(modinfo debian/tests/fake-rfkill.ko | sed -n '/depends:/ {s/^.*://; s/[[:space:]]*$//; p}') +[ -z "$DEPS" ] || modprobe "$DEPS" +insmod debian/tests/fake-rfkill.ko + +fake_id=$(rfkill list | grep fake | awk -F: '{ print $1; }') +echo "+++ fake-rfkill.ko is device $fake_id" +echo + + +echo "--- Testing killswitch bringup to match NM state: when URFKILL doesn't run" +echo "+++ stopping urfkill" +# ignore failure, only here, because urfkill probably isn't running yet. +service urfkill stop || true +echo "+++ unblocking device $fake_id" +rfkill unblock $fake_id +echo "+++ stopping network-manager" +service NetworkManager stop || true +echo "+++ blocking device $fake_id" +rfkill block $fake_id +echo "+++ starting network-manager" +service NetworkManager start + +echo "+++ Waiting for the devices to settle" +sleep 30 + +echo -n "=== NetworkManager state should now be \"enabled\": " +LC_MESSAGES=C nmcli radio wifi +LC_MESSAGES=C nmcli radio wifi | grep -qc enabled +echo + +echo -n "=== NM saved state: " +grep WirelessEnabled /var/lib/NetworkManager/NetworkManager.state +grep -qc WirelessEnabled=true /var/lib/NetworkManager/NetworkManager.state +echo +echo + +echo "--- Testing killswitch bringup when URFKILL is running: follow URfkill signals" +echo "+++ starting urfkill" +service urfkill start +sleep 15 +echo "+++ blocking device $fake_id" +rfkill block $fake_id +rfkill list + +echo "+++ Waiting for the devices to settle" +sleep 30 + +echo -n "=== NetworkManager state should now be \"disabled\": " +LC_MESSAGES=C nmcli radio wifi +LC_MESSAGES=C nmcli radio wifi | grep -qc disabled +echo + +echo -n "=== NM saved state: " +grep WirelessEnabled /var/lib/NetworkManager/NetworkManager.state +#grep -qc WirelessEnabled=false /var/lib/NetworkManager/NetworkManager.state +echo +echo + +echo "+++ Asking urfkill to unblock device $fake_id" +dbus-send --print-reply --system --dest=org.freedesktop.URfkill /org/freedesktop/URfkill org.freedesktop.URfkill.BlockIdx uint32:$fake_id boolean:false +sleep 5 +echo -n "=== NetworkManager state should now be \"enabled\": " +LC_MESSAGES=C nmcli radio wifi +LC_MESSAGES=C nmcli radio wifi | grep -qc enabled +echo + +echo "+++ Asking urfkill to block device $fake_id again" +dbus-send --print-reply --system --dest=org.freedesktop.URfkill /org/freedesktop/URfkill org.freedesktop.URfkill.BlockIdx uint32:$fake_id boolean:true +sleep 5 +echo -n "=== NetworkManager state should now be \"disabled\": " +LC_MESSAGES=C nmcli radio wifi +LC_MESSAGES=C nmcli radio wifi | grep -qc disabled +echo +echo + +echo "--- Removing fake-rfkill, aggregate state should get back to enabled" +rmmod fake-rfkill +sleep 5 +echo -n "=== Checking that the fake device $fake_id has disappeared: " +rfkill list | ( ! grep -qc fake || exit 1 ) && echo yes || echo no + +echo -n "=== NetworkManager state should now be \"enabled\": " +LC_MESSAGES=C nmcli radio wifi +LC_MESSAGES=C nmcli radio wifi | grep -qc enabled +echo + +#cleanup +make -f debian/tests/Makefile clean-rfkill + +echo OK +exit 0
  10. Download patch debian/source_network-manager.py

    --- 1.26.0-1/debian/source_network-manager.py 1970-01-01 00:00:00.000000000 +0000 +++ 1.26.0-1ubuntu1/debian/source_network-manager.py 2020-07-27 15:09:03.000000000 +0000 @@ -0,0 +1,82 @@ +'''Apport package hook for Network Manager + +(c) 2008 Canonical Ltd. +Contributors: +Matt Zimmerman <mdz@canonical.com> +Martin Pitt <martin.pitt@canonical.com> +Mathieu Trudel-Lapierre <mathieu.trudel-lapierre@canonical.com> +Thomas Bechtold <thomasbechtold@jpberlin.de> + +This program is free software; you can redistribute it and/or modify it +under the terms of the GNU General Public License as published by the +Free Software Foundation; either version 2 of the License, or (at your +option) any later version. See http://www.gnu.org/copyleft/gpl.html for +the full text of the license. +''' + +import os +import subprocess +from apport.hookutils import * + +def _network_interfaces(): + interfaces = [] + output = command_output(['ls', '-1', '/sys/class/net']) + for device in output.split('\n'): + interfaces.append(device) + + return interfaces + +def _device_details(device): + details = command_output(['udevadm', 'info', '--query=all', '--path', '/sys/class/net/%s' % device]) + + # add the only extra thing of use from hal we don't get from udev. + details = details + "\nX: INTERFACE_MAC=" + details = details + command_output(['cat', '/sys/class/net/%s/address' % device]) + return details + +def add_info(report, ui=None): + attach_network(report) + attach_wifi(report) + + #this is the old config file (still read by NM if available) + attach_file_if_exists(report, '/etc/NetworkManager/nm-system-settings.conf', 'nm-system-settings.conf') + + #the new default config file + attach_file_if_exists(report, '/etc/NetworkManager/NetworkManager.conf', 'NetworkManager.conf') + + # attach NetworkManager.state: it gives us good hints in rfkill-related bugs. + attach_file_if_exists(report, '/var/lib/NetworkManager/NetworkManager.state', 'NetworkManager.state') + + for interface in _network_interfaces(): + key = 'NetDevice.%s' % interface + report[key] = _device_details(interface) + + interesting_modules = { 'ndiswrapper' : 'driver-ndiswrapper', + 'ath_hal' : 'driver-madwifi', + 'b44' : 'driver-b44' } + interesting_modules_loaded = [] + tags = [] + for line in open('/proc/modules'): + module = line.split()[0] + if module in interesting_modules: + tags.append(interesting_modules[module]) + interesting_modules_loaded.append(module) + + if interesting_modules_loaded: + report['InterestingModules'] = ' '.join(interesting_modules_loaded) + report.setdefault('Tags', '') + report['Tags'] += ' ' + ' '.join(tags) + + #add output of nmcli + report['nmcli-nm'] = command_output(['nmcli', '-f', 'all', 'gen']) + report['nmcli-dev'] = command_output(['nmcli', '-f', 'all', 'dev']) + report['nmcli-con'] = command_output(['nmcli', '-f', 'all', 'con']) + + +## Only for debugging ## +if __name__ == '__main__': + report = {} + report['CrashDB'] = 'ubuntu' + add_info(report, None) + for key in report: + print('%s: %s' % (key, report[key]))
  11. Download patch debian/tests/wpa-dhclient
  12. Download patch debian/patches/Provide-access-to-some-of-NM-s-interfaces-to-whoopsie.patch

    --- 1.26.0-1/debian/patches/Provide-access-to-some-of-NM-s-interfaces-to-whoopsie.patch 1970-01-01 00:00:00.000000000 +0000 +++ 1.26.0-1ubuntu1/debian/patches/Provide-access-to-some-of-NM-s-interfaces-to-whoopsie.patch 2020-07-27 15:09:03.000000000 +0000 @@ -0,0 +1,35 @@ +From: Mathieu Trudel-Lapierre <mathieu.trudel-lapierre@canonical.com> +Date: Thu, 12 May 2016 22:25:32 +0800 +Subject: Provide access to some of NM's interfaces to whoopsie. + +Whoopsie is the crash database reporting daemon. It needs access to some of +the information NM keeps about devices to avoid sending data over the network +when connected to 3G or other systems that are potentially billable. +--- + src/org.freedesktop.NetworkManager.conf | 13 +++++++++++++ + 1 file changed, 13 insertions(+) + +diff --git a/src/org.freedesktop.NetworkManager.conf b/src/org.freedesktop.NetworkManager.conf +index 6be1feb..3dd2350 100644 +--- a/src/org.freedesktop.NetworkManager.conf ++++ b/src/org.freedesktop.NetworkManager.conf +@@ -37,6 +37,19 @@ + <allow own="org.freedesktop.NetworkManager.dnsmasq"/> + <allow send_destination="org.freedesktop.NetworkManager.dnsmasq"/> + </policy> ++ <policy user="whoopsie"> ++ <allow send_destination="org.freedesktop.NetworkManager"/> ++ <allow send_destination="org.freedesktop.NetworkManager" ++ send_interface="org.freedesktop.DBus.Introspectable"/> ++ <allow send_destination="org.freedesktop.NetworkManager" ++ send_interface="org.freedesktop.DBus.Properties"/> ++ <allow send_destination="org.freedesktop.NetworkManager" ++ send_interface="org.freedesktop.NetworkManager"/> ++ <allow send_destination="org.freedesktop.NetworkManager" ++ send_interface="org.freedesktop.NetworkManager.Connection.Active"/> ++ <allow send_destination="org.freedesktop.NetworkManager" ++ send_interface="org.freedesktop.NetworkManager.Device"/> ++ </policy> + <policy context="default"> + <deny own="org.freedesktop.NetworkManager"/> +
  13. Download patch debian/tests/nm.py
  14. Download patch debian/network-manager-config-connectivity-ubuntu.install

    --- 1.26.0-1/debian/network-manager-config-connectivity-ubuntu.install 1970-01-01 00:00:00.000000000 +0000 +++ 1.26.0-1ubuntu1/debian/network-manager-config-connectivity-ubuntu.install 2020-07-27 15:09:03.000000000 +0000 @@ -0,0 +1 @@ +debian/20-connectivity-ubuntu.conf usr/lib/NetworkManager/conf.d/
  15. Download patch debian/network-manager.postinst

    --- 1.26.0-1/debian/network-manager.postinst 2020-07-13 20:34:27.000000000 +0000 +++ 1.26.0-1ubuntu1/debian/network-manager.postinst 2020-07-27 15:09:03.000000000 +0000 @@ -20,9 +20,16 @@ set -e case "$1" in configure) - # Create netdev group. Members of group netdev get access to the PolicyKit action - # org.freedesktop.NetworkManager.settings.modify.system without prior authentication - addgroup --quiet --system netdev + # request a reboot (NM tears down interfaces on restart + # which is not the way we want to go) + [ -x /usr/share/update-notifier/notify-reboot-required ] && \ + /usr/share/update-notifier/notify-reboot-required + + update-rc.d -f NetworkManager remove >/dev/null + + if [ -x "/etc/init.d/dbus" ]; then + invoke-rc.d dbus force-reload || true + fi # This directory can contain sensitive data and should not be world-readable chmod 0700 /var/lib/NetworkManager @@ -48,6 +55,15 @@ case "$1" in fi fi + if dpkg --compare-versions "$2" le-nl "9999"; then + mkdir -p /etc/NetworkManager/conf.d || true + # for old versions, override the global config with a null config, + # but only if the netplan config has not been modified by an user. + if find /etc/netplan -name "*.yaml" | wc -l | grep -qc 0; then + touch /etc/NetworkManager/conf.d/10-globally-managed-devices.conf + fi + fi + if dpkg --compare-versions "$2" lt-nl "1.20.4-2"; then if [ -f /var/lib/NetworkManager/secret_key ]; then chmod 0600 /var/lib/NetworkManager/secret_key
  16. Download patch debian/NetworkManager.conf

    --- 1.26.0-1/debian/NetworkManager.conf 2020-07-13 20:34:27.000000000 +0000 +++ 1.26.0-1ubuntu1/debian/NetworkManager.conf 2020-07-27 15:09:03.000000000 +0000 @@ -3,3 +3,6 @@ plugins=ifupdown,keyfile [ifupdown] managed=false + +[device] +wifi.scan-rand-mac-address=no
  17. Download patch debian/patches/gitlab_connection_ready.patch

    --- 1.26.0-1/debian/patches/gitlab_connection_ready.patch 1970-01-01 00:00:00.000000000 +0000 +++ 1.26.0-1ubuntu1/debian/patches/gitlab_connection_ready.patch 2020-07-27 15:09:03.000000000 +0000 @@ -0,0 +1,115 @@ + +From 1043189ef6bd12475304bbe87f4f8daaf67402ec Mon Sep 17 00:00:00 2001 +From: Thomas Haller <thaller@redhat.com> +Date: Fri, 31 Jan 2020 00:54:46 +0100 +Subject: [PATCH 2/2] libnm: hide NMActiveConnection until NMRemoteConnection + is ready + +Generally, libnm's NMClient cache only wants to expose NMObjects that +are fully initalized. Most objects don't require anything special, +except NMRemoteConnection waits for the GetSettings() call to complete. + +NMObjects reference each other. For example, NMActiveConnection +references NMDevice and NMRemoteConnection. There is a desire that an +object is only ready, if the objects that it references are ready too. +In practice that is not done, because usually every objects references +other objects, that means all objects would be declared as non-ready +until they are all ready at the same time. Only NMRemoteConnection +implements is_ready() function. All other objects are declared ready +as they appear. This is also done this way, to cope with cycles where +objects reference each other. In practice, such cycles should not be +exposed by NetworkManager. However, libnm should be robust against that. + +This has the undesired effect that when you call AddAndActivate(), then +the NMActiveConnection might already be ready while its +NMRemoteConnection isn't. That means, ac.get_connection() will +initially return NULL, until the remote connection becomes ready. +Also add a special handling that NMActiveConnection waits for their +NMRemoteConnection to be ready, before being ready itself. +--- + libnm/nm-active-connection.c | 29 +++++++++++++++++++++++++++++ + libnm/nm-client.c | 8 ++++++++ + libnm/nm-libnm-utils.h | 2 ++ + 3 files changed, 39 insertions(+) + +diff --git a/libnm/nm-active-connection.c b/libnm/nm-active-connection.c +index aa8504e61d..ade2edbe73 100644 +--- a/libnm/nm-active-connection.c ++++ b/libnm/nm-active-connection.c +@@ -425,6 +425,33 @@ _nm_active_connection_state_changed_commit (NMActiveConnection *self, + _notify_event_state_changed, + g_object_ref (self)); + } ++/*****************************************************************************/ ++ ++static gboolean ++is_ready (NMObject *nmobj) ++{ ++ NMActiveConnectionPrivate *priv = NM_ACTIVE_CONNECTION_GET_PRIVATE (nmobj); ++ ++ /* Usually, we don't want to expose our NMObject instances until they are fully initialized. ++ * For NMRemoteSetting this means to wait until GetSettings() returns. ++ * ++ * Note that most object types reference each other (directly or indirectly). E.g. the ++ * NMActiveConnection refers to the NMRemoteConnection and the NMDevice instance. So, ++ * we don't want to hide them too long, otherwise basically the entire set of objects ++ * will be hidden until they are all initialized. So, usually, when a NMObject references ++ * objects that are not yet initialized, that reference will just be NULL but the object ++ * will be considered ready already. ++ * ++ * For NMActiveConnection referencing a NMRemoteConnection don't do that. Here we wait for the ++ * NMRemoteConnection to be ready as well. This is somewhat arbitrary special casing, but ++ * the effect is that when nm_client_add_and_activate*() returns, the NMActiveConnection already ++ * references a initialized NMRemoteConnection. ++ */ ++ if (!nml_dbus_property_o_is_ready_fully (&priv->property_o[PROPERTY_O_IDX_CONNECTION])) ++ return FALSE; ++ ++ return NM_OBJECT_CLASS (nm_active_connection_parent_class)->is_ready (nmobj); ++} + + /*****************************************************************************/ + +@@ -550,6 +577,8 @@ nm_active_connection_class_init (NMActiveConnectionClass *klass) + object_class->get_property = get_property; + object_class->finalize = finalize; + ++ nm_object_class->is_ready = is_ready; ++ + _NM_OBJECT_CLASS_INIT_PRIV_PTR_INDIRECT (nm_object_class, NMActiveConnection); + + _NM_OBJECT_CLASS_INIT_PROPERTY_O_FIELDS_N (nm_object_class, NMActiveConnectionPrivate, property_o); +diff --git a/libnm/nm-client.c b/libnm/nm-client.c +index 154ad1c992..a93a81c353 100644 +--- a/libnm/nm-client.c ++++ b/libnm/nm-client.c +@@ -1594,6 +1594,14 @@ nml_dbus_property_o_is_ready (const NMLDBusPropertyO *pr_o) + || !pr_o->owner_dbobj; + } + ++gboolean ++nml_dbus_property_o_is_ready_fully (const NMLDBusPropertyO *pr_o) ++{ ++ return !pr_o->owner_dbobj ++ || !pr_o->obj_watcher ++ || pr_o->nmobj; ++} ++ + static void + nml_dbus_property_o_notify_changed (NMLDBusPropertyO *pr_o, + NMClient *self) +diff --git a/libnm/nm-libnm-utils.h b/libnm/nm-libnm-utils.h +index f2affc5f62..28c9c1164c 100644 +--- a/libnm/nm-libnm-utils.h ++++ b/libnm/nm-libnm-utils.h +@@ -260,6 +260,8 @@ gpointer nml_dbus_property_o_get_obj (NMLDBusPropertyO *pr_o); + + gboolean nml_dbus_property_o_is_ready (const NMLDBusPropertyO *pr_o); + ++gboolean nml_dbus_property_o_is_ready_fully (const NMLDBusPropertyO *pr_o); ++ + void nml_dbus_property_o_clear (NMLDBusPropertyO *pr_o, + NMClient *client); + +-- +2.24.1
  18. Download patch debian/patches/Update-dnsmasq-parameters.patch

    --- 1.26.0-1/debian/patches/Update-dnsmasq-parameters.patch 1970-01-01 00:00:00.000000000 +0000 +++ 1.26.0-1ubuntu1/debian/patches/Update-dnsmasq-parameters.patch 2020-07-27 15:09:03.000000000 +0000 @@ -0,0 +1,55 @@ +From: =?utf-8?q?St=C3=A9phane_Graber?= <stephane.graber@canonical.com> +Date: Thu, 12 May 2016 22:44:06 +0800 +Subject: Update dnsmasq parameters + +Disable caching since it's a potential security issue (local dns cache poisoning). + +See also: https://blueprints.launchpad.net/ubuntu/+spec/foundations-p-dns-resolving +--- + src/dns/nm-dns-dnsmasq.c | 4 ++-- + src/dns/nm-dns-manager.c | 6 +++--- + 2 files changed, 5 insertions(+), 5 deletions(-) + +Index: network-manager-1.24.0/src/dns/nm-dns-dnsmasq.c +=================================================================== +--- network-manager-1.24.0.orig/src/dns/nm-dns-dnsmasq.c ++++ network-manager-1.24.0/src/dns/nm-dns-dnsmasq.c +@@ -494,8 +494,8 @@ _gl_pid_spawn_next_step (void) + argv[argv_idx++] = "--no-hosts"; /* don't use /etc/hosts to resolve */ + argv[argv_idx++] = "--bind-interfaces"; + argv[argv_idx++] = "--pid-file=" PIDFILE; +- argv[argv_idx++] = "--listen-address=127.0.0.1"; /* Should work for both 4 and 6 */ +- argv[argv_idx++] = "--cache-size=400"; ++ argv[argv_idx++] = "--listen-address=127.0.1.1"; /* Should work for both 4 and 6 */ ++ argv[argv_idx++] = "--cache-size=0"; + argv[argv_idx++] = "--clear-on-reload"; /* clear cache when dns server changes */ + argv[argv_idx++] = "--conf-file=/dev/null"; /* avoid loading /etc/dnsmasq.conf */ + argv[argv_idx++] = "--proxy-dnssec"; /* Allow DNSSEC to pass through */ +Index: network-manager-1.24.0/src/dns/nm-dns-manager.c +=================================================================== +--- network-manager-1.24.0.orig/src/dns/nm-dns-manager.c ++++ network-manager-1.24.0/src/dns/nm-dns-manager.c +@@ -1526,12 +1526,12 @@ plugin_skip: + NM_CAST_STRV_CC (nameservers), + NM_CAST_STRV_CC (options)); + +- /* If caching was successful, we only send 127.0.0.1 to /etc/resolv.conf ++ /* If caching was successful, we only send 127.0.1.1 to /etc/resolv.conf + * to ensure that the glibc resolver doesn't try to round-robin nameservers, + * but only uses the local caching nameserver. + */ + if (caching) { +- const char *lladdr = "127.0.0.1"; ++ const char *lladdr = "127.0.1.1"; + + if (NM_IS_DNS_SYSTEMD_RESOLVED (priv->plugin)) { + /* systemd-resolved uses a different link-local address */ +@@ -1825,7 +1825,7 @@ nm_dns_manager_stop (NMDnsManager *self) + _LOGT ("stopping..."); + + /* If we're quitting, leave a valid resolv.conf in place, not one +- * pointing to 127.0.0.1 if dnsmasq was active. But if we haven't ++ * pointing to 127.0.1.1 if dnsmasq was active. But if we haven't + * done any DNS updates yet, there's no reason to touch resolv.conf + * on shutdown. + */
  19. Download patch debian/patches/series

    --- 1.26.0-1/debian/patches/series 2020-07-13 20:34:27.000000000 +0000 +++ 1.26.0-1ubuntu1/debian/patches/series 2020-07-27 15:09:03.000000000 +0000 @@ -1 +1,6 @@ Force-online-state-with-unmanaged-devices.patch + +# Ubuntu patches +Provide-access-to-some-of-NM-s-interfaces-to-whoopsie.patch +Update-dnsmasq-parameters.patch +
  20. Download patch debian/network-manager-config-connectivity-ubuntu.postinst

    --- 1.26.0-1/debian/network-manager-config-connectivity-ubuntu.postinst 1970-01-01 00:00:00.000000000 +0000 +++ 1.26.0-1ubuntu1/debian/network-manager-config-connectivity-ubuntu.postinst 2020-07-27 15:09:03.000000000 +0000 @@ -0,0 +1,9 @@ +#!/bin/sh + +set -e + +if [ "$1" = configure ]; then + invoke-rc.d network-manager force-reload || true +fi + +#DEBHELPER#
  21. Download patch debian/tests/fake-rfkill.c

    --- 1.26.0-1/debian/tests/fake-rfkill.c 1970-01-01 00:00:00.000000000 +0000 +++ 1.26.0-1ubuntu1/debian/tests/fake-rfkill.c 2020-07-27 15:09:03.000000000 +0000 @@ -0,0 +1,51 @@ +#include <linux/rfkill.h> +#include <linux/module.h> + +MODULE_LICENSE("GPL"); +MODULE_AUTHOR("Johannes Berg <johannes@sipsolutions.net>"); + +static struct rfkill *rfk; + +static void test_poll(struct rfkill *rfkill, void *data) +{ + printk(KERN_DEBUG "poll test rfkill\n"); +} + +static void test_query(struct rfkill *rfkill, void *data) +{ + printk(KERN_DEBUG "query test rfkill\n"); +} + +static int test_set_block(void *data, bool blocked) +{ + printk(KERN_DEBUG "set test rfkill (%s)\n", + blocked ? "blocked" : "active"); + return 0; +} + +static struct rfkill_ops ops = { + .poll = test_poll, + .query = test_query, + .set_block = test_set_block, +}; + +int mod_init(void) +{ + int err; + + rfk = rfkill_alloc("fake", NULL, RFKILL_TYPE_WLAN, &ops, NULL); + if (!rfk) + return -ENOMEM; + err = rfkill_register(rfk); + if (err) + rfkill_destroy(rfk); + return err; +} +module_init(mod_init); + +void mod_exit(void) +{ + rfkill_unregister(rfk); + rfkill_destroy(rfk); +} +module_exit(mod_exit);
  22. Download patch debian/20-connectivity-ubuntu.conf

    --- 1.26.0-1/debian/20-connectivity-ubuntu.conf 1970-01-01 00:00:00.000000000 +0000 +++ 1.26.0-1ubuntu1/debian/20-connectivity-ubuntu.conf 2020-07-27 15:09:03.000000000 +0000 @@ -0,0 +1,2 @@ +[connectivity] +uri=http://connectivity-check.ubuntu.com./
  23. Download patch debian/10-dns-resolved.conf

    --- 1.26.0-1/debian/10-dns-resolved.conf 1970-01-01 00:00:00.000000000 +0000 +++ 1.26.0-1ubuntu1/debian/10-dns-resolved.conf 2020-07-27 15:09:03.000000000 +0000 @@ -0,0 +1,5 @@ +[main] +# We need to specify "dns=systemd-resolved" as for the time being our +# /etc/resolv.conf points to resolvconf's generated file instead of +# systemd-resolved's, so the auto-detection does not work. +dns=systemd-resolved
  24. Download patch debian/10-globally-managed-devices.conf

    --- 1.26.0-1/debian/10-globally-managed-devices.conf 1970-01-01 00:00:00.000000000 +0000 +++ 1.26.0-1ubuntu1/debian/10-globally-managed-devices.conf 2020-07-27 15:09:03.000000000 +0000 @@ -0,0 +1,2 @@ +[keyfile] +unmanaged-devices=*,except:type:wifi,except:type:gsm,except:type:cdma
  25. Download patch debian/patches/Import-some-missing-WoWLAN-patches.patch
  26. Download patch debian/patches/dns-manager-don-t-merge-split-DNS-search-domains.patch

    --- 1.26.0-1/debian/patches/dns-manager-don-t-merge-split-DNS-search-domains.patch 1970-01-01 00:00:00.000000000 +0000 +++ 1.26.0-1ubuntu1/debian/patches/dns-manager-don-t-merge-split-DNS-search-domains.patch 2020-07-27 15:09:03.000000000 +0000 @@ -0,0 +1,88 @@ +From: Mathieu Trudel-Lapierre <mathieu.trudel-lapierre@canonical.com> +Date: Wed, 15 Jun 2016 16:07:27 +0300 +Subject: dns-manager: don't merge split-DNS search domains + +Signed-off-by: Mathieu Trudel-Lapierre <mathieu.trudel-lapierre@canonical.com> +Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/network-manager/+bug/1592721 +--- + src/dns/nm-dns-manager.c | 36 ++++++++++++++++++++---------------- + 1 file changed, 20 insertions(+), 16 deletions(-) + +Index: b/src/dns/nm-dns-manager.c +=================================================================== +--- a/src/dns/nm-dns-manager.c ++++ b/src/dns/nm-dns-manager.c +@@ -295,7 +295,7 @@ + } + + static void +-merge_one_ip4_config (NMResolvConfData *rc, NMIP4Config *src) ++merge_one_ip4_config (NMResolvConfData *rc, NMIP4Config *src, gboolean never_default) + { + guint32 num, num_domains, num_searches, i; + +@@ -308,13 +308,14 @@ + num_domains = nm_ip4_config_get_num_domains (src); + num_searches = nm_ip4_config_get_num_searches (src); + +- for (i = 0; i < num_searches; i++) { +- const char *search; +- +- search = nm_ip4_config_get_search (src, i); +- if (!domain_is_valid (search, FALSE)) +- continue; +- add_string_item (rc->searches, search); ++ if (!never_default) { ++ for (i = 0; i < num_searches; i++) { ++ const char *search; ++ search = nm_ip4_config_get_search (src, i); ++ if (!domain_is_valid (search, FALSE)) ++ continue; ++ add_string_item (rc->searches, search); ++ } + } + + if (num_domains > 1 || !num_searches) { +@@ -351,7 +352,7 @@ + } + + static void +-merge_one_ip6_config (NMResolvConfData *rc, NMIP6Config *src, const char *iface) ++merge_one_ip6_config (NMResolvConfData *rc, NMIP6Config *src, const char *iface, gboolean never_default) + { + guint32 num, num_domains, num_searches, i; + +@@ -378,13 +379,14 @@ + num_domains = nm_ip6_config_get_num_domains (src); + num_searches = nm_ip6_config_get_num_searches (src); + +- for (i = 0; i < num_searches; i++) { +- const char *search; +- +- search = nm_ip6_config_get_search (src, i); +- if (!domain_is_valid (search, FALSE)) +- continue; +- add_string_item (rc->searches, search); ++ if (!never_default) { ++ for (i = 0; i < num_searches; i++) { ++ const char *search; ++ search = nm_ip6_config_get_search (src, i); ++ if (!domain_is_valid (search, FALSE)) ++ continue; ++ add_string_item (rc->searches, search); ++ } + } + + if (num_domains > 1 || !num_searches) { +@@ -412,9 +414,9 @@ + NMDnsIPConfigData *data) + { + if (NM_IS_IP4_CONFIG (data->config)) +- merge_one_ip4_config (rc, (NMIP4Config *) data->config); ++ merge_one_ip4_config (rc, (NMIP4Config *) data->config, nm_ip4_config_get_never_default (data->config)); + else if (NM_IS_IP6_CONFIG (data->config)) +- merge_one_ip6_config (rc, (NMIP6Config *) data->config, data->iface); ++ merge_one_ip6_config (rc, (NMIP6Config *) data->config, data->iface, nm_ip4_config_get_never_default (data->config)); + else + g_return_if_reached (); + }
  27. Download patch debian/tests/Makefile

    --- 1.26.0-1/debian/tests/Makefile 1970-01-01 00:00:00.000000000 +0000 +++ 1.26.0-1ubuntu1/debian/tests/Makefile 2020-07-27 15:09:03.000000000 +0000 @@ -0,0 +1,8 @@ + +obj-m += fake-rfkill.o + +fake-rfkill: + make -C /lib/modules/$(shell uname -r)/build KBUILD_SRC=/lib/modules/$(shell uname -r)/build M=$(shell pwd)/debian/tests + +clean-rfkill: + make -C /lib/modules/$(shell uname -r)/build KBUILD_SRC=/lib/modules/$(shell uname -r)/build M=$(shell pwd)/debian/tests clean
  28. Download patch debian/gbp.conf

    --- 1.26.0-1/debian/gbp.conf 2020-07-13 20:34:27.000000000 +0000 +++ 1.26.0-1ubuntu1/debian/gbp.conf 2020-07-27 15:09:03.000000000 +0000 @@ -1,5 +1,6 @@ [DEFAULT] pristine-tar = True patch-numbers = False -debian-branch = debian/master +debian-branch = ubuntu/master +debian-tag = ubuntu/%(version)s upstream-branch = upstream/latest

Debian ( Changelog | PTS | Bugs ) Ubuntu ( Changelog | txt | LP | Bugs ) | Diff from Ubuntu

Source: zfs-linux

zfs-linux (0.8.4-1ubuntu10) groovy; urgency=medium * Fix volume wait on locked encrypted zvols (LP: #1888405) [ James Dingwall ] - 4620-zfs-vol-wait-fix-locked-encrypted-vols.patch zfs-volume-wait.service systemd unit does not start if the encrypted zvol is locked. The /sbin/zvol_wait should not wait for links when the volume has property keystatus=unavailable. Add a check for this. -- Colin Ian King <colin.king@canonical.com> Wed, 22 Jul 2020 09:58:22 +0100 zfs-linux (0.8.4-1ubuntu9) groovy; urgency=medium [ Colin Ian King ] * Add risc-v 64 bit support, requires implementing risc-v setjmp/longjmp and adding some relevant #defines - 4521-enable-risc-v-isa.patch * Disable HTML doc generation because of a Sphinx regression between version 2.4.3-2 and 2.4.3-4 (see Debian bug 962276) -- Colin Ian King <colin.king@canonical.com> Tue, 21 Jul 2020 10:01:10 +0100 zfs-linux (0.8.4-1ubuntu8) groovy; urgency=medium [ Didier Roche ] [ Jean-Baptiste Lallement ] * debian/patches/4000-mount-encrypted-dataset-fix.patch: - Upstreamable patch (under PR) for making keystore encryption or direct ZFS encryption closer, and make the service chain more robust. * debian/patches/4000-zsys-support.patch: - Reupdate with latest version of code, which was reverted erroneously to a previous version during debian merge. - Align PROPS generated cache to zed list cacher properties. - Add keystore encryption support. * debian/patches/4500-fix-generator-invalid-cache.patch: - Removed again, was removed before focal release, but has been erroneously restored during debian merge. * debian/patches/git_fix_dependency_loop_encryption2.patch: - Refreshed -- Jean-Baptiste Lallement <jean-baptiste.lallement@ubuntu.com> Fri, 19 Jun 2020 16:17:05 +0200 zfs-linux (0.8.4-1ubuntu7) groovy; urgency=medium * debian/patches/4520-Linux-5.8-compat-__vmalloc.patch - Add Linux 5.8 compat fix -- Colin Ian King <colin.king@canonical.com> Thu, 18 Jun 2020 14:40:22 +0100 zfs-linux (0.8.4-1ubuntu6) groovy; urgency=medium * debian/patches/4000-zsys-support.patch: - Fix boot on non encrypted system when cryptsetup-initramfs isn’t installed (LP: #1882975) -- Didier Roche <didrocks@ubuntu.com> Thu, 11 Jun 2020 08:17:14 +0200 zfs-linux (0.8.4-1ubuntu5) groovy; urgency=medium [ Jean-Baptiste Lallement ] [ Didier Roche ] * debian/patches/4000-zsys-support.patch: - Readd ZSys support erroneously dropped during previous debian merge. - Add external Luks store encryption support. * debian/patches/git_fix_dependency_loop_encryption{1,2}.patch: - Backport upstream patches (PR accepted, not merged yet) fixing a dependency loop when encryption via Luks (like swap) is enabled. (LP: #1875577) -- Didier Roche <didrocks@ubuntu.com> Wed, 10 Jun 2020 10:48:19 +0200 zfs-linux (0.8.4-1ubuntu4) groovy; urgency=medium * Don't report errors if modprobe fails (LP: #1880421) - loading ZFS modules on zfs-utils installation is a nice to have feature, but don't throw an error if modules are not available to load -- Colin Ian King <colin.king@canonical.com> Thu, 4 Jun 2020 13:54:54 +0100 zfs-linux (0.8.4-1ubuntu3) groovy; urgency=medium * Debian/tests: Move control.ubuntu to control - kernel ADT tests handle the driver side of testing so just use the standard smoke tests -- Colin Ian King <colin.king@canonical.com> Tue, 2 Jun 2020 10:56:52 +0100 zfs-linux (0.8.4-1ubuntu2) groovy; urgency=medium * Remove zfs-dkms depedencies for Ubuntu as these are built into the kernel -- Colin Ian King <colin.king@canonical.com> Mon, 1 Jun 2020 22:57:23 +0100 zfs-linux (0.8.4-1ubuntu1) groovy; urgency=medium * Sync with debian 0.8.4-1 * Ubuntu specific changes: - copy over 0.8.3 Ubuntu changes to 0.8.4 - drop debian tests in debian/tests/control - wiggle zsys patches to apply cleanly: 4000-zsys-support.patch 4500-fix-generator-invalid-cache.patch -- Colin Ian King <colin.king@canonical.com> Mon, 1 Jun 2020 10:20:51 +0100

Modifications :
  1. Download patch debian/tests/control

    --- 0.8.4-1/debian/tests/control 2020-05-13 06:40:56.000000000 +0000 +++ 0.8.4-1ubuntu10/debian/tests/control 2020-06-02 09:54:52.000000000 +0000 @@ -1,24 +1,7 @@ -Tests: kernel-smoke-test, kernel-ztest +Tests: kernel-smoke-test Restrictions: needs-root, isolation-machine Depends: zfs-dkms [ amd64 arm64 ppc64el s390x ], zfs-initramfs [ amd64 arm64 ppc64el s390x ], zfs-test [ amd64 arm64 ppc64el s390x ], zfs-zed [ amd64 arm64 ppc64el s390x ], zfsutils-linux [ amd64 arm64 ppc64el s390x ] - -Tests: dkms-zfs-test -Restrictions: needs-root, allow-stderr -Depends: dkms, - linux-headers-amd64 [amd64], - linux-headers-arm64 [arm64], - linux-headers-powerpc64le [ppc64el], - linux-headers-s390x [s390x] - -Tests: binary-debs-modules, binary-debs-modules-udeb -Restrictions: needs-root, allow-stderr, -Depends: fakeroot, - linux-headers-amd64 [amd64], - linux-headers-arm64 [arm64], - linux-headers-powerpc64le [ppc64el], - linux-headers-s390x [s390x], - @builddeps@
  2. Download patch debian/patches/4620-zfs-vol-wait-fix-locked-encrypted-vols.patch

    --- 0.8.4-1/debian/patches/4620-zfs-vol-wait-fix-locked-encrypted-vols.patch 1970-01-01 00:00:00.000000000 +0000 +++ 0.8.4-1ubuntu10/debian/patches/4620-zfs-vol-wait-fix-locked-encrypted-vols.patch 2020-07-22 08:58:22.000000000 +0000 @@ -0,0 +1,39 @@ +Description: don't wait for links when volume has property keystatus=unavailable + zfs-volume-wait.service systemd unit does not start if the encrypted + zvol is locked. The /sbin/zvol_wait should not wait for links when the + volume has property keystatus=unavailable. This patch fixes this issue +Bug: https://bugs.launchpad.net/ubuntu/+source/zfs-linux/+bug/1888405 +Author: James Dingwall +Origin: ubuntu +Forwarded: no +Reviewed-By: Colin Ian King <colin.king@canonical.com> +Last-Update: 2020-07-22 + +Index: zfs-linux-0.8.3/cmd/zvol_wait/zvol_wait +=================================================================== +--- zfs-linux-0.8.3.orig/cmd/zvol_wait/zvol_wait ++++ zfs-linux-0.8.3/cmd/zvol_wait/zvol_wait +@@ -24,6 +24,14 @@ filter_out_deleted_zvols() { + done + } + ++filter_out_locked_zvols() { ++ while read -r zvol; do ++ if ! [ "$(zfs list -H -o keystatus rpool/export/vault/block "$zvol")" = "unavailable" ]; then ++ echo "$zvol" ++ fi ++ done ++} ++ + list_zvols() { + zfs list -t volume -H -o name,volmode,receive_resume_token | + while read -r zvol_line; do +@@ -71,7 +79,7 @@ while [ "$outer_loop" -lt 20 ]; do + while [ "$inner_loop" -lt 30 ]; do + inner_loop=$((inner_loop + 1)) + +- zvols="$(echo "$zvols" | filter_out_zvols_with_links)" ++ zvols="$(echo "$zvols" | filter_out_zvols_with_links | filter_out_locked_zvols)" + + zvols_count=$(count_zvols) + if [ "$zvols_count" -eq 0 ]; then
  3. Download patch debian/rules

    --- 0.8.4-1/debian/rules 2020-05-13 02:02:03.000000000 +0000 +++ 0.8.4-1ubuntu10/debian/rules 2020-07-21 09:01:10.000000000 +0000 @@ -182,9 +182,14 @@ override_dh_systemd_start: override_dh_installdocs: dh_installdocs -ifeq (,$(findstring nodoc, $(DEB_BUILD_OPTIONS))) - http_proxy='127.0.0.1:9' $(SPHINX_BUILD) -N -bhtml "$(CURDIR)/contrib/pyzfs/docs/source/" debian/pyzfs-doc/usr/share/doc/pyzfs-doc/html/ -endif +# +# Temporarily disable html doc generation because +# a regression caused by sphinx between version 2.4.3-2 and 2.4.3-4. +# See debian bug #962276 +# +#ifeq (,$(findstring nodoc, $(DEB_BUILD_OPTIONS))) +# http_proxy='127.0.0.1:9' $(SPHINX_BUILD) -N -bhtml "$(CURDIR)/contrib/pyzfs/docs/source/" debian/pyzfs-doc/usr/share/doc/pyzfs-doc/html/ +#endif # ------------
  4. Download patch debian/patches/4000-zsys-support.patch
  5. Download patch debian/control

    --- 0.8.4-1/debian/control 2020-05-13 01:51:02.000000000 +0000 +++ 0.8.4-1ubuntu10/debian/control 2020-07-21 09:01:10.000000000 +0000 @@ -1,7 +1,8 @@ Source: zfs-linux Section: contrib/kernel Priority: optional -Maintainer: Debian ZFS on Linux maintainers <pkg-zfsonlinux-devel@alioth-lists.debian.net> +Maintainer: Ubuntu Developers <ubuntu-devel-discuss@lists.ubuntu.com> +XSBC-Original-Maintainer: Debian ZFS on Linux maintainers <pkg-zfsonlinux-devel@alioth-lists.debian.net> Uploaders: Aron Xu <aron@debian.org>, Petter Reinholdtsen <pere@debian.org>, Carlos Alberto Lopez Perez <clopez@igalia.com>, @@ -166,10 +167,9 @@ Description: OpenZFS filesystem kernel m OpenZFS. Package: zfs-initramfs -Architecture: all +Architecture: amd64 arm64 ppc64el s390x Depends: busybox-initramfs | busybox-static | busybox, initramfs-tools, - zfs-modules | zfs-dkms, zfsutils-linux (>= ${binary:Version}), ${misc:Depends} Breaks: zfsutils-linux (<= 0.7.11-2) @@ -183,9 +183,8 @@ Description: OpenZFS root filesystem cap for the initramfs-tools infrastructure. Package: zfs-dracut -Architecture: all +Architecture: amd64 arm64 ppc64el s390x Depends: dracut, - zfs-modules | zfs-dkms, zfsutils-linux (>= ${binary:Version}), ${misc:Depends} Description: OpenZFS root filesystem capabilities for Linux - dracut @@ -206,7 +205,7 @@ Depends: libnvpair1linux (= ${binary:Ver python3, ${misc:Depends}, ${shlibs:Depends} -Recommends: lsb-base, zfs-modules | zfs-dkms, zfs-zed +Recommends: lsb-base, zfs-zed Breaks: openrc, spl (<< 0.7.9-2), spl-dkms (<< 0.8.0~rc1), @@ -229,8 +228,7 @@ Description: command-line tools to manag Package: zfs-zed Section: contrib/admin Architecture: linux-any -Depends: zfs-modules | zfs-dkms, - zfsutils-linux (>= ${binary:Version}), +Depends: zfsutils-linux (>= ${binary:Version}), ${misc:Depends}, ${shlibs:Depends} Description: OpenZFS Event Daemon @@ -255,7 +253,6 @@ Depends: acl, python3-pyzfs, sudo, sysstat, - zfs-modules | zfs-dkms, zfsutils-linux (>=${binary:Version}), ${misc:Depends}, ${shlibs:Depends}
  6. Download patch debian/patches/4520-Linux-5.8-compat-__vmalloc.patch

    --- 0.8.4-1/debian/patches/4520-Linux-5.8-compat-__vmalloc.patch 1970-01-01 00:00:00.000000000 +0000 +++ 0.8.4-1ubuntu10/debian/patches/4520-Linux-5.8-compat-__vmalloc.patch 2020-06-18 13:40:22.000000000 +0000 @@ -0,0 +1,152 @@ +From 080102a1b686a36adaec3a11a9778783462429e8 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Michael=20Niew=C3=B6hner?= + <c0d3z3r0@users.noreply.github.com> +Date: Tue, 9 Jun 2020 01:32:02 +0200 +Subject: [PATCH] Linux 5.8 compat: __vmalloc() +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +The `pgprot` argument has been removed from `__vmalloc` in Linux 5.8, +being `PAGE_KERNEL` always now [1]. + +Detect this during configure and define a wrapper for older kernels. + +[1] https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/mm/vmalloc.c?h=next-20200605&id=88dca4ca5a93d2c09e5bbc6a62fbfc3af83c4fca + +Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> +Co-authored-by: Sebastian Gottschall <s.gottschall@dd-wrt.com> +Co-authored-by: Michael Niewöhner <foss@mniewoehner.de> +Signed-off-by: Sebastian Gottschall <s.gottschall@dd-wrt.com> +Signed-off-by: Michael Niewöhner <foss@mniewoehner.de> +Closes #10422 +--- + config/kernel.m4 | 2 ++ + include/spl/sys/kmem.h | 9 +++++++++ + module/spl/spl-kmem-cache.c | 4 ++-- + module/spl/spl-kmem.c | 16 +++++++--------- + 5 files changed, 46 insertions(+), 11 deletions(-) + +Index: zfs-linux-0.8.4/config/kernel.m4 +=================================================================== +--- zfs-linux-0.8.4.orig/config/kernel.m4 ++++ zfs-linux-0.8.4/config/kernel.m4 +@@ -44,6 +44,7 @@ AC_DEFUN([ZFS_AC_KERNEL_TEST_SRC], [ + ZFS_AC_KERNEL_SRC_RWSEM + ZFS_AC_KERNEL_SRC_SCHED + ZFS_AC_KERNEL_SRC_USLEEP_RANGE ++ ZFS_AC_KERNEL_SRC_VMALLOC_PAGE_KERNEL + ZFS_AC_KERNEL_SRC_KMEM_CACHE + ZFS_AC_KERNEL_SRC_WAIT + ZFS_AC_KERNEL_SRC_INODE_TIMES +@@ -162,6 +163,7 @@ AC_DEFUN([ZFS_AC_KERNEL_TEST_RESULT], [ + ZFS_AC_KERNEL_RWSEM + ZFS_AC_KERNEL_SCHED + ZFS_AC_KERNEL_USLEEP_RANGE ++ ZFS_AC_KERNEL_VMALLOC_PAGE_KERNEL + ZFS_AC_KERNEL_KMEM_CACHE + ZFS_AC_KERNEL_WAIT + ZFS_AC_KERNEL_INODE_TIMES +Index: zfs-linux-0.8.4/include/spl/sys/kmem.h +=================================================================== +--- zfs-linux-0.8.4.orig/include/spl/sys/kmem.h ++++ zfs-linux-0.8.4/include/spl/sys/kmem.h +@@ -170,6 +170,15 @@ extern void *spl_kmem_zalloc(size_t sz, + extern void spl_kmem_free(const void *ptr, size_t sz); + + /* ++ * 5.8 API change, pgprot_t argument removed. ++ */ ++#ifdef HAVE_VMALLOC_PAGE_KERNEL ++#define spl_vmalloc(size, flags) __vmalloc(size, flags, PAGE_KERNEL) ++#else ++#define spl_vmalloc(size, flags) __vmalloc(size, flags) ++#endif ++ ++/* + * The following functions are only available for internal use. + */ + extern void *spl_kmem_alloc_impl(size_t size, int flags, int node); +Index: zfs-linux-0.8.4/module/spl/spl-kmem-cache.c +=================================================================== +--- zfs-linux-0.8.4.orig/module/spl/spl-kmem-cache.c ++++ zfs-linux-0.8.4/module/spl/spl-kmem-cache.c +@@ -203,7 +203,7 @@ kv_alloc(spl_kmem_cache_t *skc, int size + ASSERT(ISP2(size)); + ptr = (void *)__get_free_pages(lflags, get_order(size)); + } else { +- ptr = __vmalloc(size, lflags | __GFP_HIGHMEM, PAGE_KERNEL); ++ ptr = spl_vmalloc(size, lflags | __GFP_HIGHMEM); + } + + /* Resulting allocated memory will be page aligned */ +@@ -1242,7 +1242,7 @@ spl_cache_grow(spl_kmem_cache_t *skc, in + * allocation. + * + * However, this can't be applied to KVM_VMEM due to a bug that +- * __vmalloc() doesn't honor gfp flags in page table allocation. ++ * spl_vmalloc() doesn't honor gfp flags in page table allocation. + */ + if (!(skc->skc_flags & KMC_VMEM)) { + rc = __spl_cache_grow(skc, flags | KM_NOSLEEP); +Index: zfs-linux-0.8.4/module/spl/spl-kmem.c +=================================================================== +--- zfs-linux-0.8.4.orig/module/spl/spl-kmem.c ++++ zfs-linux-0.8.4/module/spl/spl-kmem.c +@@ -172,7 +172,7 @@ spl_kmem_alloc_impl(size_t size, int fla + * kmem_zalloc() callers. + * + * For vmem_alloc() and vmem_zalloc() callers it is permissible +- * to use __vmalloc(). However, in general use of __vmalloc() ++ * to use spl_vmalloc(). However, in general use of spl_vmalloc() + * is strongly discouraged because a global lock must be + * acquired. Contention on this lock can significantly + * impact performance so frequently manipulating the virtual +@@ -180,8 +180,7 @@ spl_kmem_alloc_impl(size_t size, int fla + */ + if ((size > spl_kmem_alloc_max) || use_vmem) { + if (flags & KM_VMEM) { +- ptr = __vmalloc(size, lflags | __GFP_HIGHMEM, +- PAGE_KERNEL); ++ ptr = spl_vmalloc(size, lflags | __GFP_HIGHMEM); + } else { + return (NULL); + } +@@ -194,7 +193,7 @@ spl_kmem_alloc_impl(size_t size, int fla + + /* + * For vmem_alloc() and vmem_zalloc() callers retry immediately +- * using __vmalloc() which is unlikely to fail. ++ * using spl_vmalloc() which is unlikely to fail. + */ + if ((flags & KM_VMEM) && (use_vmem == 0)) { + use_vmem = 1; +Index: zfs-linux-0.8.4/config/kernel-kmem.m4 +=================================================================== +--- /dev/null ++++ zfs-linux-0.8.4/config/kernel-kmem.m4 +@@ -0,0 +1,24 @@ ++dnl # ++dnl # 5.8 API, ++dnl # __vmalloc PAGE_KERNEL removal ++dnl # ++AC_DEFUN([ZFS_AC_KERNEL_SRC_VMALLOC_PAGE_KERNEL], [ ++ ZFS_LINUX_TEST_SRC([__vmalloc], [ ++ #include <linux/mm.h> ++ #include <linux/vmalloc.h> ++ ],[ ++ void *p __attribute__ ((unused)); ++ ++ p = __vmalloc(0, GFP_KERNEL, PAGE_KERNEL); ++ ]) ++]) ++ ++AC_DEFUN([ZFS_AC_KERNEL_VMALLOC_PAGE_KERNEL], [ ++ AC_MSG_CHECKING([whether __vmalloc(ptr, flags, pageflags) is available]) ++ ZFS_LINUX_TEST_RESULT([__vmalloc], [ ++ AC_MSG_RESULT(yes) ++ AC_DEFINE(HAVE_VMALLOC_PAGE_KERNEL, 1, [__vmalloc page flags exists]) ++ ],[ ++ AC_MSG_RESULT(no) ++ ]) ++])
  7. Download patch debian/patches/4100-disable-bpool-upgrade.patch

    --- 0.8.4-1/debian/patches/4100-disable-bpool-upgrade.patch 1970-01-01 00:00:00.000000000 +0000 +++ 0.8.4-1ubuntu10/debian/patches/4100-disable-bpool-upgrade.patch 2020-06-04 12:53:20.000000000 +0000 @@ -0,0 +1,49 @@ +Description: Disable bpool upgrade + On ubuntu, upgrade of bpool is disabled to prevent users to break their + system by upgrading to features not supported by GRUB. +Author: Jean-Baptiste Lallement <jean.baptiste@ubuntu.com> + Didier Roche <didrocks@ubuntu.com> +Bug-Ubuntu: https://bugs.launchpad.net/bugs/1847389 +Forwarded: not-needed +Last-Update: 2020-04-14 +=================================================================== +Index: zfs-linux-0.8.4/cmd/zpool/zpool_main.c +=================================================================== +--- zfs-linux-0.8.4.orig/cmd/zpool/zpool_main.c ++++ zfs-linux-0.8.4/cmd/zpool/zpool_main.c +@@ -7991,6 +7991,16 @@ upgrade_enable_all(zpool_handle_t *zhp, + { + int i, ret, count; + boolean_t firstff = B_TRUE; ++ ++ // On ubuntu, upgrade of bpool is disabled to prevent users to break their ++ // system by upgrading to features not supported by GRUB ++ if (strcmp("bpool", zpool_get_name(zhp)) == 0) { ++ (void) fprintf(stderr, gettext("'zpool upgrade' is disabled for" ++ " 'bpool' to keep compatibility with GRUB.\n" ++ "Skipping upgrade.\n")); ++ return (0); ++ } ++ + nvlist_t *enabled = zpool_get_features(zhp); + + count = 0; +Index: zfs-linux-0.8.4/lib/libzfs/libzfs_status.c +=================================================================== +--- zfs-linux-0.8.4.orig/lib/libzfs/libzfs_status.c ++++ zfs-linux-0.8.4/lib/libzfs/libzfs_status.c +@@ -425,6 +425,14 @@ zpool_get_status(zpool_handle_t *zhp, ch + else + *msgid = zfs_msgid_table[ret]; + } ++ ++ // On Ubuntu GRUB is incompatible with newest features of zfs. In order to ++ // prevent people from upgrading bpool, the message to suggest to upgrade ++ // the pool is removed. ++ if (ret == ZPOOL_STATUS_FEAT_DISABLED && strcmp(zpool_get_name(zhp), "bpool") == 0) { ++ ret = ZPOOL_STATUS_OK; ++ } ++ + return (ret); + } +
  8. Download patch debian/patches/4521-enable-risc-v-isa.patch

    --- 0.8.4-1/debian/patches/4521-enable-risc-v-isa.patch 1970-01-01 00:00:00.000000000 +0000 +++ 0.8.4-1ubuntu10/debian/patches/4521-enable-risc-v-isa.patch 2020-07-21 09:01:10.000000000 +0000 @@ -0,0 +1,168 @@ +Index: zfs-linux-0.8.4/lib/libspl/include/sys/isa_defs.h +=================================================================== +--- zfs-linux-0.8.4.orig/lib/libspl/include/sys/isa_defs.h ++++ zfs-linux-0.8.4/lib/libspl/include/sys/isa_defs.h +@@ -192,10 +192,19 @@ extern "C" { + + #define _SUNOS_VTOC_16 + ++#elif defined(__riscv) ++ ++#define _LITTLE_ENDIAN ++#define _SUNOS_VTOC_16 ++ ++#ifndef _LP64 ++#define _ILP32 ++#endif ++ + #else + /* + * Currently supported: +- * x86_64, i386, arm, powerpc, s390, sparc, and mips ++ * x86_64, i386, arm, powerpc, s390, sparc, and mips, riscv64 + */ + #error "Unsupported ISA type" + #endif +Index: zfs-linux-0.8.4/lib/libefi/rdwr_efi.c +=================================================================== +--- zfs-linux-0.8.4.orig/lib/libefi/rdwr_efi.c ++++ zfs-linux-0.8.4/lib/libefi/rdwr_efi.c +@@ -156,7 +156,7 @@ struct dk_map2 default_vtoc_map[NDKMAP] + + #if defined(i386) || defined(__amd64) || defined(__arm) || \ + defined(__powerpc) || defined(__sparc) || defined(__s390__) || \ +- defined(__mips__) ++ defined(__mips__) || defined(__riscv) + { V_BOOT, V_UNMNT }, /* i - 8 */ + { V_ALTSCTR, 0 }, /* j - 9 */ + +Index: zfs-linux-0.8.4/include/spl/sys/isa_defs.h +=================================================================== +--- zfs-linux-0.8.4.orig/include/spl/sys/isa_defs.h ++++ zfs-linux-0.8.4/include/spl/sys/isa_defs.h +@@ -192,10 +192,24 @@ + */ + #define _ALIGNMENT_REQUIRED 1 + ++#elif defined(__riscv) ++ ++#define _LITTLE_ENDIAN ++#define _SUNOS_VTOC_16 ++ ++#ifndef _LP64 ++#define _ILP32 ++#endif ++ ++/* ++ * Illumos doesn't define _ALIGNMENT_REQUIRED for RISC-V, so default to 1 ++ * out of paranoia. ++ */ ++ + #else + /* + * Currently supported: +- * x86_64, i386, arm, powerpc, s390, sparc, and mips ++ * x86_64, i386, arm, powerpc, s390, sparc, mips and risc-v + */ + #error "Unsupported ISA type" + #endif +Index: zfs-linux-0.8.4/module/lua/ldo.c +=================================================================== +--- zfs-linux-0.8.4.orig/module/lua/ldo.c ++++ zfs-linux-0.8.4/module/lua/ldo.c +@@ -62,6 +62,8 @@ + #define JMP_BUF_CNT 12 + #elif defined(__s390x__) + #define JMP_BUF_CNT 18 ++#elif defined(__riscv) ++#define JMP_BUF_CNT 16 + #else + #define JMP_BUF_CNT 1 + #endif +Index: zfs-linux-0.8.4/module/lua/setjmp/setjmp.S +=================================================================== +--- zfs-linux-0.8.4.orig/module/lua/setjmp/setjmp.S ++++ zfs-linux-0.8.4/module/lua/setjmp/setjmp.S +@@ -14,4 +14,6 @@ + #include "setjmp_mips.S" + #elif defined(__s390x__) + #include "setjmp_s390x.S" ++#elif defined(__riscv) ++#include "setjmp_riscv64.S" + #endif +Index: zfs-linux-0.8.4/module/lua/setjmp/setjmp_riscv64.S +=================================================================== +--- /dev/null ++++ zfs-linux-0.8.4/module/lua/setjmp/setjmp_riscv64.S +@@ -0,0 +1,71 @@ ++/* ++ * Copyright (C) 2020 Canonical, Ltd. ++ * ++ * Permission is hereby granted, free of charge, to any person obtaining ++ * a copy of this software and associated documentation files (the ++ * "Software"), to deal in the Software without restriction, including ++ * without limitation the rights to use, copy, modify, merge, publish, ++ * distribute, sublicense, and/or sell copies of the Software, and to ++ * permit persons to whom the Software is furnished to do so, subject to ++ * the following conditions: ++ * ++ * The above copyright notice and this permission notice shall be ++ * included in all copies or substantial portions of the Software. ++ * ++ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, ++ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF ++ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. ++ * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY ++ * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, ++ * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE ++ * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ++ * ++ */ ++ .option pic ++ .text ++ .globl setjmp ++ .type setjmp, @function ++ ++setjmp: ++ sd s0, (0)(a0) ++ sd s1, (8)(a0) ++ sd s2, (16)(a0) ++ sd s3, (24)(a0) ++ sd s4, (32)(a0) ++ sd s5, (40)(a0) ++ sd s6, (48)(a0) ++ sd s7, (56)(a0) ++ sd s8, (64)(a0) ++ sd s9, (72)(a0) ++ sd s10, (80)(a0) ++ sd s11, (88)(a0) ++ sd ra, (96)(a0) ++ sd sp, (104)(a0) ++ li a0, 0 ++ ret ++ ++ .globl longjmp ++ .type longjmp, @function ++longjmp: ++ ld s0, (0)(a0) ++ ld s1, (8)(a0) ++ ld s2, (16)(a0) ++ ld s3, (24)(a0) ++ ld s4, (32)(a0) ++ ld s5, (40)(a0) ++ ld s6, (48)(a0) ++ ld s7, (56)(a0) ++ ld s8, (64)(a0) ++ ld s9, (72)(a0) ++ ld s10, (80)(a0) ++ ld s11, (88)(a0) ++ ld ra, (96)(a0) ++ ld sp, (104)(a0) ++ ++ beq a1, zero, longjmp_1 ++ mv a0, a1 ++ ret ++ ++longjmp_1: ++ li a0, 1 ++ ret
  9. Download patch debian/tests/control.ubuntu

    --- 0.8.4-1/debian/tests/control.ubuntu 2020-05-07 14:36:39.000000000 +0000 +++ 0.8.4-1ubuntu10/debian/tests/control.ubuntu 1970-01-01 00:00:00.000000000 +0000 @@ -1,7 +0,0 @@ -Tests: kernel-smoke-test -Restrictions: needs-root, isolation-machine -Depends: zfs-dkms [ amd64 arm64 ppc64el s390x ], - zfs-initramfs [ amd64 arm64 ppc64el s390x ], - zfs-test [ amd64 arm64 ppc64el s390x ], - zfs-zed [ amd64 arm64 ppc64el s390x ], - zfsutils-linux [ amd64 arm64 ppc64el s390x ]
  10. Download patch debian/patches/series

    --- 0.8.4-1/debian/patches/series 2020-05-13 01:49:43.000000000 +0000 +++ 0.8.4-1ubuntu10/debian/patches/series 2020-07-22 08:58:22.000000000 +0000 @@ -7,10 +7,17 @@ dont-symlink-zed-scripts.patch enable-zed.patch 1004-zed-service-bindir.patch 2100-zfs-load-module.patch -#2200-add-zfs-0.6.x-ioctl-compat-shim.patch +2200-add-zfs-0.6.x-ioctl-compat-shim.patch 3100-remove-libzfs-module-timeout.patch -#3302-Use-obj-m-instead-of-subdir-m.patch -#4000-zsys-support.patch -#4500-fix-generator-invalid-cache.patch +3302-Use-obj-m-instead-of-subdir-m.patch +4000-mount-encrypted-dataset-fix.patch +4000-zsys-support.patch +4100-disable-bpool-upgrade.patch force-verbose-rules.patch -#zfs-mount-container-start.patch +zfs-mount-container-start.patch +4510-silently-ignore-modprobe-failure.patch +git_fix_dependency_loop_encryption1.patch +git_fix_dependency_loop_encryption2.patch +4520-Linux-5.8-compat-__vmalloc.patch +4521-enable-risc-v-isa.patch +4620-zfs-vol-wait-fix-locked-encrypted-vols.patch
  11. Download patch debian/patches/git_fix_dependency_loop_encryption1.patch

    --- 0.8.4-1/debian/patches/git_fix_dependency_loop_encryption1.patch 1970-01-01 00:00:00.000000000 +0000 +++ 0.8.4-1ubuntu10/debian/patches/git_fix_dependency_loop_encryption1.patch 2020-06-10 08:47:36.000000000 +0000 @@ -0,0 +1,72 @@ +From 9f6280503d0960eed0994fdcef57c65dc1d481a4 Mon Sep 17 00:00:00 2001 +From: Richard Laager <rlaager@wiktel.com> +Date: Sat, 30 May 2020 18:40:45 -0500 +Subject: [PATCH 1/2] Fix a dependency loop + +When generating units with zfs-mount-generator, if the pool is already +imported, zfs-import.target is not needed. This avoids a dependency +loop on root-on-ZFS systems: + systemd-random-seed.service After (via RequiresMountsFor) + var-lib.mount After + zfs-import.target After + zfs-import-{cache,scan}.service After + cryptsetup.service After + systemd-random-seed.service + +Signed-off-by: Richard Laager <rlaager@wiktel.com> +--- + .../system-generators/zfs-mount-generator.in | 14 ++++++++++++++ + etc/systemd/system/zfs-mount.service.in | 1 - + 2 files changed, 14 insertions(+), 1 deletion(-) + +Index: zfs-linux-0.8.4/etc/systemd/system-generators/zfs-mount-generator.in +=================================================================== +--- zfs-linux-0.8.4.orig/etc/systemd/system-generators/zfs-mount-generator.in ++++ zfs-linux-0.8.4/etc/systemd/system-generators/zfs-mount-generator.in +@@ -74,6 +74,7 @@ else + do_fail "zero or three arguments required" + fi + ++pools=$(zpool list -H -o name) + + # All needed information about each ZFS is available from + # zfs list -H -t filesystem -o <properties> +@@ -90,6 +91,7 @@ process_line() { + # shellcheck disable=SC2086 + set -- $1 + dataset="${1}" ++ pool="${dataset%%/*}" + p_mountpoint="${2}" + p_canmount="${3}" + p_atime="${4}" +@@ -141,6 +143,18 @@ process_line() { + requiredmounts="RequiresMountsFor=${p_systemd_requiresmountsfor}" + fi + ++ # If the pool is already imported, zfs-import.target is not needed. This ++ # avoids a dependency loop on root-on-ZFS systems: ++ # systemd-random-seed.service After (via RequiresMountsFor) var-lib.mount ++ # After zfs-import.target After zfs-import-{cache,scan}.service After ++ # cryptsetup.service After systemd-random-seed.service. ++ for p in $pools ; do ++ if [ "$p" = "$pool" ] ; then ++ wants="" ++ break ++ fi ++ done ++ + # Handle encryption + if [ -n "${p_encroot}" ] && + [ "${p_encroot}" != "-" ] ; then +Index: zfs-linux-0.8.4/etc/systemd/system/zfs-mount.service.in +=================================================================== +--- zfs-linux-0.8.4.orig/etc/systemd/system/zfs-mount.service.in ++++ zfs-linux-0.8.4/etc/systemd/system/zfs-mount.service.in +@@ -6,7 +6,6 @@ After=systemd-udev-settle.service + After=zfs-import.target + After=systemd-remount-fs.service + Before=local-fs.target +-Before=systemd-random-seed.service + After=zfs-load-module.service + ConditionPathExists=/sys/module/zfs +
  12. Download patch debian/patches/4510-silently-ignore-modprobe-failure.patch

    --- 0.8.4-1/debian/patches/4510-silently-ignore-modprobe-failure.patch 1970-01-01 00:00:00.000000000 +0000 +++ 0.8.4-1ubuntu10/debian/patches/4510-silently-ignore-modprobe-failure.patch 2020-06-04 12:54:54.000000000 +0000 @@ -0,0 +1,33 @@ +Description: Don't fail if zfs modules can't load on package installation + Ideally, modprobe should be attempted but not fatal (LP: #1880421) +Author: Colin Ian King <colin.king@canonical.com> +Origin: ubuntu +Forwarded: no +Last-Update: 2020-06-04 + +Index: zfs-linux-0.8.4/etc/systemd/system/zfs-load-module.service.in +=================================================================== +--- zfs-linux-0.8.4.orig/etc/systemd/system/zfs-load-module.service.in ++++ zfs-linux-0.8.4/etc/systemd/system/zfs-load-module.service.in +@@ -10,7 +10,7 @@ After=systemd-remount-fs.service + [Service] + Type=oneshot + RemainAfterExit=yes +-ExecStart=/sbin/modprobe zfs ++ExecStart=-/sbin/modprobe zfs + + [Install] + WantedBy=zfs-mount.service +Index: zfs-linux-0.8.4/etc/systemd/system/zfs-share.service.in +=================================================================== +--- zfs-linux-0.8.4.orig/etc/systemd/system/zfs-share.service.in ++++ zfs-linux-0.8.4/etc/systemd/system/zfs-share.service.in +@@ -13,7 +13,7 @@ PartOf=smb.service + Type=oneshot + RemainAfterExit=yes + ExecStartPre=-/bin/rm -f /etc/dfs/sharetab +-ExecStart=@sbindir@/zfs share -a ++ExecStart=-@sbindir@/zfs share -a + + [Install] + WantedBy=zfs.target
  13. Download patch debian/libzfs2linux.symbols

    --- 0.8.4-1/debian/libzfs2linux.symbols 2020-05-07 14:36:39.000000000 +0000 +++ 0.8.4-1ubuntu10/debian/libzfs2linux.symbols 2020-07-21 09:01:10.000000000 +0000 @@ -33,8 +33,8 @@ libzfs.so.2 libzfs2linux #MINVER# atomic_and_64_nv@Base 0.8.2 atomic_and_8@Base 0.8.2 atomic_and_8_nv@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_and_long@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_and_long_nv@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_and_long@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_and_long_nv@Base 0.8.2 atomic_and_uchar@Base 0.8.2 atomic_and_uchar_nv@Base 0.8.2 atomic_and_uint@Base 0.8.2 @@ -61,8 +61,8 @@ libzfs.so.2 libzfs2linux #MINVER# atomic_dec_64_nv@Base 0.8.2 atomic_dec_8@Base 0.8.2 atomic_dec_8_nv@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_dec_long@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_dec_long_nv@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_dec_long@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_dec_long_nv@Base 0.8.2 atomic_dec_uchar@Base 0.8.2 atomic_dec_uchar_nv@Base 0.8.2 atomic_dec_uint@Base 0.8.2 @@ -79,8 +79,8 @@ libzfs.so.2 libzfs2linux #MINVER# atomic_inc_64_nv@Base 0.8.2 atomic_inc_8@Base 0.8.2 atomic_inc_8_nv@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_inc_long@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_inc_long_nv@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_inc_long@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_inc_long_nv@Base 0.8.2 atomic_inc_uchar@Base 0.8.2 atomic_inc_uchar_nv@Base 0.8.2 atomic_inc_uint@Base 0.8.2 @@ -89,7 +89,7 @@ libzfs.so.2 libzfs2linux #MINVER# atomic_inc_ulong_nv@Base 0.8.2 atomic_inc_ushort@Base 0.8.2 atomic_inc_ushort_nv@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_lock@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_lock@Base 0.8.2 atomic_or_16@Base 0.8.2 atomic_or_16_nv@Base 0.8.2 atomic_or_32@Base 0.8.2 @@ -98,8 +98,8 @@ libzfs.so.2 libzfs2linux #MINVER# atomic_or_64_nv@Base 0.8.2 atomic_or_8@Base 0.8.2 atomic_or_8_nv@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_or_long@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_or_long_nv@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_or_long@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_or_long_nv@Base 0.8.2 atomic_or_uchar@Base 0.8.2 atomic_or_uchar_nv@Base 0.8.2 atomic_or_uint@Base 0.8.2 @@ -152,11 +152,11 @@ libzfs.so.2 libzfs2linux #MINVER# avl_swap@Base 0.8.2 avl_walk@Base 0.8.2 buf@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)cas32@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)cas64@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)cas8@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)caslong@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)casptr@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)cas32@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)cas64@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)cas8@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)caslong@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)casptr@Base 0.8.2 changelist_free@Base 0.8.2 changelist_gather@Base 0.8.2 changelist_haszonedchild@Base 0.8.2
  14. Download patch debian/patches/git_fix_dependency_loop_encryption2.patch

    --- 0.8.4-1/debian/patches/git_fix_dependency_loop_encryption2.patch 1970-01-01 00:00:00.000000000 +0000 +++ 0.8.4-1ubuntu10/debian/patches/git_fix_dependency_loop_encryption2.patch 2020-06-19 14:17:05.000000000 +0000 @@ -0,0 +1,36 @@ +From dc4242bd2ebd2d80544d903fb612c1cf153e5497 Mon Sep 17 00:00:00 2001 +From: Richard Laager <rlaager@wiktel.com> +Date: Sat, 30 May 2020 20:39:31 -0500 +Subject: [PATCH 2/2] Fix another dependency loop + +zfs-load-key-DATASET.service was gaining an +After=systemd-journald.socket due to its stdout/stderr going to the +journal (which is the default). systemd-journald.socket has an After +(via RequiresMountsFor=/run/systemd/journal) on -.mount. If the root +filesystem is encrypted, -.mount gets an After +zfs-load-key-DATASET.service. + +By setting stdout and stderr to null on the key load services, we avoid +this loop. + +Signed-off-by: Richard Laager <rlaager@wiktel.com> +Closes: #10356 +--- + etc/systemd/system-generators/zfs-mount-generator.in | 4 ++++ + 1 file changed, 4 insertions(+) + +Index: zfs-linux-0.8.4/etc/systemd/system-generators/zfs-mount-generator.in +=================================================================== +--- zfs-linux-0.8.4.orig/etc/systemd/system-generators/zfs-mount-generator.in ++++ zfs-linux-0.8.4/etc/systemd/system-generators/zfs-mount-generator.in +@@ -280,6 +280,10 @@ ${automount_loadkey_extra_args} + [Service] + Type=oneshot + RemainAfterExit=yes ++# This avoids a dependency loop involving systemd-journald.socket if this ++# dataset is a parent of the root filesystem. ++StandardOutput=null ++StandardError=null + ExecStart=${keyloadcmd} + ExecStop=${keyunloadcmd}" > "${dest_norm}/${keyloadunit}" + fi
  15. Download patch debian/patches/4000-mount-encrypted-dataset-fix.patch

    --- 0.8.4-1/debian/patches/4000-mount-encrypted-dataset-fix.patch 1970-01-01 00:00:00.000000000 +0000 +++ 0.8.4-1ubuntu10/debian/patches/4000-mount-encrypted-dataset-fix.patch 2020-06-19 14:17:05.000000000 +0000 @@ -0,0 +1,88 @@ +Description: Improved mounting of encrypted dataset + Make unloading the key more robust. + The unit was failing instead of stopping if someone manually unloaded + the key before stopping the unit (zfs unload-key is failing on an + unavailable key). + Follow a similar logic than for loading the key, checking for the key + status before unloading it. + . + BindsTo dataset keyload unit to mount associate unit. + We need a stronger dependency between the mount unit and its keyload unit + when we know that the dataset is encrypted. + If the keyload unit fails, Wants= will still try to mount the dataset, + which will then fail. + It’s better to show that the failure is due to a dependency failing, the + keyload unit, by tighting up the dependency. We can do this as we know + that we generate both units in the generator and so, it’s not an + optional dependency. + BindsTo enable as well that if the keyload unit fails at any point, the + associated mountpoint will be then unmounted. + . + Ensure mount unit pilots when its ZFS key is loaded. + Drop Before=zfs.mount dependency explicitly on generated key-load .service + unit. + Indeed, the associated mount unit is After=<dataset-key-load>.service. + This is thus the mount point which controls at what point it wants to be + mounted (Before=zfs-mount.service in stock generator), but this can be + an automount point, or triggered by another service. + This additional dependency from the key load service is not needed thus. +Author: Jean-Baptiste Lallement <jean.baptiste@ubuntu.com> +Author: Didier Roche <didrocks@ubuntu.com> +Forwarded: https://github.com/openzfs/zfs/pull/10477 +Last-Update: 2020-06-19 +Index: zfs-linux-0.8.4/etc/systemd/system-generators/zfs-mount-generator.in +=================================================================== +--- a/etc/systemd/system-generators/zfs-mount-generator.in ++++ b/etc/systemd/system-generators/zfs-mount-generator.in +@@ -115,6 +115,7 @@ process_line() { + wants="zfs-import.target" + requires="" + requiredmounts="" ++ bindsto="" + wantedby="" + requiredby="" + noauto="off" +@@ -172,6 +173,12 @@ set -eu;\ + keystatus=\"\$\$(@sbindir@/zfs get -H -o value keystatus \"${dataset}\")\";\ + [ \"\$\$keystatus\" = \"unavailable\" ] || exit 0;\ + ${keyloadscript}'" ++ keyunloadcmd="\ ++/bin/sh -c '\ ++set -eu;\ ++keystatus=\"\$\$(@sbindir@/zfs get -H -o value keystatus \"${dataset}\")\";\ ++[ \"\$\$keystatus\" = \"available\" ] || exit 0;\ ++@sbindir@/zfs unload-key \"${dataset}\"'" + + + +@@ -191,7 +198,6 @@ Documentation=man:zfs-mount-generator(8) + DefaultDependencies=no + Wants=${wants} + After=${after} +-Before=${before} + ${requires} + ${keymountdep} + +@@ -199,11 +205,12 @@ ${keymountdep} + Type=oneshot + RemainAfterExit=yes + ExecStart=${keyloadcmd} +-ExecStop=@sbindir@/zfs unload-key '${dataset}'" > "${dest_norm}/${keyloadunit}" ++ExecStop=${keyunloadcmd}" > "${dest_norm}/${keyloadunit}" + fi + # Update the dependencies for the mount file to want the + # key-loading unit. +- wants="${wants} ${keyloadunit}" ++ wants="${wants}" ++ bindsto="BindsTo=${keyloadunit}" + after="${after} ${keyloadunit}" + fi + +@@ -414,6 +421,7 @@ Documentation=man:zfs-mount-generator(8) + Before=${before} + After=${after} + Wants=${wants} ++${bindsto} + ${requires} + ${requiredmounts} +
  16. Download patch debian/libuutil1linux.symbols

    --- 0.8.4-1/debian/libuutil1linux.symbols 2020-05-07 14:36:39.000000000 +0000 +++ 0.8.4-1ubuntu10/debian/libuutil1linux.symbols 2020-07-21 09:01:10.000000000 +0000 @@ -27,8 +27,8 @@ libuutil.so.1 libuutil1linux #MINVER# atomic_and_64_nv@Base 0.8.2 atomic_and_8@Base 0.8.2 atomic_and_8_nv@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_and_long@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_and_long_nv@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_and_long@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_and_long_nv@Base 0.8.2 atomic_and_uchar@Base 0.8.2 atomic_and_uchar_nv@Base 0.8.2 atomic_and_uint@Base 0.8.2 @@ -55,8 +55,8 @@ libuutil.so.1 libuutil1linux #MINVER# atomic_dec_64_nv@Base 0.8.2 atomic_dec_8@Base 0.8.2 atomic_dec_8_nv@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_dec_long@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_dec_long_nv@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_dec_long@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_dec_long_nv@Base 0.8.2 atomic_dec_uchar@Base 0.8.2 atomic_dec_uchar_nv@Base 0.8.2 atomic_dec_uint@Base 0.8.2 @@ -73,8 +73,8 @@ libuutil.so.1 libuutil1linux #MINVER# atomic_inc_64_nv@Base 0.8.2 atomic_inc_8@Base 0.8.2 atomic_inc_8_nv@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_inc_long@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_inc_long_nv@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_inc_long@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_inc_long_nv@Base 0.8.2 atomic_inc_uchar@Base 0.8.2 atomic_inc_uchar_nv@Base 0.8.2 atomic_inc_uint@Base 0.8.2 @@ -83,7 +83,7 @@ libuutil.so.1 libuutil1linux #MINVER# atomic_inc_ulong_nv@Base 0.8.2 atomic_inc_ushort@Base 0.8.2 atomic_inc_ushort_nv@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_lock@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_lock@Base 0.8.2 atomic_or_16@Base 0.8.2 atomic_or_16_nv@Base 0.8.2 atomic_or_32@Base 0.8.2 @@ -92,8 +92,8 @@ libuutil.so.1 libuutil1linux #MINVER# atomic_or_64_nv@Base 0.8.2 atomic_or_8@Base 0.8.2 atomic_or_8_nv@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_or_long@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_or_long_nv@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_or_long@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_or_long_nv@Base 0.8.2 atomic_or_uchar@Base 0.8.2 atomic_or_uchar_nv@Base 0.8.2 atomic_or_uint@Base 0.8.2 @@ -146,11 +146,11 @@ libuutil.so.1 libuutil1linux #MINVER# avl_swap@Base 0.8.2 avl_walk@Base 0.8.2 buf@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)cas32@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)cas64@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)cas8@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)caslong@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)casptr@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)cas32@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)cas64@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)cas8@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)caslong@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)casptr@Base 0.8.2 get_system_hostid@Base 0.8.2 getexecname@Base 0.8.2 getextmntent@Base 0.8.2
  17. Download patch debian/patches/4500-fix-generator-invalid-cache.patch

    --- 0.8.4-1/debian/patches/4500-fix-generator-invalid-cache.patch 2020-05-07 14:36:39.000000000 +0000 +++ 0.8.4-1ubuntu10/debian/patches/4500-fix-generator-invalid-cache.patch 1970-01-01 00:00:00.000000000 +0000 @@ -1,54 +0,0 @@ -Description: Regenerate cache file if empty - There is a race between empty cache file for the mount generator - and fstab which contains /boot/grub. - With zfs on root, the generator is the only solution to avoid races. - However in 0.8 it misses cache invalidation (when rollbacking or booting - on other datasets). - This is a workaround for the first boot with empty files to ensure we - initialize it properly. A more complete work on cache invalidation needs - to be done upstream. -Author: Didier Roche <didrocks@ubuntu.com> -Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/zfs-linux/+bug/1845606 -Forwarded: Not-needed -Index: zfs-linux-0.8.3/etc/systemd/system-generators/zfs-mount-generator.in -=================================================================== ---- zfs-linux-0.8.3.orig/etc/systemd/system-generators/zfs-mount-generator.in -+++ zfs-linux-0.8.3/etc/systemd/system-generators/zfs-mount-generator.in -@@ -278,6 +278,9 @@ on_exit() { - done - } - -+PROPS="name,mountpoint,canmount,atime,relatime,devices,exec,readonly" -+PROPS="${PROPS},setuid,nbmand" -+ - # TODO: we should move that in its own script, and use a systemd service as a fallback. - # We need to condition this on current vs previous dataset (across the whole system), so - # in /boot. -@@ -295,9 +298,6 @@ initzsys() { - all_pools="$(zpool list | awk '{if (NR>1) print $1}')" - ${ZSYS} boot-prepare - -- PROPS="name,mountpoint,canmount,atime,relatime,devices,exec,readonly" -- PROPS="${PROPS},setuid,nbmand" -- - for cachefile in "${FSLIST}/"* ; do - pool=`basename $cachefile` - fs_pools="${fs_pools} ${pool}" -@@ -309,6 +309,17 @@ initzsys - - # Feed each line into process_line - for cachefile in "${FSLIST}/"* ; do -+ # FIXME: we need to ensure that pools are imported because some pools, like -+ # bpool, should be imported and mounted before /boot/grub (via fstab). -+ # For some reasons, the bpool isn't imported (not in cache). -+ pool=`basename ${cachefile}` -+ ${ZPOOL} import "${pool}" || true -+ -+ # If the cache file is empty for a pool, reload it -+ if [ ! -s "${cachefile}" ]; then -+ ${ZFS} list -H -t filesystem -o $PROPS -r "${pool}" > "${cachefile}" -+ fi -+ - while read -r fs ; do - process_line "${fs}" - done < "${cachefile}"
  18. Download patch debian/libzpool2linux.symbols

    --- 0.8.4-1/debian/libzpool2linux.symbols 2020-05-13 02:00:26.000000000 +0000 +++ 0.8.4-1ubuntu10/debian/libzpool2linux.symbols 2020-07-21 09:01:10.000000000 +0000 @@ -219,8 +219,8 @@ libzpool.so.2 libzpool2linux #MINVER# atomic_and_64_nv@Base 0.8.2 atomic_and_8@Base 0.8.2 atomic_and_8_nv@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_and_long@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_and_long_nv@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_and_long@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_and_long_nv@Base 0.8.2 atomic_and_uchar@Base 0.8.2 atomic_and_uchar_nv@Base 0.8.2 atomic_and_uint@Base 0.8.2 @@ -247,8 +247,8 @@ libzpool.so.2 libzpool2linux #MINVER# atomic_dec_64_nv@Base 0.8.2 atomic_dec_8@Base 0.8.2 atomic_dec_8_nv@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_dec_long@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_dec_long_nv@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_dec_long@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_dec_long_nv@Base 0.8.2 atomic_dec_uchar@Base 0.8.2 atomic_dec_uchar_nv@Base 0.8.2 atomic_dec_uint@Base 0.8.2 @@ -265,8 +265,8 @@ libzpool.so.2 libzpool2linux #MINVER# atomic_inc_64_nv@Base 0.8.2 atomic_inc_8@Base 0.8.2 atomic_inc_8_nv@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_inc_long@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_inc_long_nv@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_inc_long@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_inc_long_nv@Base 0.8.2 atomic_inc_uchar@Base 0.8.2 atomic_inc_uchar_nv@Base 0.8.2 atomic_inc_uint@Base 0.8.2 @@ -275,7 +275,7 @@ libzpool.so.2 libzpool2linux #MINVER# atomic_inc_ulong_nv@Base 0.8.2 atomic_inc_ushort@Base 0.8.2 atomic_inc_ushort_nv@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_lock@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_lock@Base 0.8.2 atomic_or_16@Base 0.8.2 atomic_or_16_nv@Base 0.8.2 atomic_or_32@Base 0.8.2 @@ -284,8 +284,8 @@ libzpool.so.2 libzpool2linux #MINVER# atomic_or_64_nv@Base 0.8.2 atomic_or_8@Base 0.8.2 atomic_or_8_nv@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_or_long@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)atomic_or_long_nv@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_or_long@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)atomic_or_long_nv@Base 0.8.2 atomic_or_uchar@Base 0.8.2 atomic_or_uchar_nv@Base 0.8.2 atomic_or_uint@Base 0.8.2 @@ -375,11 +375,11 @@ libzpool.so.2 libzpool2linux #MINVER# byteswap_uint64_array@Base 0.8.2 byteswap_uint8_array@Base 0.8.2 calculate_ccm_mac@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)cas32@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)cas64@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)cas8@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)caslong@Base 0.8.2 - (arch=s390x ppc64el arm64 armhf armel mips64el mipsel)casptr@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)cas32@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)cas64@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)cas8@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)caslong@Base 0.8.2 + (arch=s390x ppc64el arm64 armhf armel mips64el mipsel riscv64)casptr@Base 0.8.2 cbc_alloc_ctx@Base 0.8.2 cbc_decrypt_contiguous_blocks@Base 0.8.2 cbc_encrypt_contiguous_blocks@Base 0.8.2
  1. network-manager
  2. zfs-linux