74 Commits

Author SHA1 Message Date
Fabian Grünbichler b03175e961 bump version to 0.7.3-pve1 2017-11-06 09:15:19 +01:00
Fabian Grünbichler cc88cf22d1 update SPL submodule to 0.7.3-1 2017-11-06 09:12:42 +01:00
Fabian Grünbichler f07031b9ab add workaround for NS issue
tracked upstream in #6800, full fix/user NS compatibility not yet
available.

https://github.com/zfsonlinux/zfs/issues/6800
2017-11-06 09:04:37 +01:00
Fabian Grünbichler af05210837 refresh and drop patches
most have been applied upstream
2017-11-06 09:03:30 +01:00
Fabian Grünbichler c542769d74 update ZFS submodule to 0.7.3-1 2017-11-06 08:56:51 +01:00
Fabian Grünbichler 2ce263d24d bump version to 0.7.2-pve1
and add new zfs-test deb
2017-10-13 11:32:02 +02:00
Fabian Grünbichler 38b6b3a10d build: whitespace cleanup 2017-10-13 11:32:02 +02:00
Fabian Grünbichler 65fc6d785f zfs: add PR 6616 - compatibility with 0.6.5 2017-10-13 11:32:02 +02:00
Fabian Grünbichler f2be26ec96 zfs: add PR 6695
don't accidently skip over objects which should be freed
2017-10-13 11:32:02 +02:00
Fabian Grünbichler e2f4edc81e zfs: add various small fixes 2017-10-13 11:32:02 +02:00
Fabian Grünbichler 3c99d2a035 zfs: split test suite into zfs-test package 2017-10-13 11:32:02 +02:00
Fabian Grünbichler 3264cfc5e7 zfs: drop patch applied upstream 2017-10-12 13:23:57 +02:00
Fabian Grünbichler bdc71736c4 spl: add man page cleanup patches 2017-10-12 13:19:24 +02:00
Fabian Grünbichler 11fac95726 update SPL and ZFS sources to 0.7.2 2017-10-12 13:18:47 +02:00
Fabian Grünbichler 012341487f bump ZFS version to 0.6.5.11-pve18 2017-10-02 09:31:03 +02:00
Fabian Grünbichler ea927859d2 fix #1509: arc_summary error with L2ARC 2017-10-02 09:30:14 +02:00
Fabian Grünbichler e6fdafd565 build: remove old source tar balls and download target
they are not used anymore
2017-08-25 09:28:12 +02:00
Fabian Grünbichler 4c3d639686 bump version to 0.6.5.17-pve16/0.6.5.11-pve10 2017-08-07 15:28:34 +02:00
Fabian Grünbichler 8a19f2ad5d buildsys: switch to submodules 2017-08-07 15:28:34 +02:00
Fabian Grünbichler 56d9662c48 buildsys: add zfs-debian and spl-debian submodules 2017-08-07 15:28:34 +02:00
Fabian Grünbichler a59077893a drop patches applied upstream 2017-07-27 13:14:15 +02:00
Fabian Grünbichler 4156449701 update sources to 0.6.5.11-1 2017-07-27 13:10:29 +02:00
Fabian Grünbichler 8dbff718a0 update dkms removal patches
to reflect that we don't need DKMS for building.
2017-07-27 12:29:31 +02:00
Fabian Grünbichler 58a974f8f0 buildsys: add deb target 2017-07-27 12:09:16 +02:00
Fabian Grünbichler 1e88a70802 buildsys: clean up *.buildinfo 2017-03-10 10:50:09 +01:00
Fabian Grünbichler 59653d92a8 bump versions to -pve16~bpo90/pve-9~bpo90 2017-03-10 09:50:37 +01:00
Fabian Grünbichler a5dfd38639 buildsys: no longer build transitional packages 2017-03-10 09:50:37 +01:00
Fabian Grünbichler 100fba2dff drop patches no longer needed for stretch 2017-03-10 09:50:37 +01:00
Fabian Grünbichler eee857a82b buildsys: update make upload target for stretch 2017-03-10 09:37:21 +01:00
Fabian Grünbichler 33edb24418 bump version to 0.6.5.9-pve15~bpo80/-pve8~bpo80 2017-02-07 13:33:33 +01:00
Fabian Grünbichler 2d5ff41105 refresh patches
and manage them as rebasing patch queue branch
2017-02-07 13:33:32 +01:00
Fabian Grünbichler d93bc1b005 update sources to debian/0.6.5.9-1 2017-02-07 13:33:28 +01:00
Fabian Grünbichler 18708aae25 bump zfs version to 0.6.5.8-pve14~bpo80 2017-01-11 09:35:44 +01:00
Fabian Grünbichler 904f90c739 revert python changes
these changes are a bit disruptive for a minor version bump,
postpone until PVE 5.0 packages + upgrade notes.
2017-01-11 09:34:02 +01:00
Fabian Grünbichler 81f5dae8f7 update zfs source to 0.6.5.8-3 2017-01-11 09:32:25 +01:00
Fabian Grünbichler 7bfc3db5e1 bump zfs version to 0.6.5.8-pve13 2016-10-27 11:26:37 +02:00
Fabian Grünbichler 49f86653f1 fix #1184: zfs-share.service has wrong path to 'rm' command 2016-10-27 11:25:24 +02:00
Fabian Grünbichler 3474a9b46b bump version to 0.6.5.8-pve12~bpo80 2016-10-24 13:49:06 +02:00
Fabian Grünbichler d0b125705d import with '-d /dev/disk/by-id' in systemd service 2016-10-24 13:48:46 +02:00
Fabian Grünbichler 8a287a137b bump version to 0.6.5.8-pve11/-pve7 2016-10-20 15:11:32 +02:00
Fabian Grünbichler 00d871a78a add transitional packages and relations for upgrades 2016-10-20 15:11:32 +02:00
Fabian Grünbichler 23db36409e switch pkg source to Debian Jessie
update to 0.6.5.8
drop unneeded patches
refresh no-DKMS and no-dracut patches
2016-10-19 10:48:58 +02:00
Fabian Grünbichler d72bef5bd3 update make upload target 2016-06-28 09:59:50 +02:00
Fabian Grünbichler b894a06c2c bump versions, update changelogs 2016-06-28 09:51:10 +02:00
Fabian Grünbichler 0b15456e05 update zfs/spl source archives 2016-06-28 09:50:45 +02:00
Fabian Grünbichler 2aba4528fd update to zfs/spl 0.6.5.7
update versioning scheme for backwards compatibility /
upgrade paths
2016-06-28 09:48:19 +02:00
Dietmar Maurer 00c2573479 bump spl package version to 0.6.5-pve5~jessie 2016-04-15 11:12:46 +02:00
Dietmar Maurer 531bc89e39 update spl sources 2016-04-15 11:10:47 +02:00
Fabian Grünbichler de76987c78 Make patches unfuzzy 2016-04-15 11:06:44 +02:00
Fabian Grünbichler 8155ecfe17 Update pkg-spl to jessie/0.6.5.6-3 2016-04-15 11:03:55 +02:00
Dietmar Maurer c5aee9e4ce Update to pkg-zfs jessie/0.6.5.6-3 2016-04-12 09:53:56 +02:00
Fabian Grünbichler 03ab644074 Update to pkg-zfs jessie/0.6.5.6-3
drop cherry-pick workarounds

drop unneeded/non-upstream pull requests:
- #1099: iSCSI support for ZoL
- #1476: Change sharesmb to use REGISTRY shares for better
  control by user/admin
- #2790: Rewrite of nfs.c to keep options per host separated.
- #3238: Allow "zfs unshare <proto> -a" much like "zfs share
  <proto> -a" (WIP)
2016-04-12 09:49:28 +02:00
Dietmar Maurer acef550f8d update sources to 0.6.5.6 2016-03-30 10:50:40 +02:00
Fabian Grünbichler c7fd7e24f5 Update to zfs/spl 0.6.5.6 2016-03-30 10:47:25 +02:00
Thomas Lamprecht d064c14aad fix cherry-picking relevant 0.6.5.4 changes
When cherry-picking range A..B the commit A won't get cherry picked,
only the commits after A.
To fix that use range A^..B as ^ selects the previous commit.

This fixes the build of zfs with linux kernel version 4.4 as one
compatibility change commit wasn't included.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2016-02-04 18:20:51 +01:00
Dietmar Maurer 8d62a89482 update to 0.6.5.4 2016-01-14 11:28:08 +01:00
Dietmar Maurer 5a1f030de3 Prepare to tag zfs-0.6.5.3
So finally this is a full update to 0.6.5.3, but we skipped the sysv
init related patch:

  zfs-import: Perform verbatim import using cache file

We use systemd, so those updates are pointless.
2015-11-05 07:22:46 +01:00
Dietmar Maurer bc3a2de1e1 include important patches from 0.6.5.3 2015-11-04 17:43:26 +01:00
Dietmar Maurer 944a4708cf update to master/debian/jessie/0.6.5.2-2 2015-10-05 18:00:17 +02:00
Dietmar Maurer 3435683847 do not install sysv init scripts
to avoid double startup with systemd
2015-09-29 11:55:27 +02:00
Dietmar Maurer 64d186b910 adopt fix-dh-installinit.patch for latest upstream changes 2015-09-24 13:11:56 +02:00
Dietmar Maurer eb4bd3cde8 update pkg-zfs to master/debian/jessie/0.6.5.1-4 2015-09-24 12:47:22 +02:00
Dietmar Maurer c6ed1ff858 update to 0.6.5.1 2015-09-21 10:05:21 +02:00
Dietmar Maurer 20bb0ecfa0 updates from upstream
spl: snapshot/debian/jessie/0.6.4-8-8ac6ff
zfs: snapshot/debian/jessie/0.6.4-24-6bec43
2015-08-24 06:27:18 +02:00
Dietmar Maurer 1c1a906890 avoid warnings with update-rc.d 2015-07-21 11:48:23 +02:00
Dietmar Maurer 787716f74d update to update to 0.6.4.2 2015-07-21 11:28:52 +02:00
Dietmar Maurer 46e32ac3b7 fix upload (remove zfs-dbg package) 2015-04-14 10:40:56 +02:00
Dietmar Maurer f5c66275b3 remove stale patches 2015-04-14 10:37:18 +02:00
Dietmar Maurer e479455eaf update to 0.6.4 2015-04-14 10:28:07 +02:00
Dietmar Maurer 10b48f6191 ignore zfs-import-scan errors
zpool import return error if we have no zfs pools. We want to ignore that.
2015-03-31 17:54:03 +02:00
Dietmar Maurer 09b78d33bc bump zfs package version to 0.6.3-pve2~jessie 2015-03-15 15:54:13 +01:00
Dietmar Maurer 2335fd5207 use systemd 2015-03-15 15:52:02 +01:00
Dietmar Maurer 9959b4fc3a depend on sudo
zfs bash completions use sudo
2015-03-02 08:15:34 +01:00
Dietmar Maurer 5ce963e7da recompile for jessie 2015-02-28 16:27:35 +01:00
70 changed files with 995 additions and 3750 deletions
+6
View File
@@ -0,0 +1,6 @@
[submodule "zfs-debian"]
path = zfs-debian
url = ../mirror_zfs-debian
[submodule "spl-debian"]
path = spl-debian
url = ../mirror_spl-debian
+49 -65
View File
@@ -1,67 +1,74 @@
RELEASE=3.3
RELEASE=5.1
# source form https://github.com/zfsonlinux/
ZFSVER=0.6.3-1.2
ZFSPKGREL=2~wheezy
SPLPKGREL=1~wheezy
ZFSPKGVER=0.6.3-${ZFSPKGREL}
SPLPKGVER=0.6.3-${SPLPKGREL}
ZFSVER=0.7.3
ZFSPKGREL=pve1~bpo9
SPLPKGREL=pve1~bpo9
ZFSPKGVER=${ZFSVER}-${ZFSPKGREL}
SPLPKGVER=${ZFSVER}-${SPLPKGREL}
SPLDIR=spl-spl-${ZFSVER}
SPLSRC=spl-${ZFSVER}.tar.gz
ZFSDIR=zfs-zfs-${ZFSVER}
ZFSSRC=zfs-${ZFSVER}.tar.gz
SPLDIR=spl-build
SPLSRC=spl-debian
ZFSDIR=zfs-build
ZFSSRC=zfs-debian
SPL_DEBS= \
SPL_DEBS= \
spl_${SPLPKGVER}_amd64.deb
ZFS_DEBS= \
libnvpair1_${ZFSPKGVER}_amd64.deb \
libuutil1_${ZFSPKGVER}_amd64.deb \
libzfs2_${ZFSPKGVER}_amd64.deb \
libzfs-dev_${ZFSPKGVER}_amd64.deb \
libzpool2_${ZFSPKGVER}_amd64.deb \
zfs-doc_${ZFSPKGVER}_amd64.deb \
zfs-initramfs_${ZFSPKGVER}_amd64.deb \
zfsutils_${ZFSPKGVER}_amd64.deb
ZFS_DEBS= \
libnvpair1linux_${ZFSPKGVER}_amd64.deb \
libuutil1linux_${ZFSPKGVER}_amd64.deb \
libzfs2linux_${ZFSPKGVER}_amd64.deb \
libzfslinux-dev_${ZFSPKGVER}_amd64.deb \
libzpool2linux_${ZFSPKGVER}_amd64.deb \
zfs-dbg_${ZFSPKGVER}_amd64.deb \
zfs-zed_${ZFSPKGVER}_amd64.deb \
zfs-initramfs_${ZFSPKGVER}_all.deb \
zfs-test_${ZFSPKGVER}_amd64.deb \
zfsutils-linux_${ZFSPKGVER}_amd64.deb
DEBS=${SPL_DEBS} ${ZFS_DEBS}
DEBS=${SPL_DEBS} ${ZFS_DEBS}
all: ${DEBS}
all: deb
deb: ${DEBS}
.PHONY: dinstall
dinstall: ${DEBS}
dpkg -i ${DEBS}
.PHONY: submodule
submodule:
test -f "${ZFSSRC}/debian/changelog" || git submodule update --init
test -f "${SPLSRC}/debian/changelog" || git submodule update --init
.PHONY: spl
spl ${SPL_DEBS}: ${SPLSRC}
rm -rf ${SPLDIR}
tar xf ${SPLSRC}
cp -a spl-debian-pve ${SPLDIR}/debian
cd ${SPLDIR}; dpkg-buildpackage -b -uc -us
mkdir ${SPLDIR}
cp -a ${SPLSRC}/* ${SPLDIR}/
mv ${SPLDIR}/debian/changelog ${SPLDIR}/debian/changelog.org
cat spl-changelog.Debian ${SPLDIR}/debian/changelog.org > ${SPLDIR}/debian/changelog
cd ${SPLDIR}; ln -s ../spl-patches patches
cd ${SPLDIR}; quilt push -a
cd ${SPLDIR}; rm -rf .pc ./patches
cd ${SPLDIR}; dpkg-buildpackage -b -uc -us
.PHONY: zfs
zfs ${ZFS_DEBS}: ${ZFSSRC}
zfs ${ZFS_DEBS} ${ZFS_TRANS_DEBS}: ${ZFSSRC}
rm -rf ${ZFSDIR}
tar xf ${ZFSSRC}
cp -a zfs-debian-pve ${ZFSDIR}/debian
cd ${ZFSDIR}; dpkg-buildpackage -b -uc -us
.PHONY: download
download:
#git clone https://github.com/zfsonlinux/pkg-spl.git
#git clone https://github.com/zfsonlinux/pkg-zfs.git
##git checkout master/ubuntu/precise
##git checkout master/debian/wheezy
rm spl-*.tar.gz
rm zfs-*.tar.gz
wget https://github.com/zfsonlinux/spl/archive/${SPLSRC}
wget https://github.com/zfsonlinux/zfs/archive/${ZFSSRC}
mkdir ${ZFSDIR}
cp -a ${ZFSSRC}/* ${ZFSDIR}/
mv ${ZFSDIR}/debian/changelog ${ZFSDIR}/debian/changelog.org
cat zfs-changelog.Debian ${ZFSDIR}/debian/changelog.org > ${ZFSDIR}/debian/changelog
cd ${ZFSDIR}; ln -s ../zfs-patches patches
cd ${ZFSDIR}; quilt push -a
cd ${ZFSDIR}; rm -rf .pc ./patches
cd ${ZFSDIR}; dpkg-buildpackage -b -uc -us
.PHONY: clean
clean:
rm -rf *~ *.deb *.changes ${ZFSDIR} ${SPLDIR}
rm -rf *~ *.deb *.changes *.buildinfo ${ZFSDIR} ${SPLDIR}
.PHONY: distclean
distclean: clean
@@ -69,27 +76,4 @@ distclean: clean
.PHONY: upload
upload: ${DEBS}
umount /pve/${RELEASE}; mount /pve/${RELEASE} -o rw
mkdir -p /pve/${RELEASE}/extra
rm -f /pve/${RELEASE}/extra/spl_*.deb
rm -f /pve/${RELEASE}/extra/spl-dkms_*.deb
rm -f /pve/${RELEASE}/extra/libnvpair1_*.deb
rm -f /pve/${RELEASE}/extra/libnvpair1-dbg_*.deb
rm -f /pve/${RELEASE}/extra/libuutil1_*.deb
rm -f /pve/${RELEASE}/extra/libuutil1-dbg_*.deb
rm -f /pve/${RELEASE}/extra/libzfs2_*.deb
rm -f /pve/${RELEASE}/extra/libzfs2-dbg_*.deb
rm -f /pve/${RELEASE}/extra/libzfs-dev_*.deb
rm -f /pve/${RELEASE}/extra/libzpool2_*.deb
rm -f /pve/${RELEASE}/extra/libzpool2-dbg_*.deb
rm -f /pve/${RELEASE}/extra/zfs_*.deb
rm -f /pve/${RELEASE}/extra/zfs-dkms_*.deb
rm -f /pve/${RELEASE}/extra/zfs-doc_*.deb
rm -f /pve/${RELEASE}/extra/zfs-initramfs_*.deb
rm -f /pve/${RELEASE}/extra/zfsutils_*.deb
rm -f /pve/${RELEASE}/extra/zfsutils-dbg_*.deb
rm -f /pve/${RELEASE}/extra/Packages*
cp ${DEBS} /pve/${RELEASE}/extra
cd /pve/${RELEASE}/extra; dpkg-scanpackages . /dev/null > Packages; gzip -9c Packages > Packages.gz
umount /pve/${RELEASE}; mount /pve/${RELEASE} -o ro
tar -cf - ${DEBS} | ssh repoman@repo.proxmox.com -- upload --product pve --dist stretch --arch amd64
+4 -4
View File
@@ -1,13 +1,13 @@
Proxmox VE packaging for ZFS on Linux
This is based of code from:
This is based on code from:
https://github.com/zfsonlinux/pkg-spl.git
https://github.com/zfsonlinux/pkg-zfs.git
We merged updates from the precice branch into the older wheezy
branch.
We removed the dkms/modules related code, because we ship the
modules with the kernel.
For licensing questions, see:
http://open-zfs.org/wiki/Talk:FAQ
http://open-zfs.org/wiki/Talk:FAQ
Binary file not shown.
+108
View File
@@ -0,0 +1,108 @@
spl-linux (0.7.3-pve1~bpo9) unstable; urgency=medium
* update spl to 0.7.3
-- Proxmox Support Team <support@proxmox.com> Mon, 6 Nov 2017 09:14:19 +0100
spl-linux (0.7.2-pve1~bpo90) unstable; urgency=medium
* update spl to 0.7.2
* clean up man pages
-- Proxmox Support Team <support@proxmox.com> Thu, 12 Oct 2017 13:33:04 +0200
spl-linux (0.6.5.11-pve10~bpo90) unstable; urgency=medium
* update spl to debian/0.6.5.11-1
-- Proxmox Support Team <support@proxmox.com> Thu, 27 Jul 2017 13:11:45 +0200
spl-linux (0.6.5.9-pve9~bpo90) unstable; urgency=medium
* rebuild for PVE 5.0 / Debian Stretch
-- Proxmox Support Team <support@proxmox.com> Fri, 10 Mar 2017 09:45:52 +0100
spl-linux (0.6.5.9-pve8~bpo80) unstable; urgency=medium
* update spl to debian/0.6.5.9-1
-- Proxmox Support Team <support@proxmox.com> Mon, 6 Feb 2017 12:39:35 +0100
spl-linux (0.6.5.8-pve7~bpo80) unstable; urgency=medium
* update spl to debian/0.6.5.8-2
* switch package upstream sources to Debian (Jessie)
-- Proxmox Support Team <support@proxmox.com> Wed, 12 Oct 2016 11:16:02 +0200
spl-linux (0.6.5.7-pve6~bpo80) unstable; urgency=medium
* update pkg-spl to jessie/0.6.5.7-5
* change package versioning to allow upgrades from PVE3/wheezy
-- Proxmox Support Team <support@proxmox.com> Tue, 28 Jun 2016 09:50:00 +0200
spl-linux (0.6.5-pve5~jessie) unstable; urgency=medium
* Update pkg-spl to jessie/0.6.5.6-3
-- Proxmox Support Team <support@proxmox.com> Fri, 15 Apr 2016 11:11:59 +0200
spl-linux (0.6.5-pve4~jessie) unstable; urgency=medium
* update to 0.6.5.6
-- Proxmox Support Team <support@proxmox.com> Wed, 30 Mar 2016 10:49:49 +0200
spl-linux (0.6.5-pve3~jessie) unstable; urgency=medium
* update to 0.6.5.4
-- Proxmox Support Team <support@proxmox.com> Thu, 14 Jan 2016 11:00:40 +0100
spl-linux (0.6.5-pve2~jessie) unstable; urgency=medium
* update to 0.6.5.3
-- Proxmox Support Team <support@proxmox.com> Wed, 04 Nov 2015 17:40:58 +0100
spl-linux (0.6.5-pve1~jessie) unstable; urgency=medium
* update to master/debian/jessie/0.6.5-1
-- Proxmox Support Team <support@proxmox.com> Mon, 21 Sep 2015 10:04:23 +0200
spl-linux (0.6.4-pve3~jessie) unstable; urgency=medium
* update to snapshot/debian/jessie/0.6.4-8-8ac6ff
-- Proxmox Support Team <support@proxmox.com> Mon, 24 Aug 2015 06:14:12 +0200
spl-linux (0.6.4-pve2~jessie) unstable; urgency=medium
* update to 0.6.4.2 (snapshot/debian/jessie/0.6.4-6-37d7cd)
-- Proxmox Support Team <support@proxmox.com> Tue, 21 Jul 2015 11:02:31 +0200
spl-linux (0.6.4-pve1~jessie) unstable; urgency=medium
* update to 0.6.4 (use upstream zol package definitions)
-- Proxmox Support Team <support@proxmox.com> Tue, 14 Apr 2015 10:17:26 +0200
spl-linux (0.6.3-pve1~jessie) unstable; urgency=medium
* recompile for jessie
-- Proxmox Support Team <support@proxmox.com> Sat, 28 Feb 2015 16:03:01 +0100
spl-linux (0.6.3-pve1~wheezy) unstable; urgency=low
* first version for Proxmox VE
-- Proxmox Support Team <support@proxmox.com> Sat, 10 Jan 2015 14:06:34 +0100
Submodule
+1
Submodule spl-debian added at 785f8eda81
-6
View File
@@ -1,6 +0,0 @@
spl-linux (0.6.3-1~wheezy) unstable; urgency=low
* first version for Proxmox VE
-- Proxmox Support Team <support@proxmox.com> Sat, 10 Jan 2015 14:06:34 +0100
-1
View File
@@ -1 +0,0 @@
7
-34
View File
@@ -1,34 +0,0 @@
Source: spl-linux
Section: kernel
Priority: extra
Maintainer: Proxmox Support Team <support@proxmox.com>
Build-Depends: autotools-dev,
autoconf,
autogen,
automake,
debhelper (>= 8),
dh-autoreconf,
dkms (>= 2.2.0.2),
libtool,
Standards-Version: 3.9.5
Homepage: http://www.zfsonlinux.org/
Package: spl-dkms
Architecture: all
Depends: ${misc:Depends}, dkms (>= 2.2.0.2), file, lsb-release
Recommends: spl
Description: Solaris Porting Layer kernel modules for Linux
The Solaris Porting Layer (SPL) is a Linux kernel module which provides many of
the Solaris kernel APIs. This shim layer makes it possible to run Solaris
kernel code in the Linux kernel with relatively minimal modification.
.
The Solaris Porting LAyer Tests (SPLAT) is a Linux kernel module which provides
a testing harness for the SPL module.
Package: spl
Architecture: any
Conflicts: spl-dev
Depends: ${shlibs:Depends}, ${misc:Depends}
Description: Solaris Porting Layer utilities for Linux
This package provides the userspace utilities for the SPL and SPLAT Linux
kernel modules.
-147
View File
@@ -1,147 +0,0 @@
Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
Upstream-Name: Solaris Porting Layer for Linux
Upstream-Contact: Brian Behlendorf <behlendorf1@llnl.gov>
Source: https://github.com/zfsonlinux/zfs/
Disclaimer:
This work was produced at the Lawrence Livermore National Laboratory
(LLNL) under Contract No. DE-AC52-07NA27344 (Contract 44) between
the U.S. Department of Energy (DOE) and Lawrence Livermore National
Security, LLC (LLNS) for the operation of LLNL.
.
This work was prepared as an account of work sponsored by an agency of
the United States Government. Neither the United States Government nor
Lawrence Livermore National Security, LLC nor any of their employees,
makes any warranty, express or implied, or assumes any liability or
responsibility for the accuracy, completeness, or usefulness of any
information, apparatus, product, or process disclosed, or represents
that its use would not infringe privately-owned rights.
.
Reference herein to any specific commercial products, process, or
services by trade name, trademark, manufacturer or otherwise does
not necessarily constitute or imply its endorsement, recommendation,
or favoring by the United States Government or Lawrence Livermore
National Security, LLC. The views and opinions of authors expressed
herein do not necessarily state or reflect those of the Untied States
Government or Lawrence Livermore National Security, LLC, and shall
not be used for advertising or product endorsement purposes.
Files: *
Copyright: Lawrence Livermore National Security, LLC.
The Regents of the University of California
License: GPL-2+
Files: config/config.guess
Copyright: Free Software Foundation, Inc.
License: GPL-2+
Files: config/config.sub
Copyright: Free Software Foundation, Inc.
License: GPL-2+
Files: config/deb.am
Copyright: Lawrence Livermore National Security, LLC.
License: GPL-2+
Files: config/depcomp
Copyright: Free Software Foundation, Inc.
License: GPL-2+
Files: config/install-sh
Copyright: 1994 X Consortium
License:
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
X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNEC-
TION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
.
Except as contained in this notice, the name of the X Consortium shall not
be used in advertising or otherwise to promote the sale, use or other deal-
ings in this Software without prior written authorization from the X Consor-
tium.
Files: config/ltmain.sh
Copyright: Free Software Foundation, Inc.
License: GPL-2+
Files: config/missing
Copyright: Free Software Foundation, Inc.
License: GPL-2+
Files: config/tgz.am
Copyright: Lawrence Livermore National Security, LLC.
License: GPL-2+
Files: debian/*
Copyright: Darik Horn <dajhorn@vanadac.com>
Source: https://github.com/dajhorn/pkg-spl/
License: GPL-2+
Files: include/linux/zlib_compat.h
Copyright: Lawrence Livermore National Security, LLC.
License: GPL-2+
Files: include/rpc/xdr.h
Copyright: Sun Microsystems, Inc.
License: GPL-2+
Files: include/sys/extdirent.h
Copyright: Lawrence Livermore National Security, LLC.
License: GPL-2+
Files: include/sys/fcntl.h
Copyright: Lawrence Livermore National Security, LLC.
License: GPL-2+
Files: include/sys/idmap.h
Copyright: Lawrence Livermore National Security, LLC.
License: GPL-2+
Files: include/sys/tsd.h
Copyright: Lawrence Livermore National Security, LLC.
License: GPL-2+
Files: include/sys/zmod.h
Copyright: Jean-loup Gailly
Mark Adler
License:
This software is provided 'as-is', without any express or implied
warranty. In no event will the authors be held liable for any damages
arising from the use of this software.
.
Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter it and redistribute it
freely, subject to the following restrictions:
.
1. The origin of this software must not be misrepresented; you must not
claim that you wrote the original software. If you use this software
in a product, an acknowledgment in the product documentation would be
appreciated but is not required.
.
2. Altered source versions must be plainly marked as such, and must not be
misrepresented as being the original software.
.
3. This notice may not be removed or altered from any source distribution.
Files: module/spl/spl-tsd.c
Copyright: Lawrence Livermore National Security, LLC.
License: GPL-2+
Files: module/spl/spl-xdr.c
Copyright: Sun Microsystems, Inc.
License: GPL-2+
Files: module/splat/splat-linux.c
Copyright: Lawrence Livermore National Security, LLC.
License: GPL-2+
-35
View File
@@ -1,35 +0,0 @@
AUTOINSTALL="yes"
PACKAGE_NAME="spl"
PACKAGE_VERSION="#MODULE_VERSION#"
PRE_BUILD="configure
--prefix=/usr
--with-config=kernel
--with-linux=$(case `lsb_release -is` in
(Debian)
if [ -e ${kernel_source_dir/%build/source} ]
then
echo ${kernel_source_dir/%build/source}
else
# This is a kpkg exception for Proxmox 2.0
echo ${kernel_source_dir}
fi
;;
(*)
echo ${kernel_source_dir}
;;
esac)
--with-linux-obj=${kernel_source_dir}
"
POST_INSTALL="cp
${dkms_tree}/${PACKAGE_NAME}/${PACKAGE_VERSION}/build/spl_config.h
${dkms_tree}/${PACKAGE_NAME}/${PACKAGE_VERSION}/build/module/Module.symvers
${dkms_tree}/${PACKAGE_NAME}/${PACKAGE_VERSION}/${kernelver}/${arch}/
"
REMAKE_INITRD="no"
MAKE[0]="make"
BUILT_MODULE_NAME[0]="spl"
BUILT_MODULE_LOCATION[0]="module/spl/"
DEST_MODULE_LOCATION[0]="/extra/spl/spl"
BUILT_MODULE_NAME[1]="splat"
BUILT_MODULE_LOCATION[1]="module/splat/"
DEST_MODULE_LOCATION[1]="/extra/splat/splat"
@@ -1,28 +0,0 @@
From 7559daf38acc293474d3d2a13ecf746bc7507a11 Mon Sep 17 00:00:00 2001
From: Darik Horn <dajhorn@vanadac.com>
Date: Tue, 11 Oct 2011 18:32:58 -0500
Subject: [PATCH 1/2] Revert "Remove /etc/hostid missing warning"
This reverts commit 6b3b569df30d13ed7bbbff877cffc71290a52f12.
---
module/spl/spl-generic.c | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
Index: b/module/spl/spl-generic.c
===================================================================
--- a/module/spl/spl-generic.c
+++ b/module/spl/spl-generic.c
@@ -471,8 +471,12 @@
file = kobj_open_file(spl_hostid_path);
- if (file == (struct _buf *)-1)
+ if (file == (struct _buf *)-1) {
+ printk(KERN_WARNING
+ "SPL: The %s file is not found.\n",
+ spl_hostid_path);
return -1;
+ }
result = kobj_get_filesize(file, &size);
-1
View File
@@ -1 +0,0 @@
0001-Revert-Remove-etc-hostid-missing-warning.patch
-63
View File
@@ -1,63 +0,0 @@
#!/usr/bin/make -f
NAME := $(shell awk '$$1 == "Name:" { print $$2; }' META)
VERSION := $(shell dpkg-parsechangelog \
| awk '$$1 == "Version:" { print $$2; }' | cut -d- -f1)
REVISION := $(shell dpkg-parsechangelog \
| awk '$$1 == "Version:" { print $$2; }' | cut -d- -f2-)
%:
dh $@ --with autoreconf
override_dh_auto_configure:
@# Embed the downstream version in the module.
@sed \
-e 's/^Version:.*/Version: $(VERSION)/' \
-e 's/^Release:.*/Release: $(REVISION)/' \
-i.orig META
@# Create the makefiles and configure script.
./autogen.sh
@# Build the userland, but don't build the kernel modules.
dh_auto_configure -- --with-config=user
override_dh_auto_test:
# scripts/check.sh tries insmod and rmmod, so it cannot
# run in an unprivileged build environment.
override_dh_auto_install:
@# Install the utilities.
make install DESTDIR='$(CURDIR)/debian/tmp'
@# Create a dummy hostid file for the zfs-initramfs package.
@# NB: Commentary in the spl.postinst script.
mkdir -p '$(CURDIR)/debian/tmp/etc/'
/usr/bin/printf '\xFF\xFF\xFF\xFF' >'$(CURDIR)/debian/tmp/etc/hostid'
@# Get a bare copy of the source code.
@# This creates the $(CURDIR)/$(NAME)-$(VERSION)/ tree.
make distdir
@# Delete boilerplate to satisfy the lintian extra-license-file check.
rm '$(CURDIR)/$(NAME)-$(VERSION)/COPYING'
@# This shunt allows DKMS to install the Module.symvers and spl_config.h
@# files to the ${dkms_tree} area through the POST_INSTALL directive.
echo '#!/bin/sh' >'$(CURDIR)/$(NAME)-$(VERSION)/cp'
echo 'cp "$$@"' >>'$(CURDIR)/$(NAME)-$(VERSION)/cp'
chmod 755 '$(CURDIR)/$(NAME)-$(VERSION)/cp'
# Install the DKMS source.
mkdir -p '$(CURDIR)/debian/tmp/usr/src/'
mv '$(CURDIR)/$(NAME)-$(VERSION)' '$(CURDIR)/debian/tmp/usr/src/'
# Install the dkms.conf file.
dh_dkms -V $(VERSION)
override_dh_auto_clean:
dh_auto_clean
@if test -e META.orig; then mv META.orig META; fi
%:
dh $@
-3
View File
@@ -1,3 +0,0 @@
usr/src/spl-*/AUTHORS usr/share/doc/spl-dkms/
usr/src/spl-*/DISCLAIMER usr/share/doc/spl-dkms/
usr/src
-3
View File
@@ -1,3 +0,0 @@
#!/bin/sh -e
#DEBHELPER#
-3
View File
@@ -1,3 +0,0 @@
#!/bin/sh -e
#DEBHELPER#
-3
View File
@@ -1,3 +0,0 @@
etc/hostid
usr/sbin
usr/share/man
-59
View File
@@ -1,59 +0,0 @@
#!/bin/sh -e
# The hostname and hostid of the last system to access a ZFS pool are stored in
# the ZFS pool itself. A pool is foreign if, during `zpool import`, the
# current hostname and hostid are different than the stored values thereof.
#
# The hostname and hostid on Solaris are intrinsic, but they are not on Linux,
# so the spl kernel module invokes /bin/hostname and /usr/bin/hostid from the
# userland in its initialization routine.
#
# However, these two indentifiers are usually undefined in the Linux initramfs
# environment, so the /etc/hostname and /etc/hostid files must be added to the
# initrd. Things like a DHCP lease change can affect the hostid too.
#
# ZFS requires stable values for hostname and hostid, but basic Linux systems
# do not. The hostid is therefore stabilized by creating the /etc/hostid file
# in the regular environment if it does not already exist. An undefined
# hostname is usuallly stable.
#
# Neither /etc/hostname nor /etc/hostid are controlled configuration files in
# Debian distributions, but the spl package nevertheless installs a dummy
# /etc/hostid file that contains the HW_INVALID_HOSTID sentinal value so that
# the package manager will track it.
# This result is always an eight-character hexadecimal number sans the 0x
# prefix. Remember that /usr/bin/hostid generates a value if the /etc/hostid
# file doesn't exist or is malformed.
HOSTID=$(hostid)
if [ -f /etc/hostid -a "0x$HOSTID" != "0xffffffff" ]
then
# This system already has a stable hostid.
exit 0
fi
# Truncate the dummy file and generate the actual system hostid.
: >/etc/hostid
HOSTID=$(hostid)
# @TODO: Check whether this method is appropriate for gethostid(2) on big
# endian systems. (Update: It isn't.)
#
# The /etc/hostname file on i386 and amd64 systems must be a little endian
# integer of exacly four bytes. Regardless, a consistent hostid is more
# important than a correct byte order here.
# Conveniences like a ${HOSTID:$ii:2} substring range or a `sed` one-liner
# are prohibited here because this file must be dash-compatible by policy.
AA=$(echo $HOSTID | cut -b 1,2)
BB=$(echo $HOSTID | cut -b 3,4)
CC=$(echo $HOSTID | cut -b 5,6)
DD=$(echo $HOSTID | cut -b 7,8)
# Invoke the external printf because the dash builtin lacks the byte format.
"$(which printf)" "\x$DD\x$CC\x$BB\x$AA" >"/etc/hostid"
# @ASSERT: [ "$HOSTID" = "$(hostid)" ]
#DEBHELPER#
@@ -0,0 +1,163 @@
From 9cb5edffe475c25c4132aace431ffc6a97531583 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Fabian=20Gr=C3=BCnbichler?= <f.gruenbichler@proxmox.com>
Date: Wed, 12 Oct 2016 10:57:39 +0200
Subject: [PATCH 1/3] remove DKMS and module build
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
---
debian/control.in | 24 --------------------
debian/control | 1 -
debian/rules | 68 +------------------------------------------------------
3 files changed, 1 insertion(+), 92 deletions(-)
diff --git a/debian/control.in b/debian/control.in
index 52c1660..dc6ee96 100644
--- a/debian/control.in
+++ b/debian/control.in
@@ -8,40 +8,16 @@ Build-Depends: autogen,
autotools-dev,
debhelper (>= 9),
dh-autoreconf,
- dkms (>> 2.2.0.2-1~),
libtool
Standards-Version: 3.9.8
Homepage: http://www.zfsonlinux.org/
Vcs-Git: git://anonscm.debian.org/pkg-zfsonlinux/spl.git
Vcs-Browser: http://anonscm.debian.org/gitweb/?p=pkg-zfsonlinux/spl.git
-Package: spl-dkms
-Architecture: all
-Depends: dkms (>> 2.2.1.0), file, libc-dev, lsb-release, ${misc:Depends}
-Recommends: spl (>= ${source:Upstream-Version})
-Provides: spl-modules
-Description: Solaris Porting Layer kernel modules for Linux
- The Solaris Porting Layer (SPL) is a Linux kernel module which provides
- many of the Solaris kernel APIs. This shim layer makes it possible to
- run Solaris kernel code in the Linux kernel with relatively minimal
- modification. The Solaris Porting LAyer Tests (SPLAT) is a Linux kernel
- module which provides a testing harness for the SPL module.
- .
- SPL can be particularly useful when you want to track upstream Illumos
- (or any other OpenSolaris fork) development closely and don't want the
- overhead of maintaining a large patch which converts Solaris primitives
- to Linux primitives.
- .
- This package contains the source code for the SPL and SPLAT Linux kernel
- modules, which can be used with DKMS, so that local kernel modules are
- automatically built and installed every time the kernel packages are
- upgraded.
-
Package: spl
Architecture: linux-any
Conflicts: spl-dev, splat
Depends: ${misc:Depends}, ${shlibs:Depends}
-Recommends: spl-modules | spl-dkms
Description: Solaris Porting Layer user-space utilities for Linux
The Solaris Porting Layer (SPL) is a Linux kernel module which provides
many of the Solaris kernel APIs. This shim layer makes it possible to
diff --git a/debian/control b/debian/control
index 52c1660..e055965 100644
--- a/debian/control
+++ b/debian/control
@@ -8,7 +8,6 @@ Build-Depends: autogen,
autotools-dev,
debhelper (>= 9),
dh-autoreconf,
- dkms (>> 2.2.0.2-1~),
libtool
Standards-Version: 3.9.8
Homepage: http://www.zfsonlinux.org/
diff --git a/debian/rules b/debian/rules
index b2fc86c..a474ca4 100755
--- a/debian/rules
+++ b/debian/rules
@@ -14,12 +14,8 @@ ifndef KVERS
KVERS=$(shell uname -r)
endif
-non_epoch_version=$(shell echo $(KVERS) | perl -pe 's/^\d+://')
-PACKAGE=spl
-pmodules = $(PACKAGE)-modules-$(non_epoch_version)
-
%:
- dh $@ --with dkms,autoreconf --parallel
+ dh $@ --with autoreconf --parallel
override_dh_auto_configure:
@cp debian/control.in debian/control
@@ -45,69 +41,7 @@ override_dh_auto_install:
@# This creates the $(CURDIR)/$(NAME)-$(VERSION)/ tree.
$(MAKE) distdir
- @# This shunt allows DKMS to install the Module.symvers and spl_config.h
- @# files to the ${dkms_tree} area through the POST_INSTALL directive.
- echo '#!/bin/sh' >'$(CURDIR)/$(NAME)-$(VERSION)/cp'
- echo 'cp "$$@"' >>'$(CURDIR)/$(NAME)-$(VERSION)/cp'
- chmod 755 '$(CURDIR)/$(NAME)-$(VERSION)/cp'
-
- # Install the DKMS source.
- mkdir -p '$(CURDIR)/debian/tmp/usr/src/'
- mv '$(CURDIR)/$(NAME)-$(VERSION)' '$(CURDIR)/debian/tmp/usr/src/'
-
-override_dh_dkms:
- dh_dkms -V $(VERSION)
-
override_dh_auto_clean:
dh_auto_clean
@if test -e META.orig; then mv META.orig META; fi
cp debian/control.in debian/control
-
-# ------------
-
-override_dh_prep-deb-files:
- for templ in $(wildcard $(CURDIR)/debian/*_KVERS_*.in); do \
- sed -e 's/##KVERS##/$(KVERS)/g ; s/#KVERS#/$(KVERS)/g ; s/_KVERS_/$(KVERS)/g ; s/##KDREV##/$(KDREV)/g ; s/#KDREV#/$(KDREV)/g ; s/_KDREV_/$(KDREV)/g ; s/_ARCH_/$(DEB_HOST_ARCH)/g' \
- < $$templ > `echo $$templ | sed -e 's/_KVERS_/$(KVERS)/g ; s/_ARCH_/$(DEB_HOST_ARCH)/g ; s/\.in$$//'` ; \
- done
- sed -e 's/##KVERS##/$(KVERS)/g ; s/#KVERS#/$(KVERS)/g ; s/_KVERS_/$(KVERS)/g ; s/##KDREV##/$(KDREV)/g ; s/#KDREV#/$(KDREV)/g ; s/_KDREV_/$(KDREV)/g ; s/_ARCH_/$(DEB_HOST_ARCH)/g' \
- < debian/control.modules.in > debian/control
-
-override_dh_configure_modules: override_dh_configure_modules_stamp
-override_dh_configure_modules_stamp:
- ./configure --with-config=kernel --with-linux=$(KSRC) \
- --with-linux-obj=$(KOBJ) \
- --disable-debug-kmem
- touch override_dh_configure_modules_stamp
-
-override_dh_binary-modules-udeb: override_dh_prep-deb-files override_dh_configure_modules
- dh_testdir
- dh_testroot
- dh_prep
-
- $(MAKE) -C $(CURDIR)/module modules
-
- dh_installdirs -p${pmodules}-di
- dh_install -p${pmodules}-di
- dh_gencontrol -p${pmodules}-di
-
- dh_builddeb -p${pmodules}-di
-
-override_dh_binary-modules: override_dh_prep-deb-files override_dh_configure_modules
- dh_testdir
- dh_testroot
- dh_prep
-
- $(MAKE) -C $(CURDIR)/module modules
-
- dh_installdocs -p${pmodules}
- dh_install -p${pmodules}
- dh_installchangelogs -p${pmodules}
- dh_compress -p${pmodules}
- dh_strip -p${pmodules}
- dh_fixperms -p${pmodules}
- dh_installdeb -p${pmodules}
- dh_gencontrol -p${pmodules}
- dh_md5sums -p${pmodules}
-
- dh_builddeb -p${pmodules}
--
2.14.1
@@ -0,0 +1,55 @@
From b414fa1353cac23e1d58d3fbdd1c48a7925bdbdb Mon Sep 17 00:00:00 2001
From: Fabian-Gruenbichler <f.gruenbichler@proxmox.com>
Date: Fri, 11 Aug 2017 00:21:54 +0200
Subject: [PATCH 2/3] splat.1 manpage: fix spelling of 'hexadecimal'
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Reviewed-by: George Melikov <mail@gmelikov.ru>
Reviewed-by: Giuseppe Di Natale <dinatale2@llnl.gov>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes #642
(cherry picked from commit a02fa347b75266f40c8f571d7d63a21ec7f6f13d)
Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
---
man/man1/splat.1 | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/man/man1/splat.1 b/man/man1/splat.1
index 37f8435..407680b 100644
--- a/man/man1/splat.1
+++ b/man/man1/splat.1
@@ -32,7 +32,7 @@ Print the usage message.
.BI "\-l" "" ", \-\-list" ""
.IP
For each spl.ko subsystem, print all available test names and
-hexidecimal identifiers with a short description.
+hexadecimal identifiers with a short description.
.HP
.BI "\-t" " subsystem" ":" "test" ", \-\-test" " subsystem" ":" "test"
.HP
@@ -42,9 +42,9 @@ Run the \fItest\fR diagnostic routine for the spl.ko \fIsubsystem\fR.
Specify this option more than once to run multiple tests.
The \fItest\fR and \fIsubsystem\fR parameters are the names or
-hexidecimal identifiers returned by the \fBsplat --list\fR command.
+hexadecimal identifiers returned by the \fBsplat --list\fR command.
-If \fIsubsystem\fR is a name and not a hexidecimal identifier, then the
+If \fIsubsystem\fR is a name and not a hexadecimal identifier, then the
\fBall\fR keyword can be used to run all available \fIsubsystem\fR
tests.
@@ -73,7 +73,7 @@ Test the kernel compression and queue waiting facilities:
# splat --test zlib:compress/uncompress --test taskq:wait
.LP
This is the same as the previous command, except that the subsystems
-and tests are referenced by hexidecimal identifier instead of by name:
+and tests are referenced by hexadecimal identifier instead of by name:
.IP
# splat -t 0x0f00:0x0f01 -t 0x0200:0x0204
--
2.14.1
@@ -0,0 +1,38 @@
From cb03b1234f9e3645fb731fdbeb5ba12f0013caa8 Mon Sep 17 00:00:00 2001
From: Fabian-Gruenbichler <f.gruenbichler@proxmox.com>
Date: Fri, 11 Aug 2017 00:22:31 +0200
Subject: [PATCH 3/3] spl-module-parameters.5 manpage: fix macro
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
There is no '.sh' macro in troff/groff/man, only '.SH' for section
headers. I assume .sp for a line break was intended here like
in the rest of the man page.
Reviewed-by: George Melikov <mail@gmelikov.ru>
Reviewed-by: Giuseppe Di Natale <dinatale2@llnl.gov>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes #643
(cherry picked from commit 945b7f1c63e3a12d08349afb986b7dfaca370222)
Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
---
man/man5/spl-module-parameters.5 | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/man/man5/spl-module-parameters.5 b/man/man5/spl-module-parameters.5
index 97241fd..e151144 100644
--- a/man/man5/spl-module-parameters.5
+++ b/man/man5/spl-module-parameters.5
@@ -153,7 +153,7 @@ function takes a single global lock over the entire virtual address range
which serializes all allocations. Using slightly different allocation
functions for small and large objects allows us to handle a wide range of
object sizes.
-.sh
+.sp
The \fBspl_kmem_cache_kmem_limit\fR value is used to determine this cutoff
size. One quarter the PAGE_SIZE is used as the default value because
\fBspl_kmem_cache_obj_per_slab\fR defaults to 16. This means that at
--
2.14.1
+3
View File
@@ -0,0 +1,3 @@
0001-remove-DKMS-and-module-build.patch
0002-splat.1-manpage-fix-spelling-of-hexadecimal.patch
0003-spl-module-parameters.5-manpage-fix-macro.patch
Binary file not shown.
+195
View File
@@ -0,0 +1,195 @@
zfs-linux (0.7.3-pve1~bpo9) unstable; urgency=medium
* update ZFS to 0.7.3
* include fix for user namespace setgid issue (#6800 upstream)
-- Proxmox Support Team <support@proxmox.com> Mon, 6 Nov 2017 09:14:19 +0100
zfs-linux (0.7.2-pve1~bpo90) unstable; urgency=medium
* update zfs to 0.7.2
* add PR 6616 - zfs send/recv compatibility with 0.6.5
* add PR 6695 - zfs recv: don't skip over objects which should be freed
* various small fixes
* split test suite into zfs-test package
-- Proxmox Support Team <support@proxmox.com> Thu, 12 Oct 2017 13:34:05 +0200
zfs-linux (0.6.5.11-pve18~bpo90) unstable; urgency=medium
* fix #1509: arc_summary error with L2ARC
-- Proxmox Support Team <support@proxmox.com> Mon, 2 Oct 2017 09:30:41 +0200
zfs-linux (0.6.5.11-pve17~bpo90) unstable; urgency=medium
* update zfs to debian/0.6.5.11-1
-- Proxmox Support Team <support@proxmox.com> Thu, 27 Jul 2017 13:11:45 +0200
zfs-linux (0.6.5.9-pve16~bpo90) unstable; urgency=medium
* drop transitional packages
* convert python scripts to python 3, drop .py suffix
* rebuild for PVE 5.0 / Debian Stretch
-- Proxmox Support Team <support@proxmox.com> Fri, 10 Mar 2017 09:45:52 +0100
zfs-linux (0.6.5.9-pve15~bpo80) unstable; urgency=medium
* update zfs to debian/0.6.5.9-1
-- Proxmox Support Team <support@proxmox.com> Mon, 6 Feb 2017 12:39:10 +0100
zfs-linux (0.6.5.8-pve14~bpo80) unstable; urgency=medium
* update zfs to debian/0.6.5.8-3
-- Proxmox Support Team <support@proxmox.com> Wed, 11 Jan 2017 09:34:58 +0100
zfs-linux (0.6.5.8-pve13~bpo80) unstable; urgency=medium
* fix #1184: zfs-share.service has wrong path to 'rm' command
-- Proxmox Support Team <support@proxmox.com> Thu, 27 Oct 2016 11:25:47 +0200
zfs-linux (0.6.5.8-pve12~bpo80) unstable; urgency=medium
* import with "-d /dev/disk/by-id" in systemd service
-- Proxmox Support Team <support@proxmox.com> Mon, 24 Oct 2016 13:48:08 +0200
zfs-linux (0.6.5.8-pve11~bpo80) unstable; urgency=medium
* update zfs to debian/0.6.5.8-1
* switch package upstream sources to Debian (Jessie)
* add transitional packages for upgrades
-- Proxmox Support Team <support@proxmox.com> Wed, 12 Oct 2016 11:16:02 +0200
zfs-linux (0.6.5.7-pve10~bpo80) unstable; urgency=medium
* update to pkg-zfs jessie/0.6.5.7-8
* change package versioning to allow upgrades from PVE3/wheezy
-- Proxmox Support Team <support@proxmox.com> Tue, 28 Jun 2016 09:50:00 +0200
zfs-linux (0.6.5-pve9~jessie) unstable; urgency=medium
* Update to pkg-zfs jessie/0.6.5.6-3
-- Proxmox Support Team <support@proxmox.com> Tue, 12 Apr 2016 09:51:35 +0200
zfs-linux (0.6.5-pve8~jessie) unstable; urgency=medium
* update to zfs-0.6.5.6
-- Proxmox Support Team <support@proxmox.com> Wed, 30 Mar 2016 10:50:22 +0200
zfs-linux (0.6.5-pve7~jessie) unstable; urgency=medium
* update to zfs-0.6.5.4
-- Proxmox Support Team <support@proxmox.com> Thu, 14 Jan 2016 10:51:17 +0100
zfs-linux (0.6.5-pve6~jessie) unstable; urgency=medium
* Prepare to tag zfs-0.6.5.3
-- Proxmox Support Team <support@proxmox.com> Thu, 05 Nov 2015 07:21:44 +0100
zfs-linux (0.6.5-pve5~jessie) unstable; urgency=medium
* Illumos 6267 - dn_bonus evicted too early
* Fix use-after-free in vdev_disk_physio_completion
-- Proxmox Support Team <support@proxmox.com> Wed, 04 Nov 2015 17:42:42 +0100
zfs-linux (0.6.5-pve4~jessie) unstable; urgency=medium
* update to master/debian/jessie/0.6.5.2-2
-- Proxmox Support Team <support@proxmox.com> Mon, 05 Oct 2015 17:56:45 +0200
zfs-linux (0.6.5-pve3~jessie) unstable; urgency=medium
* do not install /etc/init.d/zfs-zed script to avoid double startup
with systemd
-- Proxmox Support Team <support@proxmox.com> Mon, 28 Sep 2015 10:14:40 +0200
zfs-linux (0.6.5-pve2~jessie) unstable; urgency=medium
* update to master/debian/jessie/0.6.5.1-4
-- Proxmox Support Team <support@proxmox.com> Thu, 24 Sep 2015 12:45:33 +0200
zfs-linux (0.6.5-pve1~jessie) unstable; urgency=medium
* update to master/debian/jessie/0.6.5.1-2
-- Proxmox Support Team <support@proxmox.com> Mon, 21 Sep 2015 10:02:41 +0200
zfs-linux (0.6.4-pve3~jessie) unstable; urgency=medium
* update to snapshot/debian/jessie/0.6.4-24-6bec43
-- Proxmox Support Team <support@proxmox.com> Mon, 24 Aug 2015 06:13:44 +0200
zfs-linux (0.6.4-pve2~jessie) unstable; urgency=medium
* update to 0.6.4.2 (snapshot/debian/jessie/0.6.4-21-53b1d9)
-- Proxmox Support Team <support@proxmox.com> Tue, 21 Jul 2015 11:03:21 +0200
zfs-linux (0.6.4-pve1~jessie) unstable; urgency=medium
* update to 0.6.4 (use upstream zol package definitions)
-- Proxmox Support Team <support@proxmox.com> Tue, 14 Apr 2015 10:19:22 +0200
zfs-linux (0.6.3-pve3~jessie) unstable; urgency=medium
* ignore zfs-import-scan errors
-- Proxmox Support Team <support@proxmox.com> Tue, 31 Mar 2015 17:52:40 +0200
zfs-linux (0.6.3-pve2~jessie) unstable; urgency=medium
* use systemd for service startup
* install zed configuration file /etc/zfs/zed.d/zed.rc
-- Proxmox Support Team <support@proxmox.com> Sun, 15 Mar 2015 15:52:54 +0100
zfs-linux (0.6.3-pve1~jessie) unstable; urgency=medium
* recompile on jessie
-- Proxmox Support Team <support@proxmox.com> Sat, 28 Feb 2015 16:02:08 +0100
zfs-linux (0.6.3-2~wheezy) unstable; urgency=low
* use /sbin/modprobe to avoid warning inside initrd
* fix warning about undefined values inside initrd
-- Proxmox Support Team <support@proxmox.com> Wed, 14 Jan 2015 19:03:04 +0100
zfs-linux (0.6.3-1~wheezy) unstable; urgency=low
* first version for Proxmox VE
-- Proxmox Support Team <support@proxmox.com> Sat, 10 Jan 2015 14:06:34 +0100
Submodule
+1
Submodule zfs-debian added at ab6f41b56c
-14
View File
@@ -1,14 +0,0 @@
zfs-linux (0.6.3-2~wheezy) unstable; urgency=low
* use /sbin/modprobe to avoid warning inside initrd
* fix warning about undefined values inside initrd
-- Proxmox Support Team <support@proxmox.com> Wed, 14 Jan 2015 19:03:04 +0100
zfs-linux (0.6.3-1~wheezy) unstable; urgency=low
* first version for Proxmox VE
-- Proxmox Support Team <support@proxmox.com> Sat, 10 Jan 2015 14:06:34 +0100
-1
View File
@@ -1 +0,0 @@
7
-178
View File
@@ -1,178 +0,0 @@
Source: zfs-linux
Section: kernel
Priority: extra
Maintainer: Proxmox Support Team <support@proxmox.com>
Build-Depends: autotools-dev,
autoconf,
autogen,
automake,
debhelper (>= 8),
dh-autoreconf,
dkms (>= 2.2.0.2),
libselinux1-dev,
libtool,
uuid-dev,
zlib1g-dev,
Standards-Version: 3.9.5
Package: libnvpair1
Section: libs
Architecture: linux-any
Depends: ${misc:Depends}, ${shlibs:Depends}
Replaces: libnvpair0
Description: Solaris name-value library for Linux
This library provides routines for packing and unpacking nv pairs for
transporting data across process boundaries, transporting between
kernel and userland, and possibly saving onto disk files.
Package: libnvpair1-dbg
Section: debug
Architecture: linux-any
Depends: ${misc:Depends}, libnvpair1 (= ${binary:Version})
Replaces: libnvpair0-dbg
Description: Debugging symbols for libnvpair1
This library provides routines for packing and unpacking nv pairs for
transporting data across process boundaries, transporting between
kernel and userland, and possibly saving onto disk files.
.
This package contains the debugging symbols for libnvpair1.
Package: libuutil1
Section: libs
Architecture: linux-any
Depends: ${misc:Depends}, ${shlibs:Depends}
Replaces: libuutil0
Description: Solaris userland utility library for Linux
This library provides a variety of glue functions for OpenZFS on Linux:
* libspl: The Solaris Porting Layer library, which provides APIs that make it
possible to run Solaris user code in a Linux environment with relatively
minimal modification.
* libavl: The Adelson-Velskii Landis balanced binary tree manipulation
library.
* libefi: The Extensible Firmware Interface library for GUID disk
partitioning.
* libshare: NFS and SMB service integration for OpenZFS.
Package: libuutil1-dbg
Section: debug
Architecture: linux-any
Depends: ${misc:Depends}, libuutil1 (= ${binary:Version})
Replaces: libuutil0-dbg
Description: Debugging symbols for libuutil1
This library provides a variety of glue functions for OpenZFS on Linux:
* libspl: The Solaris Porting Layer library, which provides APIs that make it
possible to run Solaris user code in a Linux environment with relatively
minimal modification.
* libavl: The Adelson-Velskii Landis balanced binary tree manipulation
library.
* libefi: The Extensible Firmware Interface library for GUID disk
partitioning.
* libshare: NFS and SMB service integration for OpenZFS.
.
This package contains debugging symbols for libuutil1.
Package: libzfs-dev
Section: libdevel
Architecture: linux-any
Depends: ${misc:Depends}, libzfs2 (= ${binary:Version})
Provides: libnvpair-dev, libuutil-dev
Replaces: libefi1,
libnvpair1,
libshare1,
libspl1,
libunicode1,
libuutil1,
libzavl1,
libzfs2,
libzpool2,
Description: Native OpenZFS filesystem development files for Linux
Header files and static libraries for compiling software
against libzfs.
Package: libzfs2
Section: libs
Architecture: linux-any
Depends: ${misc:Depends}, ${shlibs:Depends}
Replaces: libzfs0, libzfs1
Description: Native OpenZFS filesystem library for Linux
The ZoL management library.
Package: libzfs2-dbg
Section: debug
Architecture: linux-any
Depends: ${misc:Depends}, libzfs2 (= ${binary:Version})
Replaces: libzfs0-dbg, libzfs1-dbg
Description: Debugging symbols for libzfs2
The ZoL management library.
.
This package contains the debugging symbols for libzfs2.
Package: libzpool2
Section: libs
Architecture: linux-any
Depends: ${misc:Depends}, ${shlibs:Depends}
Replaces: libzpool0, libzpool1
Description: Native OpenZFS pool library for Linux
The zpool management library.
Package: libzpool2-dbg
Section: debug
Architecture: linux-any
Depends: ${misc:Depends}, libzpool2 (= ${binary:Version})
Replaces: libzpool0-dbg, libzpool1-dbg
Description: Debugging symbols for libzpool2
The zpool management library.
.
This package contains the debugging symbols for libzpool2.
Package: zfs-dkms
Section: kernel
Architecture: linux-any
Pre-Depends: spl-dkms (>= ${source:Upstream-Version})
Depends: ${misc:Depends}, dkms (>= 2.2.0.2)
Replaces: lzfs, lzfs-dkms
Provides: lustre-backend-fs, lzfs, lzfs-dkms
Conflicts: lzfs, lzfs-dkms
Description: Native OpenZFS filesystem kernel modules for Linux
An advanced integrated volume manager and filesystem that is designed for
performance and data integrity. Snapshots, clones, checksums, deduplication,
compression, and RAID redundancy are built-in features.
.
Includes the SPA, DMU, ZVOL, and ZPL components of OpenZFS.
Package: zfs-doc
Section: doc
Architecture: linux-any
Depends: ${misc:Depends}
Description: Native OpenZFS filesystem documentation and examples.
Shared boilerplate files for OpenZFS on Linux that are not required at runtime.
Package: zfs-initramfs
Section: kernel
Architecture: linux-any
Depends: ${misc:Depends}, zfsutils
Description: Native OpenZFS root filesystem capabilities for Linux
This package adds OpenZFS to the system initramfs with a hook
for the initramfs-tools infrastructure.
Package: zfsutils
Section: admin
Architecture: linux-any
Depends: ${misc:Depends}, ${shlibs:Depends}
Suggests: samba-common-bin (>= 3.0.23), nfs-kernel-server, zfs-initramfs
Conflicts: zfs, zfs-fuse
Replaces: zfs
Description: Native OpenZFS management utilities for Linux
This package provides the zpool and zfs commands that are used to
manage OpenZFS filesystems.
Package: zfsutils-dbg
Section: debug
Architecture: linux-any
Depends: ${misc:Depends}, zfsutils (= ${binary:Version})
Replaces: zfs-dbg
Description: Debugging symbols for zfsutils
This package provides the zpool and zfs commands that are used to
manage OpenZFS filesystems.
.
This package contains the debugging symbols for zfsutils.
File diff suppressed because it is too large Load Diff
-1
View File
@@ -1 +0,0 @@
lib/libnvpair.so.*
-1
View File
@@ -1 +0,0 @@
lib/libuutil.so.*
-4
View File
@@ -1,4 +0,0 @@
lib/*.a
lib/*.la
lib/*.so
usr/include
-2
View File
@@ -1,2 +0,0 @@
lib/libzfs.so.*
lib/libzfs_core.so.*
-1
View File
@@ -1 +0,0 @@
lib/libzpool.so.*
@@ -1,71 +0,0 @@
From: Darik Horn <dajhorn@vanadac.com>
Date: Tue, 17 Jan 2012 19:45:07 -0600
Subject: Prevent manual builds in the DKMS source.
Print an instructive error messsage and exit if the `dkms.conf` file
exists when the userland is configured. (ie: `--with-config=user`)
A non-trivial number of people try to rebuild ZoL from the
`/usr/src/zfs` tree, which is modified to better satisfy Debian
packaging policy and contains only the module sources for DKMS.
Regardless, local installations usually break managed installations,
so this autotools test could be further enhanced to check whether
ZFS has a DKMS registration.
---
config/dkms.m4 | 14 ++++++++++++++
config/user.m4 | 1 +
config/zfs-build.m4 | 6 +++---
3 files changed, 18 insertions(+), 3 deletions(-)
create mode 100644 config/dkms.m4
diff --git a/config/dkms.m4 b/config/dkms.m4
new file mode 100644
index 0000000..cfa1152
--- /dev/null
+++ b/config/dkms.m4
@@ -0,0 +1,14 @@
+dnl #
+dnl # Prevent manual building in DKMS source tree.
+dnl #
+AC_DEFUN([ZFS_AC_DKMS_INHIBIT], [
+ AC_MSG_CHECKING([for dkms.conf file])
+ AS_IF([test -e dkms.conf], [
+ AC_MSG_ERROR([
+ *** ZFS should not be manually built in the DKMS source tree.
+ *** Remove all ZFS packages before compiling the ZoL sources.
+ *** Running "make install" breaks ZFS packages.])
+ ], [
+ AC_MSG_RESULT([not found])
+ ])
+])
diff --git a/config/user.m4 b/config/user.m4
index 3802437..f5a8827 100644
--- a/config/user.m4
+++ b/config/user.m4
@@ -2,6 +2,7 @@ dnl #
dnl # Default ZFS user configuration
dnl #
AC_DEFUN([ZFS_AC_CONFIG_USER], [
+ ZFS_AC_DKMS_INHIBIT
ZFS_AC_CONFIG_USER_UDEV
ZFS_AC_CONFIG_USER_SYSTEMD
ZFS_AC_CONFIG_USER_SYSVINIT
diff --git a/config/zfs-build.m4 b/config/zfs-build.m4
index 5ec94a0..41eec88 100644
--- a/config/zfs-build.m4
+++ b/config/zfs-build.m4
@@ -87,10 +87,10 @@ AC_DEFUN([ZFS_AC_CONFIG], [
ZFS_AC_CONFIG_ALWAYS
case "$ZFS_CONFIG" in
- kernel) ZFS_AC_CONFIG_KERNEL ;;
user) ZFS_AC_CONFIG_USER ;;
- all) ZFS_AC_CONFIG_KERNEL
- ZFS_AC_CONFIG_USER ;;
+ kernel) ZFS_AC_CONFIG_KERNEL ;;
+ all) ZFS_AC_CONFIG_USER
+ ZFS_AC_CONFIG_KERNEL ;;
srpm) ;;
*)
AC_MSG_RESULT([Error!])
@@ -1,70 +0,0 @@
From: Darik Horn <dajhorn@vanadac.com>
Date: Sat, 18 Oct 2014 14:23:11 -0500
Subject: Check for META and DCH consistency in autoconf.
If a debian/ packaging overlay exists, then the software versions defined in
the META and debian/changelog files must be the same to ensure that DKMS uses
correct paths and that users see the same version everywhere.
---
config/zfs-meta.m4 | 34 +++++++++++++++++++++++++++++-----
1 file changed, 29 insertions(+), 5 deletions(-)
diff --git a/config/zfs-meta.m4 b/config/zfs-meta.m4
index 7c92dd5..d174ccc 100644
--- a/config/zfs-meta.m4
+++ b/config/zfs-meta.m4
@@ -1,9 +1,10 @@
dnl #
dnl # DESCRIPTION:
-dnl # Read meta data from the META file. When building from a git repository
-dnl # the ZFS_META_RELEASE field will be overwritten if there is an annotated
-dnl # tag matching the form ZFS_META_NAME-ZFS_META_VERSION-*. This allows
-dnl # for working builds to be uniquely identified using the git commit hash.
+dnl # Read meta data from the META file or the debian/changelog file if it
+dnl # exists. When building from a git repository the ZFS_META_RELEASE field
+dnl # will be overwritten if there is an annotated tag matching the form
+dnl # ZFS_META_NAME-ZFS_META_VERSION-*. This allows for working builds to be
+dnl # uniquely identified using the git commit hash.
dnl #
dnl # The META file format is as follows:
dnl # ^[ ]*KEY:[ \t]+VALUE$
@@ -49,6 +50,7 @@ AC_DEFUN([ZFS_AC_META], [
_zfs_ac_meta_type="none"
if test -f "$META"; then
_zfs_ac_meta_type="META file"
+ _dpkg_parsechangelog=$(dpkg-parsechangelog 2>/dev/null)
ZFS_META_NAME=_ZFS_AC_META_GETVAL([(Name|Project|Package)]);
if test -n "$ZFS_META_NAME"; then
@@ -66,8 +68,30 @@ AC_DEFUN([ZFS_AC_META], [
AC_SUBST([ZFS_META_VERSION])
fi
+ if test -n "${_dpkg_parsechangelog}"; then
+ _dpkg_version=$(echo "${_dpkg_parsechangelog}" \
+ | $AWK '$[]1 == "Version:" { print $[]2; }' \
+ | cut -d- -f1)
+ if test "${_dpkg_version}" != "$ZFS_META_VERSION"; then
+ AC_MSG_ERROR([
+ *** Version $ZFS_META_VERSION in the META file is different than
+ *** version $_dpkg_version in the debian/changelog file. DKMS and DEB
+ *** packaging require that these files have the same version.
+ ])
+ fi
+ fi
+
ZFS_META_RELEASE=_ZFS_AC_META_GETVAL([Release]);
- if test ! -f ".nogitrelease" && git rev-parse --git-dir > /dev/null 2>&1; then
+
+ if test -n "${_dpkg_parsechangelog}"; then
+ _dpkg_release=$(echo "${_dpkg_parsechangelog}" \
+ | $AWK '$[]1 == "Version:" { print $[]2; }' \
+ | cut -d- -f2-)
+ if test -n "${_dpkg_release}"; then
+ ZFS_META_RELEASE=${_dpkg_release}
+ _zfs_ac_meta_type="dpkg-parsechangelog"
+ fi
+ elif test ! -f ".nogitrelease" && git rev-parse --git-dir > /dev/null 2>&1; then
_match="${ZFS_META_NAME}-${ZFS_META_VERSION}"
_alias=$(git describe --match=${_match} 2>/dev/null)
_release=$(echo ${_alias}|cut -f3- -d'-'|sed 's/-/_/g')
@@ -1,41 +0,0 @@
From: Darik Horn <dajhorn@vanadac.com>
Date: Sat, 18 Oct 2014 19:48:46 -0500
Subject: Add libuutil to LIBADD for libzfs and libzfs_core
Resolve spurious dpkg-shlibdeps warnings like this:
warning: symbol strlcpy used by libzfs_core.so found in none of the libraries
This happens because dpkg-shlibdeps does not recursively search for symbols.
Signed-off-by: Darik Horn <dajhorn@vanadac.com>
---
lib/libzfs/Makefile.am | 1 +
lib/libzfs_core/Makefile.am | 3 ++-
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/lib/libzfs/Makefile.am b/lib/libzfs/Makefile.am
index 8b1f517..efdf84b 100644
--- a/lib/libzfs/Makefile.am
+++ b/lib/libzfs/Makefile.am
@@ -23,6 +23,7 @@ libzfs_la_SOURCES = \
libzfs_la_LIBADD = \
$(top_builddir)/lib/libzfs_core/libzfs_core.la \
+ $(top_builddir)/lib/libuutil/libuutil.la \
$(top_builddir)/lib/libshare/libshare.la \
$(top_builddir)/lib/libnvpair/libnvpair.la \
$(top_builddir)/lib/libzpool/libzpool.la
diff --git a/lib/libzfs_core/Makefile.am b/lib/libzfs_core/Makefile.am
index 0ecd208..6f0be5f 100644
--- a/lib/libzfs_core/Makefile.am
+++ b/lib/libzfs_core/Makefile.am
@@ -10,6 +10,7 @@ libzfs_core_la_SOURCES = \
$(top_srcdir)/lib/libzfs_core/libzfs_core.c
libzfs_core_la_LIBADD = \
- $(top_builddir)/lib/libnvpair/libnvpair.la
+ $(top_builddir)/lib/libnvpair/libnvpair.la \
+ $(top_builddir)/lib/libuutil/libuutil.la
libzfs_core_la_LDFLAGS = -version-info 1:0:0
@@ -1,31 +0,0 @@
From: Ned Bass <bass6@llnl.gov>
Date: Wed, 17 Dec 2014 11:01:42 -0800
Subject: vdev_id: use mawk-compatible regular expression
Slot mapping in vdev_id doesn't work on systems using mawk as the 'awk'
alternative. A regular expression in map_slot() contains an unquoted
empty string following the alternation (|) operator, which results in an
"missing operand" error with mawk. The solution is to rearrange the
expression so the alternation has two operands.
Signed-off-by: Ned Bass <bass6@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes zfsonlinux/pkg-zfs#136
Closes zfsonlinux/zfs#2965
---
cmd/vdev_id/vdev_id | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/cmd/vdev_id/vdev_id b/cmd/vdev_id/vdev_id
index b6752ba..6fddd12 100755
--- a/cmd/vdev_id/vdev_id
+++ b/cmd/vdev_id/vdev_id
@@ -116,7 +116,7 @@ map_slot() {
local MAPPED_SLOT=
MAPPED_SLOT=`awk "\\$1 == \"slot\" && \\$2 == ${LINUX_SLOT} && \
- \\$4 ~ /^(${CHANNEL}|)$/ { print \\$3; exit }" $CONFIG`
+ \\$4 ~ /^${CHANNEL}$|^$/ { print \\$3; exit }" $CONFIG`
if [ -z "$MAPPED_SLOT" ] ; then
MAPPED_SLOT=$LINUX_SLOT
fi
-4
View File
@@ -1,4 +0,0 @@
0001-Prevent-manual-builds-in-the-DKMS-source.patch
0002-Check-for-META-and-DCH-consistency-in-autoconf.patch
0003-Add-libuutil-to-LIBADD-for-libzfs-and-libzfs_core.patch
0005-vdev_id-use-mawk-compatible-regular-expression.patch
-115
View File
@@ -1,115 +0,0 @@
#!/usr/bin/make -f
CHMOD ?= chmod
INSTALL ?= install
MAKE ?= make
META_NAME := $(shell awk '$$1 == "Name:" { print $$2; }' META)
VERSION := $(shell dpkg-parsechangelog \
| awk '$$1 == "Version:" { print $$2; }' | cut -d- -f1)
REVISION := $(shell dpkg-parsechangelog \
| awk '$$1 == "Version:" { print $$2; }' | cut -d- -f2-)
META_DISTDIR := $(CURDIR)/$(META_NAME)-$(VERSION)/
%:
dh $@ --with autoreconf,dkms
override_dh_auto_configure:
@# Embed the downstream version in the module.
@sed \
-e 's/^Version:.*/Version: $(VERSION)/' \
-e 's/^Release:.*/Release: $(REVISION)/' \
-i.orig META
@# Build the userland, but don't build the kernel modules.
dh_auto_configure -- \
--bindir=/bin \
--sbindir=/sbin \
--libdir=/lib \
--with-udevdir=/lib/udev \
--with-config=user
override_dh_auto_test:
# The dh_auto_test rule is disabled because
# `make check` cannot run in an unprivileged build environment.
override_dh_auto_install:
@# Install the utilities.
$(MAKE) install DESTDIR='$(CURDIR)/debian/tmp'
@# Get a bare copy of the source code for DKMS.
@# This creates the $(META_DISTDIR)/ tree.
$(MAKE) distdir
@# Delete components that are not required to build the kernel modules.
@# This prevents several lintian complaints, discourages users from
@# running `make install` in /usr/src, and reduces the installation
@# size by one third. The printf creates a dummy automake file.
umask 0111 && \
cd '$(META_DISTDIR)' && \
for ii in $$(find cmd dracut etc lib man rpm scripts udev -type f); do \
rm "$$ii"; \
test "$$ii" != "$${ii%.in}" && printf '%%:\n\t#\n' >"$$ii"; \
true; \
done
@# This shunt allows DKMS to copy the Module.symvers and zfs_config.h
@# files into the ${dkms_tree} area through the POST_INSTALL directive.
printf '#!/bin/sh\ncp "$$@"\n' >'$(META_DISTDIR)/cp'
$(CHMOD) 755 '$(META_DISTDIR)/cp'
@# Install the DKMS source directly, avoiding dh_install.
$(INSTALL) -d '$(CURDIR)/debian/zfs-dkms/usr/src/'
mv '$(META_DISTDIR)' '$(CURDIR)/debian/zfs-dkms/usr/src/'
override_dh_dkms:
dh_dkms -V
override_dh_install:
@# Exclude the upstream /usr/lib/udev/rules.d files.
dh_install -X/rules.d/
@# Ensure that /etc/zfs is in the zfsutils package
@# because git has difficulty tracking empty directories.
$(INSTALL) -d '$(CURDIR)/debian/zfsutils/etc/zfs/'
@# Resolve lintian errors regarding Debian Policy Manual Section 8.4
@# by moving unversioned library links from /lib to /usr/lib in the
@# development package. Look at libc6-dev for a packaging example if
@# multiarch support ever becomes a concern here.
$(INSTALL) -d '$(CURDIR)/debian/libzfs-dev/usr/lib/'
cd '$(CURDIR)/debian/libzfs-dev/lib' && \
for ii in $$(find -type l); do \
ln -s "../../lib/$$(readlink "$$ii")" "../usr/lib/$$(basename "$$ii")" \
&& rm "$$ii"; \
done
override_dh_installdocs:
dh_installdocs --link-doc=zfs-doc
override_dh_installinit:
@# Install debian/zfsutils.zfs.default as /etc/default/zfs.
dh_installinit --name=zfs
@# Install the /etc/init.d/zfs-mount script.
@# Debian runs local mounts at sysv sequences [10..12] [08..09].
dh_installinit --name=zfs-mount \
--no-restart-on-upgrade --no-start -- defaults 13 07
@# Debian runs nfs-kernel-server at sysv sequence 17 01,
@# iscsitarget at 02 01, and samba at 01 02.
dh_installinit --name=zfs-share \
--no-restart-on-upgrade --no-start -- defaults 18 00
override_dh_installudev:
dh_installudev --name=zvol --priority=60
dh_installudev --name=vdev --priority=69
override_dh_strip:
dh_strip -plibnvpair1 --dbg-package=libnvpair1-dbg
dh_strip -plibuutil1 --dbg-package=libuutil1-dbg
dh_strip -plibzfs2 --dbg-package=libzfs2-dbg
dh_strip -plibzpool2 --dbg-package=libzpool2-dbg
dh_strip -pzfsutils --dbg-package=zfsutils-dbg
@@ -1,6 +0,0 @@
## /etc/dpkg/dpkg.cfg.d/zfs-doc
##
## DPKG overrides that prevent the installation of ZoL documentation.
## Enable this line to reduce installation size.
#path-exclude /usr/share/doc/zfs-doc/*
@@ -1,2 +0,0 @@
# Force the inclusion of Busybox in the initramfs.
BUSYBOX=y
@@ -1,78 +0,0 @@
#!/bin/sh
#
# Add ZoL filesystem capabilities to an initrd, usually for a native OpenZFS root.
#
# This hook installs udev rules for ZoL.
PREREQ="zdev"
# These prerequisites are provided by the zfsutils package. The zdb utility is
# not strictly required, but it can be useful at the initramfs recovery prompt.
COPY_EXEC_LIST="/sbin/zdb /sbin/zpool /sbin/zfs /sbin/mount.zfs"
# These prerequisites are provided by the base system.
COPY_EXEC_LIST="$COPY_EXEC_LIST /bin/hostname /sbin/blkid"
# Explicitly specify all kernel modules because automatic dependency resolution
# is unreliable on many systems.
MANUAL_ADD_MODULES_LIST="zlib_deflate spl zavl zcommon znvpair zunicode zfs"
# Generic result code.
RC=0
case $1 in
prereqs)
echo "$PREREQ"
exit 0
;;
esac
for ii in $COPY_EXEC_LIST
do
if [ ! -x "$ii" ]
then
echo "Error: $ii is not executable."
RC=2
fi
done
if [ "$RC" -ne 0 ]
then
exit "$RC"
fi
. /usr/share/initramfs-tools/hook-functions
mkdir -p "$DESTDIR/etc/"
# zpool requires /etc/mtab
ln -sf "/proc/mounts" "$DESTDIR/etc/mtab"
# ZDB uses pthreads for some functions, but the library dependency is not
# automatically detected. The `find` utility and extended `cp` options are
# used here because libgcc_s.so could be in a subdirectory of /lib for
# multi-arch installations.
cp --target-directory="$DESTDIR" --parents $(find /lib -type f -name libgcc_s.so.1)
for ii in $COPY_EXEC_LIST
do
copy_exec "$ii"
done
for ii in $MANUAL_ADD_MODULES_LIST
do
manual_add_modules "$ii"
done
if [ -f "/etc/hostname" ]
then
cp -p "/etc/hostname" "$DESTDIR/etc/"
else
hostname >"$DESTDIR/etc/hostname"
fi
# ZoL 0.6.3 deprecated the hostid check.
if [ -f /etc/hostid ]
then
cp -p /etc/hostid "$DESTDIR/etc/hostid"
fi
@@ -1,164 +0,0 @@
# ZFS boot stub for initramfs-tools.
#
# In the initramfs environment, the /init script sources this stub to
# override the default functions in the /scripts/local script.
#
# Enable this by passing boot=zfs on the kernel command line.
#
pre_mountroot()
{
[ "$quiet" != "y" ] && log_begin_msg "Running /scripts/local-top"
run_scripts /scripts/local-top
[ "$quiet" != "y" ] && log_end_msg
if [ -r '/etc/default/zfs' ]
then
ZFS_INITRD_PRE_MOUNTROOT_SLEEP=0
. '/etc/default/zfs'
if [ "$ZFS_INITRD_PRE_MOUNTROOT_SLEEP" -gt '0' ]
then
[ "$quiet" != "y" ] && log_begin_msg "Sleeping for $ZFS_INITRD_PRE_MOUNTROOT_SLEEP seconds..."
sleep "$ZFS_INITRD_PRE_MOUNTROOT_SLEEP"
[ "$quiet" != "y" ] && log_end_msg
fi
fi
}
# Duplicates the functionality found under try_failure_hooks in functions
# but invoking that would be inappropriate here.
disable_plymouth()
{
if [ -x /bin/plymouth ] && /bin/plymouth --ping
then
/bin/plymouth hide-splash >/dev/null 2>&1
fi
}
mountroot()
{
pre_mountroot
[ "$quiet" != "y" ] && log_begin_msg "Running /scripts/local-premount"
run_scripts /scripts/local-premount
[ "$quiet" != "y" ] && log_end_msg
# Wait for all of the /dev/{hd,sd}[a-z] device nodes to appear.
wait_for_udev
# Load the module now to get consistent automatic pool import behavior.
/sbin/modprobe zfs
# Check the kernel command line for overrides.
ZFS_RPOOL="${rpool#rpool=}"
ZFS_BOOTFS="${bootfs#bootfs=}"
if [ -z "$ZFS_RPOOL" ]
then
# Check for the `-B zfs-bootfs=%s/%u,...` kind of parameter.
#
# The ${zfs-bootfs} variable is set at the kernel commmand
# line, usually by GRUB, but it cannot be referenced here
# directly because bourne variable names cannot contain a
# hyphen.
#
# Reassign the variable by dumping the environment and
# stripping the zfs-bootfs= prefix. Let the shell handle
# quoting through the eval command.
eval ZFS_RPOOL=$(set | sed -n -e 's,^zfs-bootfs=,,p')
# Only the pool name is relevant because the ZFS filesystem on
# Linux is extrinsic and the userland cannot resolve a ZFS
# object number.
#
# Strip everything after the first slash character.
ZFS_RPOOL=$(echo "$ZFS_RPOOL" | sed -e 's,/.*,,')
fi
# Use "rpool" as the default, like on most Solaris systems.
[ -z "$ZFS_RPOOL" ] && ZFS_RPOOL='rpool'
# @FIXME: Forcing the import should not be necessary.
#
# Consider inhibiting automatic zpool imports in the initramfs
# environment and doing a full import in the regular system instead.
[ "$quiet" != "y" ] && log_begin_msg "Importing ZFS root pool $ZFS_RPOOL"
if [ -f /etc/zfs/zpool.cache ]
then
ZFS_STDERR=$(zpool list "$ZFS_RPOOL" 1>/dev/null 2>&1 \
|| zpool import -f -N "$ZFS_RPOOL" 2>&1)
ZFS_ERROR=$?
else
ZFS_STDERR=$(zpool import -f -N "$ZFS_RPOOL" 2>&1)
ZFS_ERROR=$?
fi
[ "$quiet" != "y" ] && log_end_msg
if [ "$ZFS_ERROR" -ne 0 ]
then
disable_plymouth
echo "Command: zpool import -f -N $ZFS_RPOOL"
echo "Message: $ZFS_STDERR"
echo "Error: $ZFS_ERROR"
echo ""
echo "Manually import the root pool at the command prompt and then exit."
echo "Hint: Try: zpool import -f -R / -N $ZFS_RPOOL"
/bin/sh
fi
if [ -z "$ZFS_BOOTFS" ]
then
[ "$quiet" != "y" ] && log_begin_msg "Getting ZFS bootfs property"
ZFS_BOOTFS=$(zpool list -H -o bootfs "$ZFS_RPOOL")
ZFS_ERROR=$?
[ "$quiet" != "y" ] && log_end_msg
fi
if [ -z "$ZFS_BOOTFS" ]
then
disable_plymouth
echo "Command: zpool list -H -o bootfs $ZFS_RPOOL"
echo "Error: $ZFS_ERROR, unable to get the bootfs property."
echo ""
echo "Manually mount the root filesystem on $rootmnt and then exit."
echo "Hint: Try: mount -t zfs -o zfsutil $ZFS_RPOOL/ROOT/system $rootmnt"
/bin/sh
fi
# Force the mountpoint to the only correct value for a root filesystem.
[ "$quiet" != "y" ] && log_begin_msg "Setting mountpoint=/ on ZFS filesystem $ZFS_BOOTFS"
ZFS_STDERR=$(zfs set mountpoint=/ "$ZFS_BOOTFS" 2>&1)
[ "$quiet" != "y" ] && log_end_msg
# Ideally, the root filesystem would be mounted like this:
#
# zpool import -R "$rootmnt" -N "$ZFS_RPOOL"
# zfs mount -o mountpoint=/ "$ZFS_BOOTFS"
#
# but the MOUNTPOINT prefix is preserved on descendent filesystem after
# the pivot into the regular root, which later breaks things like
# `zfs mount -a` and the /etc/mtab refresh.
[ "$quiet" != "y" ] && log_begin_msg "Mounting ZFS filesystem $ZFS_BOOTFS"
ZFS_STDERR=$(mount -t zfs -o zfsutil "$ZFS_BOOTFS" "$rootmnt" 2>&1)
ZFS_ERROR=$?
[ "$quiet" != "y" ] && log_end_msg
if [ "$ZFS_ERROR" -ne 0 ]
then
disable_plymouth
echo ""
echo "Command: mount -t zfs -o zfsutil $ZFS_BOOTFS $rootmnt"
echo "Message: $ZFS_STDERR"
echo "Error: $ZFS_ERROR"
echo ""
echo "Manually mount the root filesystem on $rootmnt and then exit."
/bin/sh
fi
[ "$quiet" != "y" ] && log_begin_msg "Running /scripts/local-bottom"
run_scripts /scripts/local-bottom
[ "$quiet" != "y" ] && log_end_msg
}
@@ -1,391 +0,0 @@
# Copyright (c) 2013, Aneurin Price <aneurin.price@gmail.com>
# 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.
if [[ -w /dev/zfs ]]; then
__ZFS_CMD="zfs"
__ZPOOL_CMD="zpool"
else
__ZFS_CMD="sudo zfs"
__ZPOOL_CMD="sudo zpool"
fi
__zfs_get_commands()
{
$__ZFS_CMD 2>&1 | awk '/^\t[a-z]/ {print $1}' | cut -f1 -d '|' | uniq
}
__zfs_get_properties()
{
$__ZFS_CMD get 2>&1 | awk '$2 == "YES" || $2 == "NO" {print $1}'; echo all name space
}
__zfs_get_editable_properties()
{
$__ZFS_CMD get 2>&1 | awk '$2 == "YES" {print $1"="}'
}
__zfs_get_inheritable_properties()
{
$__ZFS_CMD get 2>&1 | awk '$3 == "YES" {print $1}'
}
__zfs_list_datasets()
{
$__ZFS_CMD list -H -o name -t filesystem,volume
}
__zfs_list_filesystems()
{
$__ZFS_CMD list -H -o name -t filesystem
}
__zfs_match_snapshot()
{
local base_dataset=${cur%@*}
if [[ $base_dataset != $cur ]]
then
$__ZFS_CMD list -H -o name -s name -t snapshot -d 1 $base_dataset
else
$__ZFS_CMD list -H -o name -t filesystem,volume | awk '{print $1"@"}'
fi
}
__zfs_match_explicit_snapshot()
{
local base_dataset=${cur%@*}
if [[ $base_dataset != $cur ]]
then
$__ZFS_CMD list -H -o name -s name -t snapshot -d 1 $base_dataset
fi
}
__zfs_match_multiple_snapshots()
{
local existing_opts=$(expr "$cur" : '\(.*\)[%,]')
if [[ $existing_opts ]]
then
local base_dataset=${cur%@*}
if [[ $base_dataset != $cur ]]
then
local cur=${cur##*,}
if [[ $cur =~ ^%|%.*% ]]
then
# correct range syntax is start%end
return 1
fi
local range_start=$(expr "$cur" : '\(.*%\)')
$__ZFS_CMD list -H -o name -s name -t snapshot -d 1 $base_dataset | sed 's$.*@$'$range_start'$g'
fi
else
__zfs_match_explicit_snapshot; __zfs_list_datasets
fi
}
__zfs_list_volumes()
{
$__ZFS_CMD list -H -o name -t volume
}
__zfs_argument_chosen()
{
local word property
for word in $(seq $((COMP_CWORD-1)) -1 2)
do
local prev="${COMP_WORDS[$word]}"
if [[ ${COMP_WORDS[$word-1]} != -[tos] ]]
then
if [[ "$prev" == [^,]*,* ]] || [[ "$prev" == *[@:]* ]]
then
return 0
fi
for property in $@
do
if [[ $prev == "$property" ]]
then
return 0
fi
done
fi
done
return 1
}
__zfs_complete_ordered_arguments()
{
local list1=$1
local list2=$2
local cur=$3
local extra=$4
if __zfs_argument_chosen $list1
then
COMPREPLY=($(compgen -W "$list2 $extra" -- "$cur"))
else
COMPREPLY=($(compgen -W "$list1 $extra" -- "$cur"))
fi
}
__zfs_complete_multiple_options()
{
local options=$1
local cur=$2
COMPREPLY=($(compgen -W "$options" -- "${cur##*,}"))
local existing_opts=$(expr "$cur" : '\(.*,\)')
if [[ $existing_opts ]]
then
COMPREPLY=( "${COMPREPLY[@]/#/${existing_opts}}" )
fi
}
__zfs_complete_switch()
{
local options=$1
if [[ ${cur:0:1} == - ]]
then
COMPREPLY=($(compgen -W "-{$options}" -- "$cur"))
return 0
else
return 1
fi
}
__zfs_complete()
{
local cur prev cmd cmds
COMPREPLY=()
# Don't split on colon
_get_comp_words_by_ref -n : -c cur -p prev -w COMP_WORDS -i COMP_CWORD
cmd="${COMP_WORDS[1]}"
if [[ ${prev##*/} == zfs ]]
then
cmds=$(__zfs_get_commands)
COMPREPLY=($(compgen -W "$cmds -?" -- "$cur"))
return 0
fi
case "${cmd}" in
clone)
case "${prev}" in
-o)
COMPREPLY=($(compgen -W "$(__zfs_get_editable_properties)" -- "$cur"))
;;
*)
if ! __zfs_complete_switch "o,p"
then
if __zfs_argument_chosen
then
COMPREPLY=($(compgen -W "$(__zfs_list_datasets)" -- "$cur"))
else
COMPREPLY=($(compgen -W "$(__zfs_match_snapshot)" -- "$cur"))
fi
fi
;;
esac
;;
get)
case "${prev}" in
-d)
COMPREPLY=($(compgen -W "" -- "$cur"))
;;
-t)
__zfs_complete_multiple_options "filesystem volume snapshot all" "$cur"
;;
-s)
__zfs_complete_multiple_options "local default inherited temporary none" "$cur"
;;
-o)
__zfs_complete_multiple_options "name property value source received all" "$cur"
;;
*)
if ! __zfs_complete_switch "H,r,p,d,o,t,s"
then
if __zfs_argument_chosen $(__zfs_get_properties)
then
COMPREPLY=($(compgen -W "$(__zfs_match_explicit_snapshot) $(__zfs_list_datasets)" -- "$cur"))
else
__zfs_complete_multiple_options "$(__zfs_get_properties)" "$cur"
fi
fi
;;
esac
;;
inherit)
if ! __zfs_complete_switch "r"
then
__zfs_complete_ordered_arguments "$(__zfs_get_inheritable_properties)" "$(__zfs_match_explicit_snapshot) $(__zfs_list_datasets)" $cur
fi
;;
list)
case "${prev}" in
-d)
COMPREPLY=($(compgen -W "" -- "$cur"))
;;
-t)
__zfs_complete_multiple_options "filesystem volume snapshot all" "$cur"
;;
-o)
__zfs_complete_multiple_options "$(__zfs_get_properties)" "$cur"
;;
-s|-S)
COMPREPLY=($(compgen -W "$(__zfs_get_properties)" -- "$cur"))
;;
*)
if ! __zfs_complete_switch "H,r,d,o,t,s,S"
then
COMPREPLY=($(compgen -W "$(__zfs_match_explicit_snapshot) $(__zfs_list_datasets)" -- "$cur"))
fi
;;
esac
;;
promote)
COMPREPLY=($(compgen -W "$(__zfs_list_filesystems)" -- "$cur"))
;;
rollback)
if ! __zfs_complete_switch "r,R,f"
then
COMPREPLY=($(compgen -W "$(__zfs_match_snapshot)" -- "$cur"))
fi
;;
send)
if ! __zfs_complete_switch "d,n,P,p,R,v,i,I"
then
COMPREPLY=($(compgen -W "$(__zfs_match_snapshot)" -- "$cur"))
fi
;;
snapshot)
case "${prev}" in
-o)
COMPREPLY=($(compgen -W "$(__zfs_get_editable_properties)" -- "$cur"))
;;
*)
if ! __zfs_complete_switch "o,r"
then
COMPREPLY=($(compgen -W "$(__zfs_list_datasets | awk '{print $1"@"}')" -- "$cur"))
fi
;;
esac
;;
set)
__zfs_complete_ordered_arguments "$(__zfs_get_editable_properties)" "$(__zfs_match_explicit_snapshot) $(__zfs_list_datasets)" $cur
;;
upgrade)
case "${prev}" in
-a|-V|-v)
COMPREPLY=($(compgen -W "" -- "$cur"))
;;
*)
if ! __zfs_complete_switch "a,V,v,r"
then
COMPREPLY=($(compgen -W "$(__zfs_list_filesystems)" -- "$cur"))
fi
;;
esac
;;
destroy)
if ! __zfs_complete_switch "d,f,n,p,R,r,v"
then
__zfs_complete_multiple_options "$(__zfs_match_multiple_snapshots)" $cur
fi
;;
*)
COMPREPLY=($(compgen -W "$(__zfs_match_explicit_snapshot) $(__zfs_list_datasets)" -- "$cur"))
;;
esac
__ltrim_colon_completions "$cur"
return 0
}
__zpool_get_commands()
{
$__ZPOOL_CMD 2>&1 | awk '/^\t[a-z]/ {print $1}' | uniq
}
__zpool_get_properties()
{
$__ZPOOL_CMD get 2>&1 | awk '$2 == "YES" || $2 == "NO" {print $1}'; echo all
}
__zpool_get_editable_properties()
{
$__ZPOOL_CMD get 2>&1 | awk '$2 == "YES" {print $1"="}'
}
__zpool_list_pools()
{
$__ZPOOL_CMD list -H -o name
}
__zpool_complete()
{
local cur prev cmd cmds
COMPREPLY=()
cur="${COMP_WORDS[COMP_CWORD]}"
prev="${COMP_WORDS[COMP_CWORD-1]}"
cmd="${COMP_WORDS[1]}"
if [[ ${prev##*/} == zpool ]]
then
cmds=$(__zpool_get_commands)
COMPREPLY=($(compgen -W "$cmds" -- "$cur"))
return 0
fi
case "${cmd}" in
get)
__zfs_complete_ordered_arguments "$(__zpool_get_properties)" "$(__zpool_list_pools)" $cur
return 0
;;
import)
if [[ $prev == -d ]]
then
_filedir -d
else
COMPREPLY=($(compgen -W "$(__zpool_list_pools) -d" -- "$cur"))
fi
return 0
;;
set)
__zfs_complete_ordered_arguments "$(__zpool_get_editable_properties)" "$(__zpool_list_pools)" $cur
return 0
;;
add|attach|clear|create|detach|offline|online|remove|replace)
local pools="$(__zpool_list_pools)"
if __zfs_argument_chosen $pools
then
_filedir
else
COMPREPLY=($(compgen -W "$pools" -- "$cur"))
fi
return 0
;;
*)
COMPREPLY=($(compgen -W "$(__zpool_list_pools)" -- "$cur"))
return 0
;;
esac
}
complete -F __zfs_complete zfs
complete -F __zpool_complete zpool
@@ -1,28 +0,0 @@
## Allow read-only ZoL commands to be called through sudo
## without a password. Remove the first '#' column to enable.
##
## CAUTION: Any syntax error introduced here will break sudo.
##
## Cmnd alias specification
#Cmnd_Alias C_ZFS = \
# /sbin/zfs "", /sbin/zfs help *, \
# /sbin/zfs get, /sbin/zfs get *, \
# /sbin/zfs list, /sbin/zfs list *, \
# /sbin/zpool "", /sbin/zpool help *, \
# /sbin/zpool iostat, /sbin/zpool iostat *, \
# /sbin/zpool list, /sbin/zpool list *, \
# /sbin/zpool status, /sbin/zpool status *, \
# /sbin/zpool upgrade, /sbin/zpool upgrade -v
#
#Runas_Alias R_ROOT = root
#
## User privilege specification
#root ALL=(ALL) ALL
#
## Members of the admin group may gain root privileges
#%adm ALL=(ALL) ALL # linux
#%admin ALL=(ALL) ALL # linux
#%staff ALL=(ALL) ALL # solaris
#
## allow any user to use basic read-only ZFS commands
#ALL ALL = (R_ROOT) NOPASSWD: C_ZFS
@@ -1,14 +0,0 @@
#!/bin/sh
# Sub-test to exclude ZVOLs
set -e
partition="$1"
. /usr/share/os-prober/common.sh
if [ "$(stat -L -c %t "$partition")" = "e6" ] ; then
debug "$1 is a ZVOL; skipping"
exit 0
fi
# No ZVOLs found
exit 1
@@ -1,67 +0,0 @@
#!/bin/sh
#
# Add udev rules for ZoL to the initrd.
#
PREREQ="udev"
PREREQ_UDEV_RULES="60-zvol.rules 69-vdev.rules"
COPY_EXEC_LIST="/lib/udev/vdev_id /lib/udev/zvol_id"
# Generic result code.
RC=0
case $1 in
prereqs)
echo "$PREREQ"
exit 0
;;
esac
for ii in $COPY_EXEC_LIST
do
if [ ! -x "$ii" ]
then
echo "Error: $ii is not executable."
RC=2
fi
done
if [ "$RC" -ne 0 ]
then
exit "$RC"
fi
. /usr/share/initramfs-tools/hook-functions
mkdir -p "$DESTDIR/lib/udev/rules.d/"
for ii in $PREREQ_UDEV_RULES
do
if [ -e "/etc/udev/rules.d/$ii" ]
then
cp -p "/etc/udev/rules.d/$ii" "$DESTDIR/lib/udev/rules.d/"
elif [ -e "/lib/udev/rules.d/$ii" ]
then
cp -p "/lib/udev/rules.d/$ii" "$DESTDIR/lib/udev/rules.d/"
else
echo "Error: Missing udev rule: $ii"
echo " This file must be in the /etc/udev/rules.d or /lib/udev/rules.d directory."
exit 1
fi
done
for ii in $COPY_EXEC_LIST
do
copy_exec "$ii"
done
if [ -f '/etc/default/zfs' -a -r '/etc/default/zfs' ]
then
mkdir -p "$DESTDIR/etc/default"
cp -a '/etc/default/zfs' "$DESTDIR/etc/default/"
fi
if [ -d '/etc/zfs' -a -r '/etc/zfs' ]
then
mkdir -p "$DESTDIR/etc"
cp -a '/etc/zfs' "$DESTDIR/etc/"
fi
-88
View File
@@ -1,88 +0,0 @@
BUILD_DEPENDS[0]="spl"
AUTOINSTALL="yes"
PACKAGE_NAME="zfs"
PACKAGE_VERSION="#MODULE_VERSION#"
PRE_BUILD="configure
--prefix=/usr
--with-config=kernel
--with-linux=$(
case `lsb_release -is` in
(Debian)
if [[ -e ${kernel_source_dir/%build/source} ]]
then
echo ${kernel_source_dir/%build/source}
else
# A kpkg exception for Proxmox 2.0
echo ${kernel_source_dir}
fi
;;
(*)
echo ${kernel_source_dir}
;;
esac
)
--with-linux-obj=${kernel_source_dir}
--with-spl=${source_tree}/spl-${PACKAGE_VERSION}
--with-spl-obj=${dkms_tree}/spl/${PACKAGE_VERSION}/${kernelver}/${arch}
$(
[[ -r /etc/default/zfs ]] \
&& source /etc/default/zfs \
&& shopt -q -s extglob \
&& \
{
if [[ ${ZFS_DKMS_ENABLE_DEBUG,,} == @(y|yes) ]]
then
echo --enable-debug
fi
if [[ ${ZFS_DKMS_ENABLE_DEBUG_DMU_TX,,} == @(y|yes) ]]
then
echo --enable-debug-dmu-tx
fi
}
)
"
POST_BUILD="cp
${dkms_tree}/${PACKAGE_NAME}/${PACKAGE_VERSION}/build/zfs_config.h
${dkms_tree}/${PACKAGE_NAME}/${PACKAGE_VERSION}/build/module/Module.symvers
${dkms_tree}/${PACKAGE_NAME}/${PACKAGE_VERSION}/${kernelver}/${arch}/
"
REMAKE_INITRD="$(
if [ -e /usr/share/initramfs-tools/hooks/zfs \
-o -e /usr/share/dracut/modules.d/90zfs ]
then
echo -n yes
else
echo -n no
fi
)"
MAKE[0]="make"
STRIP[0]="$(
[[ -r /etc/default/zfs ]] \
&& source /etc/default/zfs \
&& shopt -q -s extglob \
&& [[ ${ZFS_DKMS_DISABLE_STRIP,,} == @(y|yes) ]] \
&& echo -n no
)"
STRIP[1]="${STRIP[0]}"
STRIP[2]="${STRIP[0]}"
STRIP[3]="${STRIP[0]}"
STRIP[4]="${STRIP[0]}"
STRIP[5]="${STRIP[0]}"
BUILT_MODULE_NAME[0]="zavl"
BUILT_MODULE_LOCATION[0]="module/avl/"
DEST_MODULE_LOCATION[0]="/extra/zfs/zavl"
BUILT_MODULE_NAME[1]="zcommon"
BUILT_MODULE_LOCATION[1]="module/zcommon/"
DEST_MODULE_LOCATION[1]="/extra/zfs/zcommon"
BUILT_MODULE_NAME[2]="znvpair"
BUILT_MODULE_LOCATION[2]="module/nvpair/"
DEST_MODULE_LOCATION[2]="/extra/zfs/znvpair"
BUILT_MODULE_NAME[3]="zpios"
BUILT_MODULE_LOCATION[3]="module/zpios/"
DEST_MODULE_LOCATION[3]="/extra/zfs/zpios"
BUILT_MODULE_NAME[4]="zunicode"
BUILT_MODULE_LOCATION[4]="module/unicode/"
DEST_MODULE_LOCATION[4]="/extra/zfs/zunicode"
BUILT_MODULE_NAME[5]="zfs"
BUILT_MODULE_LOCATION[5]="module/zfs/"
DEST_MODULE_LOCATION[5]="/extra/zfs/zfs"
-10
View File
@@ -1,10 +0,0 @@
#!/bin/sh -e
case $1 in
(configure)
[ -x /usr/share/update-notifier/notify-reboot-required ] \
&& /usr/share/update-notifier/notify-reboot-required
;;
esac
#DEBHELPER#
-3
View File
@@ -1,3 +0,0 @@
#!/bin/sh -e
#DEBHELPER#
-2
View File
@@ -1,2 +0,0 @@
COPYRIGHT
OPENSOLARIS.LICENSE
-56
View File
@@ -1,56 +0,0 @@
etc/zfs/vdev_id.conf.alias.example
etc/zfs/vdev_id.conf.multipath.example
etc/zfs/vdev_id.conf.sas_direct.example
etc/zfs/vdev_id.conf.sas_switch.example
scripts/common.sh
scripts/zconfig.sh
scripts/zfault.sh
scripts/zfs.sh
scripts/zpios-profile/zpios-profile-disk.sh
scripts/zpios-profile/zpios-profile-pids.sh
scripts/zpios-profile/zpios-profile-post.sh
scripts/zpios-profile/zpios-profile-pre.sh
scripts/zpios-profile/zpios-profile.sh
scripts/zpios-sanity.sh
scripts/zpios-survey.sh
scripts/zpios-test/16th-8192rc-4rs-1cs-4off.sh
scripts/zpios-test/1th-16rc-4rs-1cs-4off.sh
scripts/zpios-test/1x256th-65536rc-4rs-1cs-4off.sh
scripts/zpios-test/256th-65536rc-4rs-1cs-4off.sh
scripts/zpios-test/4th-1024rc-4rs-1cs-4off.sh
scripts/zpios-test/large-thread-survey.sh
scripts/zpios-test/large.sh
scripts/zpios-test/lustre.sh
scripts/zpios-test/medium.sh
scripts/zpios-test/small.sh
scripts/zpios-test/tiny.sh
scripts/zpios.sh
scripts/zpool-config/dm0-raid0.sh
scripts/zpool-config/file-raid0.sh
scripts/zpool-config/file-raid10.sh
scripts/zpool-config/file-raidz.sh
scripts/zpool-config/file-raidz2.sh
scripts/zpool-config/hda-raid0.sh
scripts/zpool-config/lo-faulty-raid0.sh
scripts/zpool-config/lo-faulty-raid10.sh
scripts/zpool-config/lo-faulty-raidz.sh
scripts/zpool-config/lo-faulty-raidz2.sh
scripts/zpool-config/lo-faulty-raidz3.sh
scripts/zpool-config/lo-raid0.sh
scripts/zpool-config/lo-raid10.sh
scripts/zpool-config/lo-raidz.sh
scripts/zpool-config/lo-raidz2.sh
scripts/zpool-config/md0-raid10.sh
scripts/zpool-config/md0-raid5.sh
scripts/zpool-config/ram0-raid0.sh
scripts/zpool-config/scsi_debug-noraid.sh
scripts/zpool-config/scsi_debug-raid0.sh
scripts/zpool-config/scsi_debug-raid10.sh
scripts/zpool-config/scsi_debug-raidz.sh
scripts/zpool-config/scsi_debug-raidz2.sh
scripts/zpool-config/scsi_debug-raidz3.sh
scripts/zpool-config/sda-raid0.sh
scripts/zpool-config/zpool-raid0.sh
scripts/zpool-config/zpool-raid10.sh
scripts/zpool-config/zpool-raidz.sh
scripts/zpool-create.sh
-1
View File
@@ -1 +0,0 @@
../tree/zfs-doc/* /
-1
View File
@@ -1 +0,0 @@
../tree/zfs-initramfs/* /
-10
View File
@@ -1,10 +0,0 @@
#!/bin/sh -e
# @FIXME: During system start, the /etc/init/mountall.conf on Ubuntu is unable
# to generate the /etc/mtab file from the /proc/mounts file if a ZFS filesystem
# is already mounted.
# This depends on mountall 2.18, which recognizes the link.
ln -sf /proc/mounts /etc/mtab
#DEBHELPER#
-4
View File
@@ -1,4 +0,0 @@
../tree/zfsutils/* /
sbin
lib/udev
usr/share/man
-9
View File
@@ -1,9 +0,0 @@
#!/bin/sh -e
if dpkg-maintscript-helper supports rm_conffile 2>/dev/null
then
dpkg-maintscript-helper rm_conffile /etc/default/zfsload -- "$@"
dpkg-maintscript-helper rm_conffile /etc/init.d/zfs -- "$@"
fi
#DEBHELPER#
-9
View File
@@ -1,9 +0,0 @@
#!/bin/sh -e
if dpkg-maintscript-helper supports rm_conffile 2>/dev/null
then
dpkg-maintscript-helper rm_conffile /etc/default/zfsload -- "$@"
dpkg-maintscript-helper rm_conffile /etc/init.d/zfs -- "$@"
fi
#DEBHELPER#
-9
View File
@@ -1,9 +0,0 @@
#!/bin/sh -e
if dpkg-maintscript-helper supports rm_conffile 2>/dev/null
then
dpkg-maintscript-helper rm_conffile /etc/default/zfsload -- "$@"
dpkg-maintscript-helper rm_conffile /etc/init.d/zfs -- "$@"
fi
#DEBHELPER#
-4
View File
@@ -1,4 +0,0 @@
ENV{DEVTYPE}=="disk", IMPORT{program}="/lib/udev/vdev_id -d %k"
KERNEL=="*[!0-9]", ENV{SUBSYSTEM}=="block", ENV{ID_VDEV}=="?*", SYMLINK+="$env{ID_VDEV_PATH}"
KERNEL=="*[0-9]", ENV{SUBSYSTEM}=="block", ENV{DEVTYPE}=="partition", ENV{ID_VDEV}=="?*", SYMLINK+="$env{ID_VDEV_PATH}-part%n"
KERNEL=="dm-[0-9]*", ENV{SUBSYSTEM}=="block", ENV{ID_VDEV}=="?*", SYMLINK+="$env{ID_VDEV_PATH}"
-80
View File
@@ -1,80 +0,0 @@
#!/bin/sh
#
### BEGIN INIT INFO
# Provides: zvol zfs
# Required-Start: $local_fs
# Required-Stop: $local_fs
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Mount ZFS filesystems
# Description: Run the `zfs mount -a` or `zfs umount -a` command.
# This init script is deprecated and should be disabled in the
# /etc/default/zfs options file. Instead, use the zfs-mount
# package for Debian or the zfs-mountall package for Ubuntu
### END INIT INFO
PATH=/sbin:/bin
. /lib/lsb/init-functions
. /lib/init/vars.sh
[ -f /etc/default/zfs ] && . /etc/default/zfs
do_start()
{
log_begin_msg "Mounting ZFS filesystems"
log_progress_msg "filesystems"
zfs mount -a
RET=$?
if [ $RET != 0 ] ; then
log_end_msg $RET
exit $RET
fi
log_end_msg 0
}
do_stop()
{
log_begin_msg "Unmounting ZFS filesystems"
log_progress_msg "filesystems"
zfs unmount -a
RET=$?
# Ignore a non-zero `zfs` result so that a busy ZFS instance
# does not hang the system during shutdown.
if [ $RET != 0 ] ; then
log_end_msg $RET
fi
log_end_msg 0
}
case "$1" in
(start)
case "$ZFS_MOUNT" in
([Oo][Ff][Ff]|[Nn][Oo]|'')
exit 0
;;
esac
do_start
;;
(stop)
case "$ZFS_UNMOUNT" in
([Oo][Ff][Ff]|[Nn][Oo]|'')
exit 0
;;
esac
do_stop
;;
(force-reload|reload|restart|status)
# no-op
;;
(*)
[ -n "$1" ] && echo "Error: Unknown command $1."
echo "Usage: $0 {start|stop}"
exit 3
;;
esac
-80
View File
@@ -1,80 +0,0 @@
#!/bin/sh
### BEGIN INIT INFO
# Provides: shareiscsi sharenfs sharesmb zfs-share
# Required-Start: $local_fs $network $remote_fs
# Required-Stop: $local_fs $network $remote_fs
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Should-Start: iscsi iscsitarget istgt nfs-kernel-server samba
# Should-Stop: iscsi iscsitarget istgt nfs-kernel-server samba
# Short-Description: Network share OpenZFS datasets.
# Description: Run the `zfs share -a` or `zfs unmount -a` commands
# for controlling iSCSI, NFS, or CIFS network shares.
### END INIT INFO
PATH=/sbin:/bin:/usr/sbin:/usr/bin
. /lib/lsb/init-functions
. /lib/init/vars.sh
[ -f /etc/default/zfs ] && . /etc/default/zfs
do_start()
{
log_begin_msg "Sharing OpenZFS filesystems"
log_progress_msg "filesystems"
zfs share -a
RET=$?
if [ $RET != 0 ] ; then
log_end_msg $RET
exit $RET
fi
log_end_msg 0
}
do_stop()
{
log_begin_msg "Unsharing OpenZFS filesystems"
log_progress_msg "filesystems"
zfs unshare -a
RET=$?
# Ignore a non-zero `zfs` result so that a busy OpenZFS instance
# does not hang the system during shutdown.
if [ $RET != 0 ] ; then
log_end_msg $RET
fi
log_end_msg 0
}
case "$1" in
(start)
case "$ZFS_SHARE" in
([Oo][Ff][Ff]|[Nn][Oo]|'')
exit 0
;;
esac
do_start
;;
(stop)
case "$ZFS_UNSHARE" in
([Oo][Ff][Ff]|[Nn][Oo]|'')
exit 0
;;
esac
do_stop
;;
(force-reload|reload|restart|status)
# no-op
;;
(*)
[ -n "$1" ] && echo "Error: Unknown command $1."
echo "Usage: $0 {start|stop}"
exit 3
;;
esac
-15
View File
@@ -1,15 +0,0 @@
# ZoL userland configuration.
# uncomment the following line to mount zfs at startup
#ZFS_MOUNT=yes
# Wait this many seconds during system start for pool member devices to appear
# before attempting import and starting mountall.
ZFS_AUTOIMPORT_TIMEOUT='30'
# Run `zfs share -a` during system start?
# nb: The shareiscsi, sharenfs, and sharesmb dataset properties.
ZFS_SHARE='no'
# Run `zfs unshare -a` during system stop?
ZFS_UNSHARE='no'
-1
View File
@@ -1 +0,0 @@
KERNEL=="zd*" SUBSYSTEM=="block" ACTION=="add|change" PROGRAM="/lib/udev/zvol_id $tempnode" SYMLINK+="zvol/%c"
@@ -0,0 +1,274 @@
From 0337ccd47d411a1db11e09dce1a6d183c2542f29 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Fabian=20Gr=C3=BCnbichler?= <f.gruenbichler@proxmox.com>
Date: Mon, 6 Feb 2017 11:03:10 +0100
Subject: [PATCH 1/3] remove DKMS, modules and dracut build
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
---
debian/control.in | 36 +++---------------
debian/control | 1 -
debian/not-installed | 1 +
debian/rules | 105 +--------------------------------------------------
4 files changed, 8 insertions(+), 135 deletions(-)
diff --git a/debian/control.in b/debian/control.in
index 18d2417cc..79bd9b302 100644
--- a/debian/control.in
+++ b/debian/control.in
@@ -9,7 +9,6 @@ Build-Depends: dh-autoreconf,
dh-systemd | debhelper (>= 10.1),
autotools-dev,
debhelper (>= 9),
- dkms (>> 2.1.1.2-5),
libselinux1-dev,
libtool,
lsb-release,
@@ -85,25 +84,11 @@ Description: OpenZFS pool library for Linux
.
This zpool library provides support for managing zpools.
-Package: zfs-dkms
-Architecture: all
-Pre-Depends: spl-dkms (>= ${source:Upstream-Version})
-Depends: dkms (>> 2.1.1.2-5), lsb-release, ${misc:Depends}
-Recommends: zfsutils-linux, zfs-zed
-Provides: zfs-modules
-Description: OpenZFS filesystem kernel modules for Linux
- The Z file system is a pooled filesystem designed for maximum data
- integrity, supporting data snapshots, multiple copies, and data
- checksums.
- .
- This DKMS package includes the SPA, DMU, ZVOL, and ZPL components of
- OpenZFS.
-
Package: zfs-initramfs
Architecture: all
Depends: initramfs-tools,
busybox-initramfs | busybox-static | busybox,
- zfs-modules | zfs-dkms, zfsutils-linux,
+ zfsutils-linux,
${misc:Depends}
Description: OpenZFS root filesystem capabilities for Linux - initramfs
The Z file system is a pooled filesystem designed for maximum data
@@ -113,23 +98,12 @@ Description: OpenZFS root filesystem capabilities for Linux - initramfs
This package adds OpenZFS to the system initramfs with a hook
for the initramfs-tools infrastructure.
-Package: zfs-dracut
-Architecture: all
-Depends: dracut, zfs-modules | zfs-dkms, zfsutils-linux, ${misc:Depends}
-Description: OpenZFS root filesystem capabilities for Linux - dracut
- The Z file system is a pooled filesystem designed for maximum data
- integrity, supporting data snapshots, multiple copies, and data
- checksums.
- .
- This package adds OpenZFS to the system initramfs with a hook
- for the dracut infrastructure.
-
Package: zfsutils-linux
Section: contrib/admin
Architecture: linux-any
Depends: ${misc:Depends}, ${shlibs:Depends}, ${python3:Depends}, python3
-Recommends: lsb-base, zfs-modules | zfs-dkms, zfs-zed
-Suggests: nfs-kernel-server, samba-common-bin (>= 3.0.23), zfs-initramfs | zfs-dracut
+Recommends: lsb-base, zfs-zed
+Suggests: nfs-kernel-server, samba-common-bin (>= 3.0.23), zfs-initramfs
Conflicts: zfs, zfs-fuse, zutils
Provides: zfsutils
Description: command-line tools to manage OpenZFS filesystems
@@ -143,7 +117,7 @@ Description: command-line tools to manage OpenZFS filesystems
Package: zfs-zed
Section: contrib/admin
Architecture: linux-any
-Depends: ${misc:Depends}, ${shlibs:Depends}, zfs-modules | zfs-dkms, zfsutils-linux
+Depends: ${misc:Depends}, ${shlibs:Depends}, zfsutils-linux
Description: OpenZFS Event Daemon
The Z file system is a pooled filesystem designed for maximum data
integrity, supporting data snapshots, multiple copies, and data
@@ -154,7 +128,7 @@ Description: OpenZFS Event Daemon
Package: zfs-test
Section: contrib/admin
Architecture: linux-any
-Depends: ${misc:Depends}, ${shlibs:Depends}, zfs-modules | zfs-dkms, zfsutils-linux, parted, lsscsi, mdadm, bc, ksh, fio, acl, sudo, sysstat, python
+Depends: ${misc:Depends}, ${shlibs:Depends}, zfsutils-linux, parted, lsscsi, mdadm, bc, ksh, fio, acl, sudo, sysstat, python
Description: OpenZFS test infrastructure an support scripts
The Z file system is a pooled filesystem designed for maximum data
integrity, supporting data snapshots, multiple copies, and data
diff --git a/debian/control b/debian/control
index 18d2417cc..b426b93c0 100644
--- a/debian/control
+++ b/debian/control
@@ -9,7 +9,6 @@ Build-Depends: dh-autoreconf,
dh-systemd | debhelper (>= 10.1),
autotools-dev,
debhelper (>= 9),
- dkms (>> 2.1.1.2-5),
libselinux1-dev,
libtool,
lsb-release,
diff --git a/debian/not-installed b/debian/not-installed
index f54fe7310..16b1cef6c 100644
--- a/debian/not-installed
+++ b/debian/not-installed
@@ -5,3 +5,4 @@ etc/zfs/vdev_id.conf.alias.example
etc/zfs/vdev_id.conf.multipath.example
etc/zfs/vdev_id.conf.sas_direct.example
etc/zfs/vdev_id.conf.sas_switch.example
+usr/lib/dracut
diff --git a/debian/rules b/debian/rules
index 800df22e0..8c5beca10 100755
--- a/debian/rules
+++ b/debian/rules
@@ -5,9 +5,6 @@ NAME := $(shell awk '$$1 == "Name:" { print $$2; }' META)
VERSION := $(shell dpkg-parsechangelog \
| awk '$$1 == "Version:" { print $$2; }' | cut -d- -f1)
-DKMSFILES := module include config zfs.release.in autogen.sh META AUTHORS \
- DISCLAIMER COPYRIGHT OPENSOLARIS.LICENSE README.markdown
-
ifndef BUILD_UDEB
BUILD_UDEB=false
endif
@@ -21,21 +18,16 @@ KVERS=$(shell uname -r)
endif
ifndef SPL
-SPL=/usr/src/spl-$(VERSION)
-endif
-
-ifndef SPLOBJ
-SPLOBJ=/var/lib/dkms/spl/$(VERSION)/$(KVERS)/$(shell dpkg-architecture -qDEB_TARGET_GNU_CPU)
+SPL=../pkg-spl
endif
non_epoch_version=$(shell echo $(KVERS) | perl -pe 's/^\d+://')
PACKAGE=zfs
-pmodules = $(PACKAGE)-modules-$(non_epoch_version)
export DEB_BUILD_MAINT_OPTIONS = hardening=+all
%:
- dh $@ --with autoreconf,dkms,python3,systemd --parallel
+ dh $@ --with autoreconf,python3,systemd --parallel
override_dh_auto_configure:
@cp debian/control.in debian/control
@@ -77,36 +69,6 @@ override_dh_auto_install:
$(INSTALL) -d '$(CURDIR)/debian/tmp/usr/sbin/'
mv '$(CURDIR)/debian/tmp/sbin/zed' '$(CURDIR)/debian/tmp/usr/sbin/zed'
- @# Get a bare copy of the source code for DKMS.
- @# This creates the $(CURDIR)/$(NAME)-$(VERSION)/ tree, which does not
- @# contain the userland sources. NB: Remove-userland-dist-rules.patch
- $(MAKE) distdir
-
- @# Install the DKMS source.
- @# We only want the files needed to build the modules
- mkdir -p '$(CURDIR)/debian/tmp/usr/src/$(NAME)-$(VERSION)'
- $(foreach file,$(DKMSFILES),mv '$(CURDIR)/$(NAME)-$(VERSION)/$(file)' '$(CURDIR)/debian/tmp/usr/src/$(NAME)-$(VERSION)' || exit 1;)
- @# Hellish awk line:
- @# * Deletes from configure.ac the parts not needed for building the kernel module
- @# * It deletes from inside AC_CONFIG_FILES([]) everything except:
- @# (Makefile$|include/|module/|*.release$)
- @# * Takes care of spaces and tabs
- awk '/^AC_CONFIG_FILES\(\[/,/^\]\)/ { if ($$0 !~ /^(AC_CONFIG_FILES\(\[([ \t]+)?$$|\]\)([ \t]+)?$$|([ \t]+)?(include\/|module\/|Makefile([ \t]+)?$$|zfs\.release([ \t]+)?$$))/){next} } {print}' \
- '$(CURDIR)/$(NAME)-$(VERSION)/configure.ac' > '$(CURDIR)/debian/tmp/usr/src/$(NAME)-$(VERSION)/configure.ac'
- @# Set "SUBDIRS = module include" for CONFIG_KERNEL and remove SUBDIRS for all other configs.
- sed '1,/CONFIG_KERNEL/s/SUBDIRS.*=.*//g;s/SUBDIRS.*=.*/SUBDIRS = module include/g;' \
- '$(CURDIR)/$(NAME)-$(VERSION)/Makefile.am' > '$(CURDIR)/debian/tmp/usr/src/$(NAME)-$(VERSION)/Makefile.am'
- @# Sanity test
- grep -q 'SUBDIRS = module include' '$(CURDIR)/debian/tmp/usr/src/$(NAME)-$(VERSION)/Makefile.am'
- @# Run autogen on the stripped source tree
- cd '$(CURDIR)/debian/tmp/usr/src/$(NAME)-$(VERSION)'; ./autogen.sh
- rm -fr '$(CURDIR)/debian/tmp/usr/src/$(NAME)-$(VERSION)/autom4te.cache'
-
- @# This shunt allows DKMS to install the Module.symvers and zfs_config.h
- @# files to the ${dkms_tree} area through the POST_INSTALL directive.
- printf '#!/bin/sh\ncp "$$@"\n' > '$(CURDIR)/debian/tmp/usr/src/$(NAME)-$(VERSION)/cp'
- chmod 755 '$(CURDIR)/debian/tmp/usr/src/$(NAME)-$(VERSION)/cp'
-
mkdir -p $(CURDIR)/debian/tmp/usr/lib
for i in `ls $(CURDIR)/debian/tmp/lib/*.so`; do \
ln -s /lib/`readlink $${i}` $(CURDIR)/debian/tmp/usr/lib/`basename $${i}`; \
@@ -116,9 +78,6 @@ override_dh_auto_install:
chmod a-x $(CURDIR)/debian/tmp/etc/zfs/zfs-functions
chmod a-x $(CURDIR)/debian/tmp/etc/default/zfs
-override_dh_dkms:
- dh_dkms -V $(VERSION)
-
override_dh_makeshlibs:
dh_makeshlibs -a
ifeq ($(BUILD_UDEB), true)
@@ -156,65 +115,5 @@ override_dh_install:
# ------------
-override_dh_prep-deb-files:
- for templ in $(wildcard $(CURDIR)/debian/*_KVERS_*.in); do \
- sed -e 's/##KVERS##/$(KVERS)/g ; s/#KVERS#/$(KVERS)/g ; s/_KVERS_/$(KVERS)/g ; s/##KDREV##/$(KDREV)/g ; s/#KDREV#/$(KDREV)/g ; s/_KDREV_/$(KDREV)/g ; s/_ARCH_/$(DEB_HOST_ARCH)/' \
- < $$templ > `echo $$templ | sed -e 's/_KVERS_/$(KVERS)/g ; s/_ARCH_/$(DEB_HOST_ARCH)/g ; s/\.in$$//'` ; \
- done
- sed -e 's/##KVERS##/$(KVERS)/g ; s/#KVERS#/$(KVERS)/g ; s/_KVERS_/$(KVERS)/g ; s/##KDREV##/$(KDREV)/g ; s/#KDREV#/$(KDREV)/g ; s/_KDREV_/$(KDREV)/g ; s/_ARCH_/$(DEB_HOST_ARCH)/g' \
- < debian/control.modules.in > debian/control
-
-override_dh_configure_modules_udeb: override_dh_configure_modules_udeb_stamp
-override_dh_configure_modules_udeb_stamp:
- ./configure \
- --without-selinux \
- --with-config=kernel \
- --with-linux=$(KSRC) \
- --with-linux-obj=$(KOBJ) \
- --with-spl=$(SPL) \
- --with-spl-obj=$(SPLOBJ)
- touch override_dh_configure_modules_udeb_stamp
-
-override_dh_configure_modules: override_dh_configure_modules_stamp
-override_dh_configure_modules_stamp:
- ./configure \
- --with-config=kernel \
- --with-linux=$(KSRC) \
- --with-linux-obj=$(KOBJ) \
- --with-spl=$(SPL) \
- --with-spl-obj=$(SPLOBJ)
- touch override_dh_configure_modules_stamp
-
-override_dh_binary-modules-udeb: override_dh_prep-deb-files override_dh_configure_modules_udeb
- dh_testdir
- dh_testroot
- dh_prep
-
- $(MAKE) -C $(CURDIR)/module modules
-
- dh_installdirs -p${pmodules}-di
- dh_install -p${pmodules}-di
- dh_gencontrol -p${pmodules}-di
-
- dh_builddeb -p${pmodules}-di
-
-override_dh_binary-modules: override_dh_prep-deb-files override_dh_configure_modules
- dh_testdir
- dh_testroot
- dh_prep
-
- $(MAKE) -C $(CURDIR)/module modules
-
- dh_install -p${pmodules}
- dh_installdocs -p${pmodules}
- dh_installchangelogs -p${pmodules}
- dh_compress -p${pmodules}
- dh_strip -p${pmodules}
- dh_fixperms -p${pmodules}
- dh_installdeb -p${pmodules}
- dh_gencontrol -p${pmodules}
- dh_md5sums -p${pmodules}
- dh_builddeb -p${pmodules}
-
debian-copyright:
cme update dpkg-copyright -file debian/copyright.cme
--
2.14.2
@@ -0,0 +1,29 @@
From 72fbbc64fe6f9e527e7ebce42d8e57c1fa82dd34 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Fabian=20Gr=C3=BCnbichler?= <f.gruenbichler@proxmox.com>
Date: Mon, 24 Oct 2016 13:47:06 +0200
Subject: [PATCH 2/3] import with -d /dev/disk/by-id in scan service
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
---
etc/systemd/system/zfs-import-scan.service.in | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/etc/systemd/system/zfs-import-scan.service.in b/etc/systemd/system/zfs-import-scan.service.in
index 625f3a955..9a33d5f4a 100644
--- a/etc/systemd/system/zfs-import-scan.service.in
+++ b/etc/systemd/system/zfs-import-scan.service.in
@@ -11,7 +11,7 @@ ConditionPathExists=!@sysconfdir@/zfs/zpool.cache
Type=oneshot
RemainAfterExit=yes
ExecStartPre=/sbin/modprobe zfs
-ExecStart=@sbindir@/zpool import -aN -o cachefile=none
+ExecStart=@sbindir@/zpool import -aN -d /dev/disk/by-id -o cachefile=none
[Install]
WantedBy=zfs-mount.service
--
2.14.2
@@ -0,0 +1,66 @@
From f9171eb92ffd260debce2b28111dc7018d258588 Mon Sep 17 00:00:00 2001
From: Wolfgang Bumiller <w.bumiller@proxmox.com>
Date: Tue, 31 Oct 2017 09:08:42 +0100
Subject: [PATCH 3/3] Use user namespaces for FSETID policy check.
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
With this we also need to verify the group id of a file with
the setgid flag has a valid mapping in the current
namespace.
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
---
module/zfs/policy.c | 16 +++++++++++++---
1 file changed, 13 insertions(+), 3 deletions(-)
diff --git a/module/zfs/policy.c b/module/zfs/policy.c
index 03e8f748b..dbbcfefa3 100644
--- a/module/zfs/policy.c
+++ b/module/zfs/policy.c
@@ -42,19 +42,26 @@
* all other cases this function must fail and return the passed err.
*/
static int
-priv_policy(const cred_t *cr, int capability, boolean_t all, int err)
+priv_policy_ns(const cred_t *cr, int capability, boolean_t all, int err,
+ struct user_namespace *ns)
{
ASSERT3S(all, ==, B_FALSE);
if (cr != CRED() && (cr != kcred))
return (err);
- if (!capable(capability))
+ if (!(ns ? ns_capable(ns, capability) : capable(capability)))
return (err);
return (0);
}
+static int
+priv_policy(const cred_t *cr, int capability, boolean_t all, int err)
+{
+ return priv_policy_ns(cr, capability, all, err, NULL);
+}
+
/*
* Checks for operations that are either client-only or are used by
* both clients and servers.
@@ -175,8 +182,11 @@ secpolicy_vnode_setid_retain(const cred_t *cr, boolean_t issuidroot)
int
secpolicy_vnode_setids_setgids(const cred_t *cr, gid_t gid)
{
+ if (!kgid_has_mapping(cr->user_ns, SGID_TO_KGID(gid)))
+ return (EPERM);
if (crgetfsgid(cr) != gid && !groupmember(gid, cr))
- return (priv_policy(cr, CAP_FSETID, B_FALSE, EPERM));
+ return (priv_policy_ns(cr, CAP_FSETID, B_FALSE, EPERM,
+ cr->user_ns));
return (0);
}
--
2.14.2
+3
View File
@@ -0,0 +1,3 @@
0001-remove-DKMS-modules-and-dracut-build.patch
0002-import-with-d-dev-disk-by-id-in-scan-service.patch
0003-Use-user-namespaces-for-FSETID-policy-check.patch