debian/0000775000000000000000000000000012703443742007176 5ustar debian/zfsutils-linux.zfs.default0000664000000000000000000000116112656130051014355 0ustar # ZoL userland configuration. # 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' # Build kernel modules with the --enable-debug switch? ZFS_DKMS_ENABLE_DEBUG='no' # Build kernel modules with the --enable-debug-dmu-tx switch? ZFS_DKMS_ENABLE_DEBUG_DMU_TX='no' # Keep debugging symbols in kernel modules? ZFS_DKMS_DISABLE_STRIP='no' debian/changelog0000664000000000000000000006331212703431467011056 0ustar zfs-linux (0.6.5.6-0ubuntu8) xenial; urgency=medium [ Richard Laager ] * zfs-initramfs: Set elevator=noop on disks used by the root pool. (LP: #1550301) -- Colin Ian King Wed, 13 Apr 2016 11:44:39 +0100 zfs-linux (0.6.5.6-0ubuntu7) xenial; urgency=medium * Libraries should not be in /lib, but in /usr/lib (LP: #1569359) -- Colin Ian King Tue, 12 Apr 2016 12:54:17 +0100 zfs-linux (0.6.5.6-0ubuntu6) xenial; urgency=medium * Remove adm, admin, staff groups from /etc/sudoers.d/zfs (LP: #1532198) -- Colin Ian King Fri, 8 Apr 2016 15:16:39 +0100 zfs-linux (0.6.5.6-0ubuntu5) xenial; urgency=medium * Only enable testing on 64 bit arches as these are the ones that ZFS officially supports. -- Colin Ian King Tue, 5 Apr 2016 09:37:37 +0100 zfs-linux (0.6.5.6-0ubuntu4) xenial; urgency=medium * Drop mail-transport-agent to Suggests, and add default-mta preference. -- Colin Ian King Fri, 1 Apr 2016 19:18:11 +0100 zfs-linux (0.6.5.6-0ubuntu3) xenial; urgency=medium * Add support 32 bit FS_IOC32_{GET|SET}FLAGS compat ioctls -- Colin Ian King Wed, 30 Mar 2016 23:08:24 +0000 zfs-linux (0.6.5.6-0ubuntu2) xenial; urgency=medium * Fix aarch64 compilation, missing hrtime_t and timestruc_t types -- Colin Ian King Sat, 26 Mar 2016 10:30:41 +0000 zfs-linux (0.6.5.6-0ubuntu1) xenial; urgency=medium [ Colin Ian King ] * Sync with upstream 0.6.5.6 release Remove scripts/zfault.sh from debian/zfs-doc.examples (no longer exists) Add libblkid-dev, libattr1-dev build dependencies [ Richard Laager ] * Scrub all healthy pools monthly (LP: #1548009) -- Colin Ian King Wed, 23 Mar 2016 23:59:33 +0000 zfs-linux (0.6.5.5-0ubuntu1) xenial; urgency=medium [ Colin Ian King ] * Sync with upstream 0.6.5.5 release [ Chad Miller ] * Update /lib/udev/rules.d/60-zfs.rules to create symlinks for GRUB (LP: #1530953) for cases when the parition type ID is not a "Solaris ZFS" /"Apple ZFS" type. Peek at the asserted partition contents, not just the container state. -- Colin Ian King Mon, 21 Mar 2016 10:27:11 +0000 zfs-linux (0.6.5.4-0ubuntu6) xenial; urgency=medium * cherry-pick 8e85373c1ded7866ae168dde3bd640769c093172 from https://github.com/zfsonlinux/zfs/pull/4425. * Set architecture to any. -- Dimitri John Ledkov Wed, 16 Mar 2016 23:09:55 +0000 zfs-linux (0.6.5.4-0ubuntu5) xenial; urgency=medium * cherry-picked c352ec27d5c5ecea8f6af066258dfd106085eaac ('Illumos 6370 - ZFS send fails to transmit some holes') (LP: #1557151) -- Tim Gardner Mon, 14 Mar 2016 16:42:44 -0600 zfs-linux (0.6.5.4-0ubuntu4) xenial; urgency=medium [ Richard Laager ] * Make zed work out-of-the box (LP: #1542276) - zfs-zed: Install zed-functions.sh so scriptlets work - zfs-zed: Enable most scriptlets on a fresh install. - zfs-zed: Email root by default. -- Colin Ian King Wed, 24 Feb 2016 04:49:35 +0000 zfs-linux (0.6.5.4-0ubuntu3) xenial; urgency=medium * zfsutils-linux should Recommend zfs-zed (LP: #1547549) -- Colin Ian King Fri, 19 Feb 2016 15:23:11 +0000 zfs-linux (0.6.5.4-0ubuntu2) xenial; urgency=medium [ Colin Ian King ] * Start ZFS post install with dh_systemd_start (LP: #1542276) * Fix perms on initramfs-tools/hooks if they exist * install bash completions to usr/share/bash-completion/completions * debian/control: add in Homepage field [ Richard Laager ] * Add /lib/udev/rules.d/60-zfs.rules to create symlinks for GRUB (LP: #1530953) * debian/control: Remove incorrect Vcs-Git and Vcs-Browser * zfs-initramfs: Re-architect initramfs script - Require root=ZFS= syntax. rpool= and bootfs= are no longer supported. - Honor Debian standard rootdelay= kernel command-line option instead of ZFS_INITRD_PRE_MOUNTROOT_SLEEP. - Use standard panic function, which honors the Debian standard panic= kernel command-line option. - Stop force importing the pool. - Add debian/zfs-initramfs.postinst to apply udev rules without a reboot - Update 60-zpool.rules to match on partition type to trigger on the initial pool creation. -- Colin Ian King Tue, 9 Feb 2016 09:14:44 +0000 zfs-linux (0.6.5.4-0ubuntu1) xenial; urgency=medium * Sync with upstream 0.6.5.4 release -- Colin Ian King Fri, 29 Jan 2016 11:48:00 +0000 zfs-linux (0.6.5.3-0ubuntu6) xenial; urgency=medium * zfs-initramfs: Support GRUB's native root=ZFS= (LP: #1530953) - from https://github.com/zfsonlinux/pkg-zfs/pull/140 (Richard Laager) * debian/control: Add missing "Provides: zfs" (LP: #1535428) -- Colin Ian King Thu, 21 Jan 2016 11:09:01 +0000 zfs-linux (0.6.5.3-0ubuntu5) xenial; urgency=medium * Add adt smoke tests checking basic core ZFS functionality -- Colin Ian King Mon, 11 Jan 2016 16:25:00 +0000 zfs-linux (0.6.5.3-0ubuntu4) xenial; urgency=medium * Add dependency on dh-systemd for zfs-linux (LP: #1521952) - Add installinit rules for zed, zfs, mounting and import cache/scan - Copy zfs.target to /lib/systemd/system - Add bash completion rules - Add zed systemd service control - Add zfs shared systemd service control - Add zfs mount systemd service control - Add zfs import scan systemd service control - Add zfs import cache systemd service control -- Colin Ian King Wed, 2 Dec 2015 16:50:00 +0000 zfs-linux (0.6.5.3-0ubuntu3) xenial; urgency=medium * Build for powerpc64-smp -- Tim Gardner Fri, 06 Nov 2015 14:20:13 -0700 zfs-linux (0.6.5.3-0ubuntu2) xenial; urgency=medium * Dropped autogen output from orig tarball. * update debian/gbp.conf from wily to xenial -- Tim Gardner Tue, 27 Oct 2015 18:16:11 +0000 zfs-linux (0.6.5.3-0ubuntu1) xenial; urgency=medium * Updated to zfs-0.6.5.3 from https://github.com/zfsonlinux/zfs.git * Dropped: Linux 4.2 compat: bdi_setup_and_register() Linux 4.2 compat: remove bio->bi_cnt access Linux 4.2 compat: follow_link() / put_link() -- Tim Gardner Tue, 27 Oct 2015 10:50:44 -0600 zfs-linux (0.6.4.2-0ubuntu2~apw8) wily; urgency=medium * ppc64el: drop endian override in powerpc architecture definition allowing both big and little endian builds. * zfs-initramfs -- this is only build on the indep architecture so only attempt to chmod the hook files if they are present. * arm64: reorder sys/types.h sys/param.h includes to avoid include ordering issues on arm64. -- Andy Whitcroft Fri, 16 Oct 2015 13:57:18 +0100 zfs-linux (0.6.4.2-0ubuntu1) wily; urgency=medium [ Colin Ian King ] * Linux 4.2 compat: bdi_setup_and_register() * Linux 4.2 compat: remove bio->bi_cnt access * Linux 4.2 compat: follow_link() / put_link() * update debian/gbp.conf from vivid to wily * update Standards-Version to 3.9.6 * fix dep5-copyright-license-name-not-unique warning * prepared for Ubuntu Wily upload [ Iain Lane ] * Drop the upstart integration; this was causing various lintian errors and required some fixing up - we use systemd in wily anyway. * Copy the debian/copyright file as it is slightly more correct. * Install the bash-completion files in the (new) correct directory. * Don't handle upgrades from non-archive packages. * Add Depends from the -dev package to all libraries which we ship .so files for. * Don't ship .la files. * Make some packages Architecture: all where they don't ship architecture dependent files. -- Colin Ian King Wed, 14 Oct 2015 15:46:29 +0100 zfs-linux (0.6.4.2-0~vivid) vivid; urgency=low [ Brian Behlendorf ] * Wait in libzfs_init() for the /dev/zfs device * Use ExecStartPre to load zfs modules * Wait interruptibly in prefetch thread [ Tim Chase ] * Linux 3.12 compat: NUMA-aware per-superblock shrinker [ Matus Kral ] * Linux 4.1 compat: use read_iter() / write_iter() [ Brian Behlendorf ] * Add zfs_sb_prune_aliases() function [ Chris Dunlop ] * Wait for all znodes to be released before tearing down the superblock [ tuxoko ] * Add cond_resched to zfs_zget to prevent infinite loop [ Ned Bass ] * Serialize access to spa->spa_feat_stats nvlist * Tag zfs-0.6.4.2 [ Darik Horn ] * Refresh debian/patches after upstream merge. -- Darik Horn Thu, 09 Jul 2015 22:42:29 -0400 zfs-linux (0.6.4.1-1~vivid) vivid; urgency=low [ Tim Chase ] * Allocate zfs_znode_cache on the Linux slab [ Brian Behlendorf ] * Mark additional functions as PF_FSTRANS [ Chris Dunlap ] * Fix io-spare.sh to work with disk vdevs [ Brian Behlendorf ] * Extend PF_FSTRANS critical regions * Tag zfs-0.6.4.1 -- Darik Horn Fri, 24 Apr 2015 16:42:15 -0500 zfs-linux (0.6.4-3~vivid) vivid; urgency=low [ SenH ] * Fix man zpool property feature_guid [ Turbo Fredriksson ] * Add information about the -o option to zpool replace [ Brian Behlendorf ] * Improve differing sector size error [ Tim Chase ] * Comment the lack of real_LZ4_uncompress() [ Dan McDonald ] * Illumos #4936 fix potential overflow in lz4 [ Tim Chase ] * Return default value on numeric properties failing the "head check. * Document the optional "device" argument for "zpool split" [ Garrison Jensen ] * Fix comment spelling errors. [ Andrew Barnes ] * Preserve asize when last mirror child promoted to top-level vdev [ Matthew Ahrens ] * Illumos #3641 compressed block histograms with zdb [ Tim Chase ] * Convert zfs_mg_noalloc_threshold to a module parameter and document [ George Wilson ] * Illumos 4168, 4169, 4170: ztest, zdb and zhack fixes [ Richard Yao ] * zdb: Introduce -V for verbatim import [ Brian Behlendorf ] * Fix zil_commit() NULL dereference [ Prakash Surya ] * Move metaslab_group_alloc_update() call [ George Wilson ] * Illumos #4101, #4102, #4103, #4105, #4106 * Illumos #4730 destroy metaslab group taskq * Illumos #4756 Fix metaslab_group_preload deadlock [ Brian Behlendorf ] * zfs_trunc() should use dmu_tx_assign(tx, TXG_WAIT) [ Jan Engelhardt ] * Do not attempt access beyond the declared end of the dn_blkptr array [ Brian Behlendorf ] * Revert "Disable GCCs aggressive loop optimization" * zpool-create.sh: allow features to be disabled [ Turbo Fredriksson ] * Initial attempt to document events and payloads. * Support '-H' (scripted mode) to 'zpool get' (Closes: #2522) [ Brian Behlendorf ] * Remove patches directory [ Matthew Ahrens ] * Illumos 4171, 4172 [ Max Grossman ] * Illumos 4370, 4371 [ Matthew Ahrens ] * Illumos 4368, 4369. * Illumos #4374 [ George Wilson ] * Illumos 4754, 4755 [ Tim Chase ] * zed needs libzfs_core [ Matthew Ahrens ] * Illumos 3835 zfs need not store 2 copies of all metadata * Illumos 4757, 4913 * Illumos 4390 - I/O errors can corrupt space map when deleting fs/vol [ Saso Kiselkov ] * Illumos 4897 - Space accounting mismatch in L2ARC/zpool [ Matthew Ahrens ] * Illumos 4881 - zfs send performance regression with embedded data * Illumos 4914 - zfs on-disk bookmark structure should be named *_phys_t [ Turbo Fredriksson ] * Add bash completions by Aneurin Price. [ Brian Behlendorf ] * Use KM_PUSHPAGE in dsl_dataset_rollback_check() * Avoid dynamic allocation of 'search zio' * Avoid 128K kmem allocations in mzap_upgrade() * Add zfs_iput_async() interface * Revert "Revert "Revert "Fix unlink/xattr deadlock""" [ Alec Salazar ] * Replace __va_list with va_list * Avoid PAGESIZE redefinition [ Evan Susarret ] * Correct autodetection of bootfs property [ Richard Yao ] * Include sys/taskq.h in linux/vfs_compat.h [ Turbo Fredriksson ] * Create an 'overlay' property (Closes: #2503) [ George Wilson ] * Illumos 4976-4984 - metaslab improvements [ Tim Chase ] * Don't upgrade a metaslab when the pool is not writable [ Richard Yao ] * Drive database update [ Matthew Ahrens ] * Illumos 4631 - zvol_get_stats triggering too many reads [ Isaac Huang ] * Fixed memory leaks in zevent handling [ Andrew Hamilton ] * 2493 change efi_rescan() to wait longer [ Matthew Ahrens ] * Illumos 5034 - ARC's buf_hash_table is too small * Illumos 4970-4974 - extreme rewind enhancements [ Brian Behlendorf ] * Retire HAVE_IOCTL_* configure checks [ Turbo Fredriksson ] * Add a pkgconfig file (Closes: #585) [ Brian Behlendorf ] * Add a missing > to AUTHORS [ Chris Dunlap ] * Fix race condition with zed pidfile creation * Cleanup zed logging [ Ralf Ertzinger ] * Change startup mode of ZED [ louwrentius ] * Change delimiter for ZED email scripts [ Dan Swartzendruber ] * Improve handling of filesystem versions (Closes: #2616) [ Alexey Smirnoff ] * Change the default 'zfs_dedup_prefetch' value to '0' [ alteriks ] * Import zfs pools after cryptsetup [ Stanislav Seletskiy ] * Fix invalid locking order in rename operation [ Alex Reece ] * Illumos 5049 - panic when removing log device [ ilovezfs ] * Fragmentation should display as '-' if spacemap_histogram=disabled [ Richard Yao ] * Linux AIO Support [ Brian Behlendorf ] * Add object type checking to zap_lockdir() [ George Wilson ] * Illumos 5117 - spacemap reallocation can cause corruption [ Tim Chase ] * Implement fallocate FALLOC_FL_PUNCH_HOLE * Document the "readonly" pool property [ Brian Behlendorf ] * Fix z_teardown_inactive_lock deadlock [ Turbo Fredriksson ] * Document environment variables for zdb, zfs, zinject and zpool. [ Matthew Ahrens ] * Illumos 5140 - message about "%recv could not be opened" is printed when booting after crash [ Chris Dunlap ] * Remove reverse indentation from zed comments. [ Ned Bass ] * Remove obsolete comment about guard pages [ Adam Leventhal ] * Illumos 5174 - add sdt probe for blocked read in dbuf_read() [ Matthew Ahrens ] * Illumos 5177 - remove dead code from dsl_scan.c * Illumos 5161 - add tunable for number of metaslabs per vdev [ George Wilson ] * Illumos 5147 - zpool list -v should show individual disk capacity [ Richard Yao ] * Properly NULL terminate string in zfs_strcmp_pathname * Fix function call with uninitialized value in vdev_inuse * lib/libzpool/kernel.c: Assert no owners in rw_destroy() [ Matthew Ahrens ] * Illumos 5139 - SEEK_HOLE failed to report a hole at end of file * Illumos 5135 - zpool_find_import_cached() can use fnvlist_* * Illumos 5116 - zpool history -i goes into infinite loop [ Alex Reece ] * Illumos 4753 - increase number of outstanding async writes when sync task is waiting [ Max Grossman ] * Illumos 5138 - add tunable for maximum number of blocks freed in one txg [ Chris Dunlap ] * Fix zed io-spare.sh dash incompatibility * Replace zed's use of malloc with calloc * Refer to ZED's scripts as ZEDLETs [ Tim Chase ] * Perform whole-page page truncation for hole-punching under a range lock [ Brian Behlendorf ] * Make user stack limit configurable [ Richard Yao ] * Add add_prop_list_default helper * zpool import -t should not update cachefile * Implement -t option to zpool create for temporary pool names [ smh ] * FreeBSD PR kern/172259: Fixes zfs receive errors [ Andriy Gapon ] * zfs send -p send properties only for snapshots that are actually sent [ Chris Dunlap ] * Obtain advisory lock on ZED PID file * Cleanup struct zed_conf vars in zed_conf_destroy [ Lukas Wunner ] * Amend Dracut module to export ZFS root on shutdown [ Matthew Ahrens ] * Illumos 5176 - lock contention on godfather zio [ Turbo Fredriksson ] * Add an example for 'zfs bookmark' to the Example section. [ Brian Behlendorf ] * Fix CPU_SEQID use in preemptible context * Improve VERIFY() error in dmu_write() [ Turbo Fredriksson ] * Add a stern warning about dedup [ Tom Prince ] * Install header during post-build rather than post-install. * Point dkms build at installed source tree, rather than build directory. [ Brian Behlendorf ] * Fix source_tree variable in dkms build [ Ned Bass ] * ztest: print backtrace on SIGSEGV and SIGABRT [ Brian Behlendorf ] * Make license compatibility checks consistent * Update code to use misc_register()/misc_deregister() * Remove shrink_dcache_memory() and shrink_icache_memory() * Update utsname support * Handle NULL mirror child vdev [ Darik Horn ] * Let `zpool import` ignore a missing hostid record. [ Brian Behlendorf ] * Suppress AIO kmem warnings [ Daniil Lunev ] * Illumos 4924 - LZ4 Compression for metadata [ Tim Chase ] * Don't perform ACL-to-mode translation on empty ACL [ Matthew Ahrens ] * Illumos 3693 - restore_object uses at least two transactions to restore an object * Illumos 5150 - zfs clone of a defer_destroy snapshot causes strangeness * Illumos 5162 - zfs recv should use loaned arc buffer to avoid copy [ Ned Bass ] * Remove checks for mandatory locks [ Brian Behlendorf ] * Handle block pointers with a corrupt logical size [ ilovezfs ] * Fix zpool create -t ENOENT bug. [ Matthew Ahrens ] * Illumos 5178 - zdb -vvvvv on old-format pool fails in dump_deadlist() * Illumos 5169-5171 - zdb fixes [ Brian Behlendorf ] * Fix zdb segfault [ Alex Reece ] * Illumos 4958 zdb trips assert on pools with ashift >= 0xe [ Matthew Ahrens ] * Illumos 5164-5165 - space map fixes [ Tim Chase ] * Linux 3.12 compat: shrinker semantics [ Richard Yao ] * Kernel header installation should respect --prefix * Search /usr/local/src for SPL Object Directory * Make directory into which mount.zfs is installed configurable * Make systemd-modules-load.service file directory configurable [ Alexander Pyhalov ] * Fix modules installation directory [ Marcel Wysocki ] * Add config/compile to config/.gitignore [ Dan Swartzendruber ] * Improve zvol symlink handling. [ Alex Zhuravlev ] * Export symbols for ZIL interface [ Chris Wedgwood ] * Reduce buf/dbuf mutex contention [ Isaac Huang ] * Fix inaccurate field descriptions * Print header properly when terminal resizes [ Prakash Surya ] * Illumos 5213 - panic in metaslab_init due to space_map_open returning ENXIO [ Randall Mason ] * Fix small spelling mistake [ Ned Bass ] * Move a few internal ARC strucutres to arc_impl.h * Fix dprintf format specifiers * cstyle: allow right paren on its own line [ Prakash Surya ] * Swap DTRACE_PROBE* with Linux tracepoints [ Tim Chase ] * Undirty freed spill blocks. [ smh ] * Prevent ZFS leaking pool free space [ Ned Bass ] * Fix improper null-byte termination handling * Explicitly include SPL compat headers [ Isaac Huang ] * bio_alloc() with __GFP_WAIT never returns NULL [ Dan Swartzendruber ] * Fix systemd config for zfs-share.service [ Brian Behlendorf ] * Fix snapshots with dirty inodes [ Dan Swartzendruber ] * Improve systemd script to not leave stale sharetab [ Jacek Fefliński ] * zpool upgrade return errors to stderr instead of stdout [ Andy Bakun ] * Fix typo in %post scriptlet lines [ Boris Protopopov ] * Correct error returns to unify cross-pool operation error handling [ Brian Behlendorf ] * Fix cstyle issue from c66989b [ Ned Bass ] * vdev_id: use mawk-compatible regular expression [ Brian Behlendorf ] * Fix zfs_putpage() lock inversion [ Ned Bass ] * Remove duplicate typedefs from trace.h * Don't use AC_LANG_SOURCE for conftest.h source * Document zfs_flags module parameter [ Brian Behlendorf ] * Fix zfs_putpage() lock inversion (again) * Mark IO pipeline with PF_FSTRANS [ Richard Yao ] * Use is_vmalloc_addr() in vdev_disk.c [ Brian Behlendorf ] * Retire KM_NODEBUG * Change KM_PUSHPAGE -> KM_SLEEP * Add kmem_cache.h include to default context * Revert "Pre-allocate vdev I/O buffers" * Revert "SA spill block cache" [ Tim Chase ] * Linux 3.12 compat: split shrinker has s_shrink [ Richard Yao ] * Use kmem_vasprintf() in log_internal() [ Tim Chase ] * Fix removal of SA in sa_modify_attrs() [ cburroughs ] * Add arc_summary.py from FreeNAS * Modified arc_summary.py to run on linux [ Kyle Blatter ] * Refactor arc_summary to simplify -p processing * Add a help option with usage information * Force all lines to be 80 columns * Replace sysctl summary with tunables summary. [ Brian Behlendorf ] * Make `zpool import -d|-c` behave consistently [ Richard Yao ] * Use (void) memcpy(), not (void *) memcpy() [ Brian Behlendorf ] * Add zvol_open() error handling for readonly property * Handle closing an unopened ZVOL [ Chris Dunlap ] * Protect against adding duplicate strings in ZED * Cleanup _zed_event_add_nvpair() [ Brian Behlendorf ] * Use zio buffers in zil_itx_create() [ avg ] * fix l2arc compression buffers leak [ Tim Chase ] * Spurious ENOMEM returns when reading dbufs kstat [ Chunwei Chen ] * Read spl_hostid module parameter before gethostid() * Fix build error when make deb [ Brian Behlendorf ] * Skip evicting dbufs when walking the dbuf hash [ Ned Bass ] * Fix SA header size accounting [ Justin T. Gibbs ] * Illumos 5311 - traverse_dnode may report success when it should not [ Lukas Wunner ] * Fix loop in Dracut shutdown script * Fix Dracut scripts to allow for blanks in pool and dataset names [ Brian Behlendorf ] * Don't read space maps during import for readonly pools [ Tim Chase ] * Produce a full snapshot list for zfs send -p [ Brian Behlendorf ] * Revert "Don't read space maps during import for readonly pools" * Use vmem_alloc() for nvlists [ Jörg Thalheim ] * Linux 3.19 compat: file_inode was added [ Brian Behlendorf ] * Retire zio_bulk_flags * Retire zio_cons()/zio_dest() [ Andrey Vesnovaty ] * Fix readdir for .zfs/snapshot directory [ Brian Behlendorf ] * Change VERIFY to ASSERT in mutex_destroy() [ Tim Chase ] * Enhancements to zpool dry run mode. [ Sören Tempel ] * Use test(1) in a proper way * Write directly to $initdir [ Brian Behlendorf ] * Skip bad DVAs during free by setting zfs_recover=1 [ Dan Swartzendruber ] * Set zfs_autoimport_disable default value to 1 [ Steffen Müthing ] * Add required files to initramfs * Fix error in dracut script if not using ZFS root [ Brian Behlendorf ] * Fix O_APPEND open(2) flag * Retire spl_module_init()/spl_module_fini() [ Christer Ekholm ] * Fix possible future overflow in zfs_nicenum [ Tim Chase ] * Avoid dladdr() in ztest [ Brian Behlendorf ] * Prevent "zpool destroy|export" when suspended [ Isaac Huang ] * Fix deadlock between zpool export and zfs list [ Brian Behlendorf ] * Use MUTEX_FSTRANS mutex type * Linux 4.0 compat: bdi_setup_and_register() * Change ASSERT(!"...") to cmn_err(CE_PANIC, ...) [ Turbo Fredriksson ] * Install arc_summary.py [ Brian Behlendorf ] * Replace zfs.redhat.in with zfs.lsb.in init script [ Chris Dunlap ] * Add ZED to zfs.redhat.in script [ Ned Bass ] * Use cached feature info in spa_add_feature_stats() [ Hajo Möller ] * Actually source /etc/sysconfig/zfs instead of /etc/default/zfs [ Brian Behlendorf ] * Mark zfs_inactive() with PF_FSTRANS [ Josef 'Jeff' Sipek ] * Illumos 5047 - don't use atomic_*_nv if you discard the return value [ Justin T. Gibbs ] * Illumos 5630 - stale bonus buffer in recycled dnode_t leads to data corruption [ Bill McGonigle ] * Linux 4.0 compat: bdi_setup_and_register() __must_check [ Hajo Möller ] * Fix warning about AM_INIT_AUTOMAKE arguments [ Chunwei Chen ] * Use MUTEX_FSTRANS on l2arc_buflist_mtx [ Turbo Fredriksson ] * Move duplicate information about the 'zfs send -e' option. [ Richard Yao ] * Increase Linux pipe buffer size on 'zfs receive' [ Brian Behlendorf ] * Fix arc_meta_max accounting * Restructure per-filesystem reclaim * Fix arc_adjust_meta() behavior [ Chris Dunlop ] * Reduce size of zfs_sb_t: allocate z_hold_mtx separately [ Isaac Huang ] * zio_injection_enabled should not be a module option [ Gordan Bobic ] * Execute udevadm settle before trying to import pools [ Tim Chase ] * Set the maximum ZVOL transfer size correctly [ Ned Bass ] * dbuf_free_range() overzealously frees dbufs [ Brian Behlendorf ] * Check all vdev labels in 'zpool import' * Remove rpm/fedora directory * Add RHEL style kmod packages [ Ned Bass ] * Add NULL guard in zfs_zrlock_class event class * zpool import should honor overlay property [ Prakash Surya ] * Illumos 5695 - dmu_sync'ed holes do not retain birth time [ Chris Dunlop ] * Align code with Illumos [ George Wilson ] * Illumos 5694 - traverse_prefetcher does not prefetch enough [ Matthew Ahrens ] * Illumus 5693 - ztest fails in dbuf_verify: buf[i] == 0, due to dedup and bp_override [ Brian Behlendorf ] * Update zfs_pd_bytes_max default in zfs(8) [ Tim Chase ] * Mark all ZPL and ioctl functions as PF_FSTRANS [ Brian Behlendorf ] * Use vmem_alloc() in spa_config_write() * Tag zfs-0.6.4 [ Darik Horn ] * Refresh debian/patches after upstream merge. * Package zed separately. * Prevent driver modprobe in the zed upstart job. -- Darik Horn Thu, 09 Apr 2015 13:04:16 -0500 zfs-linux (0.6.3-15~vivid) vivid; urgency=low [ Brian Behlendorf ] * Tag zfs-0.6.3-1.2 [ Darik Horn ] * Update gbp.conf for Ubuntu 15.04 Vivid Vervet. -- Darik Horn Sat, 21 Feb 2015 13:40:18 -0500 debian/libnvpair1linux.install0000664000000000000000000000003312703172716013711 0ustar lib/libnvpair.so.* usr/lib debian/patches/0000775000000000000000000000000012677047044010632 5ustar debian/patches/1001-Fix-aarch64-compilation.patch0000664000000000000000000000201612675561325016522 0ustar From d76d9c696a79b07a4d874f20855d8828d84f03f6 Mon Sep 17 00:00:00 2001 From: Gordan Bobic Date: Tue, 15 Mar 2016 17:17:51 +0000 Subject: [PATCH] Fix aarch64 compilation sys/param.h depends on types defined in sys/types.h (hrtime_t & timestruc_t). Signed-off-by: Gordan Bobic Signed-off-by: Christopher J. Morrone Signed-off-by: Brian Behlendorf Closes #4420 --- lib/libspl/include/sys/types.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/libspl/include/sys/types.h b/lib/libspl/include/sys/types.h index 9816345..25d56be 100644 --- a/lib/libspl/include/sys/types.h +++ b/lib/libspl/include/sys/types.h @@ -30,7 +30,6 @@ #include #include #include_next -#include /* for NBBY */ #include #include @@ -95,4 +94,6 @@ typedef union { } lloff_t; #endif +#include /* for NBBY */ + #endif -- 2.7.3 debian/patches/0001-Prevent-manual-builds-in-the-DKMS-source.patch0000664000000000000000000000274312674630164021627 0ustar Index: zfs-linux-0.6.5.6/config/dkms.m4 =================================================================== --- /dev/null +++ zfs-linux-0.6.5.6/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]) + ]) +]) Index: zfs-linux-0.6.5.6/config/user.m4 =================================================================== --- zfs-linux-0.6.5.6.orig/config/user.m4 +++ zfs-linux-0.6.5.6/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_MOUNT_HELPER ZFS_AC_CONFIG_USER_UDEV ZFS_AC_CONFIG_USER_SYSTEMD Index: zfs-linux-0.6.5.6/config/zfs-build.m4 =================================================================== --- zfs-linux-0.6.5.6.orig/config/zfs-build.m4 +++ zfs-linux-0.6.5.6/config/zfs-build.m4 @@ -87,8 +87,8 @@ AC_DEFUN([ZFS_AC_CONFIG], [ ZFS_AC_CONFIG_ALWAYS case "$ZFS_CONFIG" in - kernel) ZFS_AC_CONFIG_KERNEL ;; user) ZFS_AC_CONFIG_USER ;; + kernel) ZFS_AC_CONFIG_KERNEL ;; all) ZFS_AC_CONFIG_KERNEL ZFS_AC_CONFIG_USER ;; srpm) ;; debian/patches/0003-Add-libuutil-to-LIBADD-for-libzfs-and-libzfs_core.patch0000664000000000000000000000211412656130051023203 0ustar Index: zfs-linux-0.6.5.3/lib/libzfs/Makefile.am =================================================================== --- zfs-linux-0.6.5.3.orig/lib/libzfs/Makefile.am 2015-10-27 14:34:47.344602154 -0600 +++ zfs-linux-0.6.5.3/lib/libzfs/Makefile.am 2015-10-27 14:35:15.236602845 -0600 @@ -32,6 +32,7 @@ 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 Index: zfs-linux-0.6.5.3/lib/libzfs_core/Makefile.am =================================================================== --- zfs-linux-0.6.5.3.orig/lib/libzfs_core/Makefile.am 2015-10-27 14:34:47.344602154 -0600 +++ zfs-linux-0.6.5.3/lib/libzfs_core/Makefile.am 2015-10-27 14:35:15.236602845 -0600 @@ -16,7 +16,8 @@ $(KERNEL_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 debian/patches/0002-Check-for-META-and-DCH-consistency-in-autoconf.patch0000664000000000000000000000501112656130051022453 0ustar Index: zfs-linux-0.6.5.3/config/zfs-meta.m4 =================================================================== --- zfs-linux-0.6.5.3.orig/config/zfs-meta.m4 2015-10-27 14:33:15.636599881 -0600 +++ zfs-linux-0.6.5.3/config/zfs-meta.m4 2015-10-27 14:33:37.996600435 -0600 @@ -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 @@ _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_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') debian/patches/series0000664000000000000000000000050312677047044012045 0ustar # 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 1000-ppc64el-endian-support.patch 1001-Fix-aarch64-compilation.patch 1002-Add-support-32-bit-FS_IOC32_-GET-SET-FLAGS-compat-io.patch enable-zed.patch debian/patches/enable-zed.patch0000664000000000000000000000174412663232247013663 0ustar Description: Enable zed emails The OpenZFS event daemon monitors pools. This patch enables the email sending function by default (if zed is installed). This is consistent with the default behavior of mdadm. Author: Richard Laager Forwarded: no Index: zfs-linux-0.6.5.3/cmd/zed/zed.d/zed.rc =================================================================== --- zfs-linux-0.6.5.3.orig/cmd/zed/zed.d/zed.rc 2015-10-27 15:22:37.000000000 -0500 +++ zfs-linux-0.6.5.3/cmd/zed/zed.d/zed.rc 2016-01-31 23:13:49.826489152 -0600 @@ -15,7 +15,7 @@ # Email will only be sent if ZED_EMAIL_ADDR is defined. # Disabled by default; uncomment to enable. # -#ZED_EMAIL_ADDR="root" +ZED_EMAIL_ADDR="root" ## # Name or path of executable responsible for sending notifications via email; @@ -41,7 +41,7 @@ ## # Minimum number of seconds between notifications for a similar event. # -#ZED_NOTIFY_INTERVAL_SECS=3600 +ZED_NOTIFY_INTERVAL_SECS=3600 ## # Notification verbosity. debian/patches/1002-Add-support-32-bit-FS_IOC32_-GET-SET-FLAGS-compat-io.patch0000664000000000000000000000260612677047011022523 0ustar From cff6678a6612e2ed7b144953782b88d8714725a4 Mon Sep 17 00:00:00 2001 From: Colin Ian King Date: Wed, 30 Mar 2016 23:00:23 +0100 Subject: [PATCH] Add support 32 bit FS_IOC32_{GET|SET}FLAGS compat ioctls We need 32 bit userspace FS_IOC32_GETFLAGS and FS_IOC32_SETFLAGS compat ioctls for systems such as powerpc64. We use the normal compat ioctl idiom as used by a variety of file systems to provide this support. Signed-off-by: Colin Ian King --- module/zfs/zpl_file.c | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/module/zfs/zpl_file.c b/module/zfs/zpl_file.c index a23bc7d..5c430c7 100644 --- a/module/zfs/zpl_file.c +++ b/module/zfs/zpl_file.c @@ -24,6 +24,9 @@ */ +#ifdef CONFIG_COMPAT +#include +#endif #include #include #include @@ -798,7 +801,17 @@ zpl_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) static long zpl_compat_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) { - return (zpl_ioctl(filp, cmd, arg)); + switch (cmd) { + case FS_IOC32_GETFLAGS: + cmd = FS_IOC_GETFLAGS; + break; + case FS_IOC32_SETFLAGS: + cmd = FS_IOC_SETFLAGS; + break; + default: + return (-ENOTTY); + } + return (zpl_ioctl(filp, cmd, (unsigned long)compat_ptr(arg))); } #endif /* CONFIG_COMPAT */ -- 2.7.4 debian/patches/1000-ppc64el-endian-support.patch0000664000000000000000000000101512673765215016454 0ustar Index: zfs-linux-0.6.5.3/lib/libspl/include/sys/isa_defs.h =================================================================== --- zfs-linux-0.6.5.3.orig/lib/libspl/include/sys/isa_defs.h 2015-10-27 14:36:37.904604893 -0600 +++ zfs-linux-0.6.5.3/lib/libspl/include/sys/isa_defs.h 2015-10-27 14:36:58.008605392 -0600 @@ -98,8 +98,8 @@ #endif #endif -#if !defined(_BIG_ENDIAN) -#define _BIG_ENDIAN +#if !defined(_BIG_ENDIAN) && !defined(_LITTLE_ENDIAN) +#error powerpc no endian specified #endif #define _SUNOS_VTOC_16 debian/libzpool2linux.install0000664000000000000000000000003212703172742013554 0ustar lib/libzpool.so.* usr/lib debian/zfs-zed.postinst0000664000000000000000000000067612663232247012377 0ustar #!/bin/sh set -e installed_dir=/usr/lib/zfs-linux/zfs/zed.d enabled_dir=/etc/zfs/zed.d # On a fresh install, enable most scriptlets. if [ -z "$2" ] then for scriptlet in "$installed_dir"/* do name=$(basename "$scriptlet") case "$name" in all-debug.sh) continue ;; generic-notify.sh) continue ;; esac if ! [ -e "$enabled_dir/$name" ] then ln -s "$scriptlet" "$enabled_dir/" fi done fi #DEBHELPER# debian/control0000664000000000000000000001504112677552107010610 0ustar Source: zfs-linux Section: kernel Priority: extra Maintainer: Ubuntu Developers XSBC-Original-Maintainer: Darik Horn Build-Depends: autotools-dev, autoconf, autogen, automake, debhelper (>= 7), dh-autoreconf, dh-systemd, dkms (>= 2.2.0.2), libselinux1-dev, libtool, uuid-dev, zlib1g-dev, libblkid-dev, libattr1-dev Standards-Version: 3.9.6 Homepage: https://github.com/zfsonlinux/zfs/releases/tag/zfs-0.6.5.6 Package: libnvpair1linux Section: libs Architecture: 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: libnvpair1linux-dbg Section: debug Architecture: any Depends: ${misc:Depends}, libnvpair1linux (= ${binary:Version}) Replaces: libnvpair0-dbg Description: Debugging symbols for libnvpair1linux 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 libnvpair1linux. Package: libuutil1linux Section: libs Architecture: 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: libuutil1linux-dbg Section: debug Architecture: any Depends: ${misc:Depends}, libuutil1linux (= ${binary:Version}) Replaces: libuutil0-dbg Description: Debugging symbols for libuutil1linux 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 libuutil1linux. Package: libzfslinux-dev Section: libdevel Architecture: any Depends: ${misc:Depends}, libnvpair1linux (= ${binary:Version}), libuutil1linux (= ${binary:Version}), libzfs2linux (= ${binary:Version}), libzpool2linux (= ${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: libzfs2linux Section: libs Architecture: any Depends: ${misc:Depends}, ${shlibs:Depends} Replaces: libzfs0, libzfs1 Description: Native OpenZFS filesystem library for Linux The ZFS on Linux management library. Package: libzfs2linux-dbg Section: debug Architecture: any Depends: ${misc:Depends}, libzfs2linux (= ${binary:Version}) Replaces: libzfs0-dbg, libzfs1-dbg Description: Debugging symbols for libzfs2 The ZFS on Linux management library. . This package contains the debugging symbols for libzfs2. Package: libzpool2linux Section: libs Architecture: any Depends: ${misc:Depends}, ${shlibs:Depends} Replaces: libzpool0, libzpool1 Description: Native OpenZFS pool library for Linux The zpool management library. Package: libzpool2linux-dbg Section: debug Architecture: any Depends: ${misc:Depends}, libzpool2linux (= ${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: 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: all 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: all Depends: ${misc:Depends}, zfsutils-linux 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: zfs-zed Section: admin Architecture: any Depends: ${misc:Depends}, ${shlibs:Depends}, zfsutils-linux Suggests: default-mta | mail-transport-agent Replaces: zfsutils-linux Description: OpenZFS Event Daemon (zed) A monitor that automatically runs scripts for OpenZFS kernel events, like disk failures. Package: zfs-zed-dbg Section: debug Architecture: any Depends: ${misc:Depends}, zfs-zed (= ${binary:Version}) Description: Debugging symbols for zfs-zed This package contains the debugging symbols for zfs-zed. Package: zfsutils-linux Section: admin Architecture: any Depends: ${misc:Depends}, ${shlibs:Depends} Recommends: zfs-dkms, zfs-zed Suggests: samba-common-bin (>= 3.0.23), nfs-kernel-server, zfs-initramfs Conflicts: zfs, zfs-fuse Provides: zfs 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-linux-dbg Section: debug Architecture: any Depends: ${misc:Depends}, zfsutils-linux (= ${binary:Version}) Replaces: zfs-dbg Description: Debugging symbols for zfsutils-linux This package provides the zpool and zfs commands that are used to manage OpenZFS filesystems. . This package contains the debugging symbols for zfsutils-linux debian/tests/0000775000000000000000000000000012700674412010335 5ustar debian/tests/kernel-smoke-test-pool-raidz30000775000000000000000000000327612656130051016001 0ustar #!/bin/sh # # Copyright (C) 2016 Canonical # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 2 # of the License, or (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. # echo -n "kernel smoke test, create and destroy pool, raidz3: " TMP=/tmp VDEV0=${TMP}/pool0-$$.img VDEV1=${TMP}/pool1-$$.img VDEV2=${TMP}/pool2-$$.img VDEV3=${TMP}/pool3-$$.img VDEV_SZ=128 POOL=pool-smoke-$$ dd if=/dev/zero of=${VDEV0} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV1} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV2} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV3} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 zpool create ${POOL} raidz3 ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool create failed, exit code=$ret" rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} exit 1 fi zpool destroy ${POOL} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool destroy failed, exit code=$ret" # # destroy failed, try to clean up, but this # wil probably fail # rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} exit 1 fi rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} echo "PASSED" exit 0 debian/tests/kernel-smoke-test-send-receive0000775000000000000000000000473512656130051016210 0ustar #!/bin/sh # # Copyright (C) 2016 Canonical # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 2 # of the License, or (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. # echo -n "kernel smoke test, ZFS send and receive: " TMP=/tmp VDEV0=${TMP}/pool0-$$.img VDEV1=${TMP}/pool1-$$.img POOL=pool-smoke-$$ SNAP=${TMP}/snapshot-$$.zfs DATA=/${POOL}/test/data dd if=/dev/zero of=${VDEV0} bs=1M count=512 > /dev/null 2>&1 dd if=/dev/zero of=${VDEV1} bs=1M count=512 > /dev/null 2>&1 zpool create ${POOL} ${VDEV0} ${VDEV1} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool create failed, exit code=$ret" rm ${VDEV0} ${VDEV1} exit 1 fi zfs create ${POOL}/test ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zfs create failed, exit code=$ret" zpool destroy ${POOL} rm ${VDEV0} ${VDEV1} exit 1 fi # # Populate with files.. # cp -rp /etc /${POOL}/test dd if=/dev/urandom of=${DATA} bs=1M count=64 > /dev/null 2>&1 sum1=$(md5sum ${DATA} | awk '{print $1}') # # Make a snapshot # zfs snapshot -r ${POOL}/test@snap ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zfs snapshot failed, exit code=$ret" zpool destroy ${POOL} rm ${VDEV0} ${VDEV1} exit 1 fi # # Make snapshot # zfs send ${POOL}/test@snap > ${SNAP} rm -rf ${POOL}/test zfs destroy ${POOL}/test@snap ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zfs destroy snapshot failed, exit code=$ret" zpool destroy ${POOL} rm ${VDEV0} ${VDEV1} exit 1 fi # # Receive it back.. # zfs receive -F ${POOL}/test < ${SNAP} sum2=$(md5sum ${DATA} | awk '{print $1}') if [ x"$sum1" != x"$sum2" ]; then echo "FAILED: received data different from original" zpool destroy ${POOL} rm ${VDEV0} ${VDEV1} exit 1 fi zpool destroy ${POOL} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool destroy failed, exit code=$ret" # # destroy failed, try to clean up, but this # wil probably fail # rm ${VDEV0} ${VDEV1} exit 1 fi rm ${VDEV0} ${VDEV1} echo "PASSED" exit 0 debian/tests/kernel-smoke-test-pool-raidz10000775000000000000000000000327512656130051015776 0ustar #!/bin/sh # # Copyright (C) 2016 Canonical # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 2 # of the License, or (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. # echo -n "kernel smoke test, create and destroy pool, raidz1: " TMP=/tmp VDEV0=${TMP}/pool0-$$.img VDEV1=${TMP}/pool1-$$.img VDEV2=${TMP}/pool2-$$.img VDEV3=${TMP}/pool3-$$.img VDEV_SZ=128 POOL=pool-smoke-$$ dd if=/dev/zero of=${VDEV0} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV1} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV2} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV3} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 zpool create ${POOL} raidz ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool create failed, exit code=$ret" rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} exit 1 fi zpool destroy ${POOL} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool destroy failed, exit code=$ret" # # destroy failed, try to clean up, but this # wil probably fail # rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} exit 1 fi rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} echo "PASSED" exit 0 debian/tests/kernel-smoke-test-pool-2x2-mirror0000775000000000000000000000331112656130051016516 0ustar #!/bin/sh # # Copyright (C) 2016 Canonical # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 2 # of the License, or (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. # echo -n "kernel smoke test, create and destroy pool, 2x2 mirror: " TMP=/tmp VDEV0=${TMP}/pool0-$$.img VDEV1=${TMP}/pool1-$$.img VDEV2=${TMP}/pool2-$$.img VDEV3=${TMP}/pool3-$$.img VDEV_SZ=128 POOL=pool-smoke-$$ dd if=/dev/zero of=${VDEV0} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV1} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV2} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV3} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 zpool create ${POOL} mirror ${VDEV0} ${VDEV1} mirror ${VDEV2} ${VDEV3} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool create failed, exit code=$ret" rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} exit 1 fi zpool destroy ${POOL} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool destroy failed, exit code=$ret" # # destroy failed, try to clean up, but this # wil probably fail # rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} exit 1 fi rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} echo "PASSED" exit 0 debian/tests/control0000664000000000000000000000007512656130051011736 0ustar Tests: kernel-smoke-test Restrictions: needs-root Depends: @ debian/tests/kernel-smoke-test-pool-nested-raidz30000775000000000000000000000432312656130051017253 0ustar #!/bin/sh # # Copyright (C) 2016 Canonical # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 2 # of the License, or (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. # echo -n "kernel smoke test, create and destroy pool, nested raidz3: " TMP=/tmp VDEV0=${TMP}/pool0-$$.img VDEV1=${TMP}/pool1-$$.img VDEV2=${TMP}/pool2-$$.img VDEV3=${TMP}/pool3-$$.img VDEV4=${TMP}/pool4-$$.img VDEV5=${TMP}/pool5-$$.img VDEV6=${TMP}/pool6-$$.img VDEV7=${TMP}/pool7-$$.img VDEV_SZ=64 POOL=pool-smoke-$$ dd if=/dev/zero of=${VDEV0} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV1} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV2} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV3} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV4} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV5} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV6} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV7} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 zpool create ${POOL} raidz3 ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} raidz3 ${VDEV4} ${VDEV5} ${VDEV6} ${VDEV7} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool create failed, exit code=$ret" rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} ${VDEV4} ${VDEV5} ${VDEV6} ${VDEV7} exit 1 fi zpool destroy ${POOL} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool destroy failed, exit code=$ret" # # destroy failed, try to clean up, but this # wil probably fail # rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} ${VDEV4} ${VDEV5} ${VDEV6} ${VDEV7} exit 1 fi rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} ${VDEV4} ${VDEV5} ${VDEV6} ${VDEV7} echo "PASSED" exit 0 debian/tests/kernel-smoke-test-scrub0000775000000000000000000000560712656130051014754 0ustar #!/bin/sh # # Copyright (C) 2016 Canonical # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 2 # of the License, or (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. # echo -n "kernel smoke test, corrupt data and clean with a scrub: " TMP=/tmp VDEV0=${TMP}/pool0-$$.img VDEV1=${TMP}/pool1-$$.img VDEV2=${TMP}/pool2-$$.img VDEV3=${TMP}/pool3-$$.img VDEV_SZ=128 POOL=pool-smoke-$$ DATA=/${POOL}/random.dat ZFSFS="test tmp example data1 data2 data3" dd if=/dev/zero of=${VDEV0} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV1} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV2} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV3} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 zpool create ${POOL} mirror ${VDEV0} ${VDEV1} mirror ${VDEV2} ${VDEV3} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool create failed, exit code=$ret" rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} exit 1 fi # # Create a file # dd if=/dev/urandom of=$DATA bs=1M count=64 > /dev/null 2>&1 sum1=$(md5sum ${DATA} | awk '{print $1}') # # Corrupt VDEV0 # dd if=/dev/zero of=${VDEV0} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 sync # # Offline "corrupted" VDEV # zpool detach ${POOL} ${VDEV0} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool detach failed, exit code=$ret" zpool destroy ${POOL} rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} exit 1 fi # # Zero corrupted VDEV and re-attach # dd if=/dev/zero of=${VDEV0} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 zpool attach ${POOL} ${VDEV1} ${VDEV0} -f ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool attach failed, exit code=$ret" zpool destroy ${POOL} rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} exit 1 fi zpool scrub ${POOL} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool scrub failed, exit code=$ret" zpool destroy ${POOL} rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} exit 1 fi sum2=$(md5sum ${DATA} | awk '{print $1}') # # Checksums must agree # if [ x"$sum1" != x"$sum2" ]; then echo "FAILED: corrupted data on scrubbed pool" zpool destroy ${POOL} rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} exit 1 fi zpool destroy ${POOL} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool destroy failed, exit code=$ret" # # destroy failed, try to clean up, but this # wil probably fail # rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} exit 1 fi rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} echo "PASSED" exit 0 debian/tests/kernel-smoke-test-pool-raidz20000775000000000000000000000327612656130051016000 0ustar #!/bin/sh # # Copyright (C) 2016 Canonical # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 2 # of the License, or (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. # echo -n "kernel smoke test, create and destroy pool, raidz2: " TMP=/tmp VDEV0=${TMP}/pool0-$$.img VDEV1=${TMP}/pool1-$$.img VDEV2=${TMP}/pool2-$$.img VDEV3=${TMP}/pool3-$$.img VDEV_SZ=128 POOL=pool-smoke-$$ dd if=/dev/zero of=${VDEV0} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV1} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV2} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV3} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 zpool create ${POOL} raidz2 ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool create failed, exit code=$ret" rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} exit 1 fi zpool destroy ${POOL} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool destroy failed, exit code=$ret" # # destroy failed, try to clean up, but this # wil probably fail # rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} exit 1 fi rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} echo "PASSED" exit 0 debian/tests/kernel-smoke-test-filesystem0000775000000000000000000000447512656130051016024 0ustar #!/bin/sh # # Copyright (C) 2016 Canonical # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 2 # of the License, or (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. # echo -n "kernel smoke test, create and destroy ZFS filesystems: " TMP=/tmp VDEV0=${TMP}/pool0-$$.img VDEV1=${TMP}/pool1-$$.img POOL=pool-smoke-$$ ZFSFS="test tmp example data1 data2 data3" dd if=/dev/zero of=${VDEV0} bs=1M count=512 > /dev/null 2>&1 dd if=/dev/zero of=${VDEV1} bs=1M count=512 > /dev/null 2>&1 zpool create ${POOL} ${VDEV0} ${VDEV1} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool create failed, exit code=$ret" rm ${VDEV0} ${VDEV1} exit 1 fi # # And populate with ZFS file systems # for fs in ${ZFSFS} do zfs create ${POOL}/$fs ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zfs create filesystem $fs failed, exit code=$ret" zpool destroy ${POOL} rm ${VDEV0} ${VDEV1} exit 1 fi zfs set quota=128M ${POOL}/$fs ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zfs set quota on $fs failed, exit code=$ret" zpool destroy ${POOL} rm ${VDEV0} ${VDEV1} exit 1 fi zfs set compression=on ${POOL}/$fs ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zfs set compression on $fs failed, exit code=$ret" zpool destroy ${POOL} rm ${VDEV0} ${VDEV1} exit 1 fi done # # And destroy ZFS file systems # for fs in ${ZFSFS} do zfs destroy ${POOL}/$fs ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zfs destroy filesystem $fs failed, exit code=$ret" zpool destroy ${POOL} rm ${VDEV0} ${VDEV1} exit 1 fi done zpool destroy ${POOL} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool destroy failed, exit code=$ret" # # destroy failed, try to clean up, but this # wil probably fail # rm ${VDEV0} ${VDEV1} exit 1 fi rm ${VDEV0} ${VDEV1} echo "PASSED" exit 0 debian/tests/kernel-smoke-test-pool-4x1-mirror0000775000000000000000000000330212656130051016517 0ustar #!/bin/sh # # Copyright (C) 2016 Canonical # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 2 # of the License, or (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. # echo -n "kernel smoke test, create and destroy pool, 4x1 mirror: " TMP=/tmp VDEV0=${TMP}/pool0-$$.img VDEV1=${TMP}/pool1-$$.img VDEV2=${TMP}/pool2-$$.img VDEV3=${TMP}/pool3-$$.img VDEV_SZ=128 POOL=pool-smoke-$$ dd if=/dev/zero of=${VDEV0} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV1} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV2} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV3} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 zpool create ${POOL} mirror ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool create failed, exit code=$ret" rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} exit 1 fi zpool destroy ${POOL} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool destroy failed, exit code=$ret" # # destroy failed, try to clean up, but this # wil probably fail # rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} exit 1 fi rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} echo "PASSED" exit 0 debian/tests/kernel-smoke-test-pool-striped0000775000000000000000000000327012656130051016251 0ustar #!/bin/sh # # Copyright (C) 2016 Canonical # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 2 # of the License, or (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. # echo -n "kernel smoke test, create and destroy pool, striped: " TMP=/tmp VDEV0=${TMP}/pool0-$$.img VDEV1=${TMP}/pool1-$$.img VDEV2=${TMP}/pool2-$$.img VDEV3=${TMP}/pool3-$$.img VDEV_SZ=128 POOL=pool-smoke-$$ dd if=/dev/zero of=${VDEV0} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV1} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV2} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 dd if=/dev/zero of=${VDEV3} bs=1M count=${VDEV_SZ} > /dev/null 2>&1 zpool create ${POOL} ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool create failed, exit code=$ret" rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} exit 1 fi zpool destroy ${POOL} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool destroy failed, exit code=$ret" # # destroy failed, try to clean up, but this # wil probably fail # rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} exit 1 fi rm ${VDEV0} ${VDEV1} ${VDEV2} ${VDEV3} echo "PASSED" exit 0 debian/tests/kernel-smoke-test-zil0000775000000000000000000000342512656130051014430 0ustar #!/bin/sh # # Copyright (C) 2016 Canonical # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 2 # of the License, or (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. # echo -n "kernel smoke test, create and destroy ZFS Intent Log: " TMP=/tmp VDEV0=${TMP}/pool0-$$.img VDEV1=${TMP}/pool1-$$.img POOL=pool-smoke-$$ dd if=/dev/zero of=${VDEV0} bs=1M count=512 > /dev/null 2>&1 dd if=/dev/zero of=${VDEV1} bs=1M count=512 > /dev/null 2>&1 zpool create ${POOL} ${VDEV0} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool create failed, exit code=$ret" rm ${VDEV0} ${VDEV1} exit 1 fi # # And add the ZIL # zpool add ${POOL} log ${VDEV1} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: ZIL add failed, exit code=$ret" zpool destroy ${POOL} rm ${VDEV0} ${VDEV1} exit 1 fi sync # # And now remove ZIL # zpool remove ${POOL} ${VDEV1} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: ZIL remove failed, exit code=$ret" zpool destroy ${POOL} rm ${VDEV0} ${VDEV1} exit 1 fi zpool destroy ${POOL} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool destroy failed, exit code=$ret" # # destroy failed, try to clean up, but this # wil probably fail # rm ${VDEV0} ${VDEV1} exit 1 fi rm ${VDEV0} ${VDEV1} echo "PASSED" exit 0 debian/tests/kernel-smoke-test-clone0000775000000000000000000000433212656130051014730 0ustar #!/bin/sh # # Copyright (C) 2016 Canonical # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 2 # of the License, or (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. # echo -n "kernel smoke test, ZFS clone: " TMP=/tmp VDEV0=${TMP}/pool0-$$.img VDEV1=${TMP}/pool1-$$.img POOL=pool-smoke-$$ DATA=/${POOL}/test/data DATA_CLONE=/${POOL}/test-clone/data dd if=/dev/zero of=${VDEV0} bs=1M count=128 > /dev/null 2>&1 dd if=/dev/zero of=${VDEV1} bs=1M count=128 > /dev/null 2>&1 zpool create ${POOL} ${VDEV0} ${VDEV1} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool create failed, exit code=$ret" rm ${VDEV0} ${VDEV1} exit 1 fi zfs create ${POOL}/test ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zfs create failed, exit code=$ret" zpool destroy ${POOL} rm ${VDEV0} ${VDEV1} exit 1 fi # # Populate with files.. # cp -rp /etc /${POOL}/test dd if=/dev/urandom of=${DATA} bs=1M count=64 > /dev/null 2>&1 sum1=$(md5sum ${DATA} | awk '{print $1}') # # Make a snapshot # zfs snapshot -r ${POOL}/test@snap ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zfs snapshot failed, exit code=$ret" zpool destroy ${POOL} rm ${VDEV0} ${VDEV1} exit 1 fi # # Clone # zfs clone ${POOL}/test@snap ${POOL}/test-clone # # Checksums must agree # sum2=$(md5sum ${DATA_CLONE} | awk '{print $1}') if [ x"$sum1" != x"$sum2" ]; then echo "FAILED: cloned data different from original" zpool destroy ${POOL} rm ${VDEV0} ${VDEV1} exit 1 fi zpool destroy ${POOL} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool destroy failed, exit code=$ret" # # destroy failed, try to clean up, but this # wil probably fail # rm ${VDEV0} ${VDEV1} exit 1 fi rm ${VDEV0} ${VDEV1} echo "PASSED" exit 0 debian/tests/kernel-smoke-test0000775000000000000000000000345512700674412013643 0ustar #!/bin/sh # # Copyright (C) 2016 Canonical # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 2 # of the License, or (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. # # # We run all the tests in this specific order from this # main script so that we don't have to go through the # pain of checking and rebuilding installing and removing # the modules for each test. A good smoke test will # exercise all the base functionality with the same # instance of the ZFS spl and zfs drivers to see what # the cumulative testing of each scenario does to the # environment. # TESTS="kernel-smoke-test-pool-2x2-mirror kernel-smoke-test-pool-4x1-mirror kernel-smoke-test-pool-nested-raidz3 kernel-smoke-test-pool-raidz1 kernel-smoke-test-pool-raidz2 kernel-smoke-test-pool-raidz3 kernel-smoke-test-pool-striped kernel-smoke-test-zil kernel-smoke-test-filesystem kernel-smoke-test-snapshot kernel-smoke-test-clone kernel-smoke-test-send-receive kernel-smoke-test-scrub" rc=0 # # We only test on 64 bit arches for the moment # as these are the ones that ZFS supports. # if [ `getconf LONG_BIT` = "32" ] then echo "Testing on 32 bit architectures not possible." exit 0 fi for t in ${TESTS} do ./debian/tests/$t if [ $? -ne 0 ]; then rc=1 fi done exit $rc debian/tests/kernel-smoke-test-snapshot0000775000000000000000000000515212656130051015470 0ustar #!/bin/sh # # Copyright (C) 2016 Canonical # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 2 # of the License, or (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. # echo -n "kernel smoke test, ZFS snapshot: " TMP=/tmp VDEV0=${TMP}/pool0-$$.img VDEV1=${TMP}/pool1-$$.img POOL=pool-smoke-$$ MARKER=/${POOL}/test/marker dd if=/dev/zero of=${VDEV0} bs=1M count=512 > /dev/null 2>&1 dd if=/dev/zero of=${VDEV1} bs=1M count=512 > /dev/null 2>&1 zpool create ${POOL} ${VDEV0} ${VDEV1} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool create failed, exit code=$ret" rm ${VDEV0} ${VDEV1} exit 1 fi zfs create ${POOL}/test ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zfs create failed, exit code=$ret" zpool destroy ${POOL} rm ${VDEV0} ${VDEV1} exit 1 fi # # Populate with files.. # cp -rp /etc /${POOL}/test echo $$ > ${MARKER} # # Make a snapshot # zfs snapshot -r ${POOL}/test@snap ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zfs snapshot failed, exit code=$ret" zpool destroy ${POOL} rm ${VDEV0} ${VDEV1} exit 1 fi # # Remove files # rm -rf /${POOL}/test/etc ${MARKER} # # Roll back # zfs rollback ${POOL}/test@snap ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zfs rollback failed, exit code=$ret" zpool destroy ${POOL} rm ${VDEV0} ${VDEV1} exit 1 fi # # Check rolled back marker contains sane data # if [ ! -e ${MARKER} ]; then echo "FAILED: zfs rollback failed, ${MARKER} not restored" zpool destroy ${POOL} rm ${VDEV0} ${VDEV1} exit 1 fi data=$(cat ${MARKER}) if [ $data -ne $$ ]; then echo "FAILED: zfs rollback failed, ${MARKER} contained unexpected data" zpool destroy ${POOL} rm ${VDEV0} ${VDEV1} exit 1 fi zfs destroy ${POOL}/test@snap ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zfs destroy snapshot failed, exit code=$ret" zpool destroy ${POOL} rm ${VDEV0} ${VDEV1} exit 1 fi zpool destroy ${POOL} ret=$? if [ $ret -ne 0 ]; then echo "FAILED: zpool destroy failed, exit code=$ret" # # destroy failed, try to clean up, but this # wil probably fail # rm ${VDEV0} ${VDEV1} exit 1 fi rm ${VDEV0} ${VDEV1} echo "PASSED" exit 0 debian/zfsutils-linux.install0000664000000000000000000000024512656130051013600 0ustar ../tree/zfsutils-linux/* / contrib/bash_completion.d/zfs /usr/share/bash-completion/completions/ sbin lib/udev usr/share/man debian/zfs.target /lib/systemd/system debian/zfs-dkms.dkms0000664000000000000000000000456412656130051011616 0ustar 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" debian/zfsutils-linux.zfs-import-cache.service0000664000000000000000000000052612656130051016746 0ustar [Unit] Description=Import ZFS pools by cache file DefaultDependencies=no Requires=systemd-udev-settle.service After=systemd-udev-settle.service After=cryptsetup.target ConditionPathExists=/etc/zfs/zpool.cache [Service] Type=oneshot RemainAfterExit=yes ExecStartPre=/sbin/modprobe zfs ExecStart=/sbin/zpool import -c /etc/zfs/zpool.cache -aN debian/gbp.conf0000664000000000000000000000021712656130051010606 0ustar [DEFAULT] debian-branch=master/ubuntu/xenial debian-tag=master/ubuntu/xenial/%(version)s upstream-branch=upstream upstream-tag=zfs-%(version)s debian/source/0000775000000000000000000000000012656130051010467 5ustar debian/source/format0000664000000000000000000000001412656130051011675 0ustar 3.0 (quilt) debian/zfsutils-linux.cron.d0000664000000000000000000000022312673776761013340 0ustar # Scrub the second Sunday of every month. 24 0 8-14 * * root [ $(date +\%w) -eq 0 ] && [ -x /usr/lib/zfs-linux/scrub ] && /usr/lib/zfs-linux/scrub debian/zfs-doc.install0000664000000000000000000000002412703172744012130 0ustar ../tree/zfs-doc/* / debian/zfs-zed.postrm0000664000000000000000000000020112663232247012020 0ustar #!/bin/sh set -e if [ "$1" = "purge" ] then for i in /etc/zfs/zed.d/*.sh do [ -L "$i" ] && rm -f "$i" done fi #DEBHELPER# debian/zfs-initramfs.triggers0000664000000000000000000000003212656130051013526 0ustar activate update-initramfs debian/rules0000775000000000000000000001043312703172626010257 0ustar #!/usr/bin/make -f CHMOD ?= chmod INSTALL ?= install MAKE ?= make META_NAME := $(shell awk '$$1 == "Name:" { print $$2; }' META) META_VERSION := $(shell awk '$$1 == "Version:" { print $$2; }' META) META_DISTDIR := $(CURDIR)/$(META_NAME)-$(META_VERSION)/ %: dh $@ --with autoreconf,dkms override_dh_auto_configure: @# 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' @# Zed has dependencies outside of the system root. $(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 $(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_fixperms: dh_fixperms @# Prevent execute bits from being stripped by the Launchpad pbuilder. $(CHMOD) a+x '$(CURDIR)'/debian/zfsutils-linux/usr/share/initramfs-tools/hooks/* \ '$(CURDIR)'/debian/zfsutils-linux/usr/lib/zfs-linux/scrub if [ -d '$(CURDIR)'/debian/zfs-initramfs/usr/share/initramfs-tools/hooks ]; then \ $(CHMOD) a+x '$(CURDIR)'/debian/zfs-initramfs/usr/share/initramfs-tools/hooks/*; \ fi override_dh_install: @# Exclude the upstream /usr/lib/udev/rules.d files. dh_install -X/rules.d/ $(INSTALL) -d '$(CURDIR)/debian/zfs-initramfs/lib/udev/rules.d' $(INSTALL) -m 644 '$(CURDIR)/debian/tree/zfs-initramfs/lib/udev/rules.d'/* \ '$(CURDIR)/debian/zfs-initramfs/lib/udev/rules.d/' @# Ensure that /etc/zfs is in the zfsutils package @# because git has difficulty tracking empty directories. $(INSTALL) -d '$(CURDIR)/debian/zfsutils-linux/etc/zfs/' $(INSTALL) -d '$(CURDIR)/debian/libzfslinux-dev/usr/lib/zfs-linux/' # No need to ship .la files find . -name lib*.la -delete override_dh_installdocs: dh_installdocs --link-doc=zfs-doc override_dh_installinit: # zfs.target isn't automatically handled by dh_systemd(?) dh_systemd_enable -p zfsutils-linux zfs.target @# Install debian/zfs-zed.zed.upstart as /etc/init/zed.conf @# and debian/zfs-zed.zed.service as /lib/systemd/system/zed.service dh_installinit --name=zed @# Install debian/zfsutils.zfs.default as /etc/default/zfs. dh_installinit --name=zfs @# Install debian/zfsutils.zpool-import.upstart as /etc/init/zpool-import.conf. dh_installinit --name=zpool-import --no-restart-on-upgrade --no-start @# Ubuntu runs nfs-kernel-server at sysv sequence 20 80 and iscsitarget at 20 20. dh_installinit --name=zfs-share --no-restart-on-upgrade --no-start -- defaults 25 15 @# Only for systemd: dh_installinit --name=zfs-import-cache dh_installinit --name=zfs-import-scan dh_installinit --name=zfs-mount dh_systemd_start override_dh_installudev: dh_installudev --name=zvol --priority=60 dh_installudev --name=vdev --priority=69 override_dh_strip: dh_strip -plibnvpair1linux --dbg-package=libnvpair1linux-dbg dh_strip -plibuutil1linux --dbg-package=libuutil1linux-dbg dh_strip -plibzfs2linux --dbg-package=libzfs2linux-dbg dh_strip -plibzpool2linux --dbg-package=libzpool2linux-dbg dh_strip -pzfs-zed --dbg-package=zfs-zed-dbg dh_strip -pzfsutils-linux --dbg-package=zfsutils-linux-dbg debian/compat0000664000000000000000000000000212656130051010365 0ustar 7 debian/zfs-initramfs.install0000664000000000000000000000003212703172746013360 0ustar ../tree/zfs-initramfs/* / debian/zfsutils-linux.zvol.udev0000664000000000000000000000015712656130051014070 0ustar KERNEL=="zd*" SUBSYSTEM=="block" ACTION=="add|change" PROGRAM="/lib/udev/zvol_id $tempnode" SYMLINK+="zvol/%c" debian/zfs-initramfs.postinst0000664000000000000000000000035512656130134013575 0ustar #!/bin/sh set -e if [ "$1" = "configure" ]; then if which udevadm > /dev/null 2>&1; then udevadm control --reload-rules || true udevadm trigger --subsystem-match=block --action=change || true fi fi #DEBHELPER# debian/zfs-zed.zed.service0000664000000000000000000000026712656130051012721 0ustar [Unit] Description=ZFS Event Daemon (zed) Documentation=man:zed(8) After=zfs-import-cache.service After=zfs-import-scan.service [Service] ExecStart=/usr/sbin/zed -F Restart=on-abort debian/copyright0000664000000000000000000013017412656130051011130 0ustar Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Upstream-Name: Native ZFS for Linux Upstream-Contact: Brian Behlendorf 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. License: CDDL-1.0 Files: * Copyright: Lawrence Livermore National Security, LLC. License: CDDL-1.0 Files: cmd/mount_zfs/* Copyright: Oracle Lawrence Livermore National Security, LLC. License: CDDL-1.0 Files: cmd/zdb/* Copyright: Oracle Sun Microssystems, Inc. License: CDDL-1.0 Files: cmd/zdb/zdb_il.c Copyright: Sun Microsystems, Inc. Cyril Plisko License: CDDL-1.0 Files: cmd/zfs/zfs_iter.c Copyright: Oracle Pawel Jakub Dawidek License: CDDL-1.0 Files: cmd/zfs/zfs_iter.h Copyright: Sun Microssystems, Inc. License: CDDL-1.0 Files: cmd/zfs/zfs_main.c Copyright: Oracle Nexenta Systems, Inc. Delphix License: CDDL-1.0 Files: cmd/zfs/zfs_util.? Copyright: Oracle License: CDDL-1.0 Files: cmd/zinject/* Copyright: Oracle License: CDDL-1.0 Files: cmd/zpios/* Copyright: Cluster Filesystems, Inc. Lawrence Livermore National Security, LLC. License: GPL-2+ Files: cmd/zpool/zpool_iter.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: cmd/zpool/zpool_main.c Copyright: Oracle Nexenta Systems, Inc. Delphix Frederik Wessels License: CDDL-1.0 Files: cmd/zpool/zpool_util.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: cmd/zpool/zpool_util.h Copyright: Oracle License: CDDL-1.0 Files: cmd/zpool/zpool_vdev.c Copyright: Oracle License: CDDL-1.0 Files: cmd/zstreamdump/zstreamdump.c Copyright: Sun Microsystems, Inc. Martin Matuska License: CDDL-1.0 Files: cmd/ztest/ztest.c Copyright: Oracle Delphix Nexenta Systems, Inc. License: CDDL-1.0 Files: cmd/zvol_id/* Copyright: Fajar A. Nugraha. License: CDDL-1.0 Files: config/config.guess config/config.sub config/depcomp config/ltmain.sh config/missing Copyright: Free Software Foundation, Inc. License: GPL-2+ Files: debian/* Copyright: Darik Horn License: GPL-2+ Files: debian/tree/zfsutils/etc/bash_completion.d/zfs Copyright: 2013, Aneurin Price License: Expat Files: etc/init.d/zfs.gentoo.in Copyright: Gentoo Foundation License: BSD-2-clause Copyright (c) 2011, Gentoo Foundation All rights reserved. . Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: . Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. . Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. . THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. Files: include/libnvpair.h Copyright: Oracle License: CDDL-1.0 Files: include/libuutil_common.h Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: include/libuutil.h Copyright: Oracle License: CDDL-1.0 Files: include/libuutil_impl.h Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: include/libzfs.h Copyright: Oracle Nexenta Systems, Inc. Delphix License: CDDL-1.0 Files: include/libzfs_impl.h Copyright: Oracle Delphix License: CDDL-1.0 Files: include/sys/arc.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/bplist.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/bpobj.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/dbuf.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/ddt.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/dmu.h Copyright: Oracle Delphix Robert Milkowski License: CDDL-1.0 Files: include/sys/dmu_impl.h Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: include/sys/dmu_objset.h Copyright: Oracle Robert Milkowski License: CDDL-1.0 Files: include/sys/dmu_traverse.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/dmu_tx.h Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: include/sys/dmu_zfetch.h Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: include/sys/dnode.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/dsl_* Copyright: Oracle License: CDDL-1.0 Files: include/sys/dsl_dataset.h Copyright: Oracle Delphix License: CDDL-1.0 Files: include/sys/dsl_deleg.h Copyright: Oracle Delphix License: CDDL-1.0 Files: include/sys/efi_partition.h Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: include/sys/fm/fs/zfs.h Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: include/sys/fm/protocol.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/fm/util.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/fs/zfs.h Copyright: Oracle Delphix Nexenta Systems, Inc. Robert Milkowski License: CDDL-1.0 Files: include/sys/metaslab.h Copyright: Oracle Delphix License: CDDL-1.0 Files: include/sys/metaslab_impl.h Copyright: Sun Microsystems, Inc. Delphix License: CDDL-1.0 Files: include/sys/nvpair.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/nvpair_impl.h Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: include/sys/refcount.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/rrwlock.h Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: include/sys/sa.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/sa_impl.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/spa_boot.h Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: include/sys/space_map.h Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: include/sys/spa.h Copyright: Oracle Delphix Nexenta Systems, Inc. License: CDDL-1.0 Files: include/sys/spa_impl.h Copyright: Oracle Delphix Nexenta Systems, Inc. License: CDDL-1.0 Files: include/sys/txg.h Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: include/sys/txg_impl.h Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: include/sys/u8_textprep_data.h Copyright: Unicode, Inc. Sun Microsystems, Inc. License: Expat~Unicode Permission is hereby granted, free of charge, to any person obtaining a copy of the Unicode data files and any associated documentation (the "Data Files") or Unicode software and any associated documentation (the "Software") to deal in the Data Files or Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, and/or sell copies of the Data Files or Software, and to permit persons to whom the Data Files or Software are furnished to do so, provided that (a) the above copyright notice(s) and this permission notice appear with all copies of the Data Files or Software, (b) both the above copyright notice(s) and this permission notice appear in associated documentation, and (c) there is clear notice in each modified Data File or in the Software as well as in the documentation associated with the Data File(s) or Software that the data or software has been modified. . THE DATA FILES AND SOFTWARE ARE 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 OF THIRD PARTY RIGHTS. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR HOLDERS INCLUDED IN THIS NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL INDIRECT OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THE DATA FILES OR SOFTWARE. . Except as contained in this notice, the name of a copyright holder shall not be used in advertising or otherwise to promote the sale, use or other dealings in these Data Files or Software without prior written authorization of the copyright holder. . Unicode and the Unicode logo are trademarks of Unicode, Inc., and may be registered in some jurisdictions. All other trademarks and registered trademarks mentioned herein are the property of their respective owners. Files: include/sys/u8_textprep.h Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: include/sys/uberblock.h Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: include/sys/uberblock_impl.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/uio_impl.h Copyright: Sun Microsystems, Inc. AT&T The Regents of the University of California License: CDDL-1.0 Files: include/sys/unique.h Copyright: Sun Microsystems, Inc. Hewlett-Packard Company Open Software Foundation, Inc. Digital Equipment Corporation. Microsoft License: CDDL-1.0 Files: include/sys/vdev_file.h Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: include/sys/vdev.h Copyright: Oracle Delphix License: CDDL-1.0 Files: include/sys/vdev_impl.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/xvattr.h Copyright: AT&T Oracle The Regents of the University of California License: CDDL-1.0 Files: include/sys/vdev_impl.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/zap.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/zap_impl.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/zap_leaf.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/zfs_acl.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/zfs_context.h Copyright: Sun Microsystems, Inc. Nexenta Systems, Inc. License: CDDL-1.0 Files: include/sys/zfs_ctldir.h Copyright: Oracle Lawrence Livermore National Security, LLC. License: CDDL-1.0 Files: include/sys/zfs_debug.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/zfs_dir.h Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: include/sys/zfs_fuid.h Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: include/sys/zfs_ioctl.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/zfs_onexit.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/zfs_rlock.h Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: include/sys/zfs_sa.h Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: include/sys/zfs_stat.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/zfs_vfsops.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/zfs_vnops.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/zfs_znode.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/zil.h Copyright: Oracle Robert Milkowski License: CDDL-1.0 Files: include/sys/zil_impl.h Copyright: Oracle Robert Milkowski License: CDDL-1.0 Files: include/sys/zio_checksum.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/zio_compress.h Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: include/sys/zio.h Copyright: Oracle Nexenta Systems, Inc. License: CDDL-1.0 Files: include/sys/zio_impl.h Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: include/sys/zrlock.h Copyright: Oracle License: CDDL-1.0 Files: include/sys/zvol.h Copyright: Oracle License: CDDL-1.0 Files: include/zfs_comutil.h Copyright: Oracle License: CDDL-1.0 Files: include/zfs_deleg.h Copyright: Oracle Nexenta Systems, Inc. License: CDDL-1.0 Files: include/zfs_fletcher.h Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: include/zfs_namecheck.h Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: include/zfs_prop.h Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: include/zpios-ctl.h Copyright: Cluster File Systems, Inc. Lawrence Livermore National Security, LLC. License: GPL-2+ Files: include/zpios-internal.h Copyright: Cluster File Systems, Inc. Lawrence Livermore National Security, LLC. License: GPL-2+ Files: lib/libefi/rdwr_efi.c Copyright: Oracle License: CDDL-1.0 Files: lib/libnvpair/libnvpair.c Copyright: Oracle License: CDDL-1.0 Files: lib/libnvpair/nvpair_alloc_system.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: lib/libshare/libshare.c Copyright: Oracle Gunnar Beutner License: CDDL-1.0 Files: lib/libshare/libshare_impl.h Copyright: Oracle Gunnar Beutner License: CDDL-1.0 Files: lib/libshare/nfs.c Copyright: Oracle Gunnar Beutner Cyril Plisko License: CDDL-1.0 Files: lib/libshare/nfs.h Copyright: Oracle Gunnar Beutner License: CDDL-1.0 Files: lib/libspl/asm-generic/atomic.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: lib/libspl/asm-i386/atomic.S Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: lib/libspl/asm-x86_64/atomic.S Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: lib/libspl/getexecname.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: lib/libspl/gethrestime.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: lib/libspl/getmntany.c Copyright: Sun Microsystems, Inc. Ricardo Correia AT&T License: CDDL-1.0 Files: lib/libspl/include/* Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: lib/libspl/include/sys/dktp/fdisk.h Copyright: Sun Microsystems, Inc. AT&T License: CDDL-1.0 Files: lib/libspl/include/sys/mntent.h Copyright: Sun Microsystems, Inc. AT&T License: CDDL-1.0 Files: lib/libspl/include/sys/mnttab.h Copyright: Sun Microsystems, Inc. Ricardo Correia AT&T License: CDDL-1.0 Files: lib/libspl/include/sys/stat.h Copyright: Oracle License: CDDL-1.0 Files: lib/libspl/include/sys/sysevent/eventdefs.h Copyright: Sun Microsystems, Inc. Nexenta Systems, Inc. License: CDDL-1.0 Files: lib/libspl/include/sys/uio.h Copyright: Sun Microsystems, Inc. AT&T The Regents of the University of California License: CDDL-1.0 Files: lib/libspl/include/sys/vtoc.h Copyright: Sun Microsystems, Inc. AT&T License: CDDL-1.0 Files: lib/libspl/list.c Copyright: 2008 Sun Microsystems, Inc. All rights reserved. License: CDDL-1.0 Files: lib/libspl/mkdirp.c Copyright: Sun Microsystems, Inc. AT&T License: CDDL-1.0 Files: lib/libspl/strlcat.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: lib/libspl/strlcpy.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: lib/libspl/strnlen.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: lib/libspl/timestamp.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: lib/libspl/xdr.c Copyright: Sun Microsystems, Inc. AT&T License: CDDL-1.0 Files: lib/libspl/zone.c Copyright: 2006 Ricardo Correia License: CDDL-1.0 Files: lib/libuutil/uu_alloc.c Copyright: Oracle License: CDDL-1.0 Files: lib/libuutil/uu_avl.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: lib/libuutil/uu_dprintf.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: lib/libuutil/uu_ident.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: lib/libuutil/uu_list.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: lib/libuutil/uu_misc.c Copyright: Oracle License: CDDL-1.0 Files: lib/libuutil/uu_open.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: lib/libuutil/uu_pname.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: lib/libuutil/uu_string.c Copyright: Oracle License: CDDL-1.0 Files: lib/libuutil/uu_strtoint.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: lib/libzfs/libzfs_changelist.c Copyright: Sun Microsystems, Inc. Ramprakash Jelari License: CDDL-1.0 Files: lib/libzfs/libzfs_config.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: lib/libzfs/libzfs_dataset.c Copyright: Oracle Nexenta Systems, Inc. Delphix DEY Storage Systems, Inc. Pawel Jakub Dawidek License: CDDL-1.0 Files: lib/libzfs/libzfs_diff.c Copyright: Oracle License: CDDL-1.0 Files: lib/libzfs/libzfs_fru.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: lib/libzfs/libzfs_graph.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: lib/libzfs/libzfs_import.c Copyright: Oracle Nexenta Systems, Inc. Delphix License: CDDL-1.0 Files: lib/libzfs/libzfs_iter.c Copyright: Oracle Nexenta Systems, Inc. Delphix License: CDDL-1.0 Files: lib/libzfs/libzfs_mount.c Copyright: Oracle License: CDDL-1.0 Files: lib/libzfs/libzfs_pool.c Copyright: Oracle Nexenta Systems, Inc. Delphix License: CDDL-1.0 Files: lib/libzfs/libzfs_sendrecv.c Copyright: Oracle Delphix Pawel Jakub Dawidek License: CDDL-1.0 Files: lib/libzfs/libzfs_status.c Copyright: Oracle License: CDDL-1.0 Files: lib/libzfs/libzfs_util.c Copyright: Oracle Delphix License: CDDL-1.0 Files: lib/libzpool/kernel.c Copyright: Oracle License: CDDL-1.0 Files: lib/libzpool/taskq.c Copyright: Sun Microsystems, Inc. Nexenta Systems, Inc. License: CDDL-1.0 Files: lib/libzpool/util.c Copyright: Oracle License: CDDL-1.0 Files: man/man8/zdb.8 Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: man/man8/zfs.8 Copyright: Sun Microsystems, Inc. Delphix Nexenta Systems, Inc. Joshua M. Clulow License: CDDL-1.0 Files: man/man8/zpool.8 Copyright: Sun Microsystems, Inc. Nexenta Systems, Inc. License: CDDL-1.0 Files: man/man8/zstreamdump.8 Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: module/avl/avl.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: module/nvpair/nvpair_alloc_fixed.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: module/nvpair/nvpair_alloc_spl.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: module/nvpair/nvpair.c Copyright: Oracle License: CDDL-1.0 Files: module/unicode/u8_textprep.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: module/unicode/uconv.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: module/zcommon/zfs_comutil.c Copyright: Oracle License: CDDL-1.0 Files: module/zcommon/zfs_deleg.c Copyright: Oracle Nexenta Systems, Inc. License: CDDL-1.0 Files: module/zcommon/zfs_fletcher.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: module/zcommon/zfs_namecheck.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: module/zcommon/zfs_prop.c Copyright: Oracle Delphix Robert Milkowski License: CDDL-1.0 Files: module/zcommon/zfs_uio.c Copyright: Sun Microsystems, Inc. AT&T The Regents of the University of California License: CDDL-1.0 Files: module/zcommon/zpool_prop.c Copyright: Oracle Nexenta Systems, Inc. Delphix License: CDDL-1.0 Files: module/zcommon/zprop_common.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: module/zfs/arc.c Copyright: Oracle Nexenta Systems, Inc. Delphix License: CDDL-1.0 Files: module/zfs/bplist.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/bpobj.c Copyright: Oracle Delphix License: CDDL-1.0 Files: module/zfs/dbuf.c Copyright: Oracle Nexenta Systems, Inc. License: CDDL-1.0 Files: module/zfs/ddt.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/ddt_zap.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/dmu.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/dmu_diff.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/dmu_object.c Copyright: Oracle Robert Milkowski License: CDDL-1.0 Files: module/zfs/dmu_send.c Copyright: Oracle Nexenta Systems, Inc. Delphix License: CDDL-1.0 Files: module/zfs/dmu_traverse.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/dmu_tx.c Copyright: Oracle Nexenta Systems, Inc. License: CDDL-1.0 Files: module/zfs/dmu_zfetch.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: module/zfs/dnode.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/dnode_sync.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/dsl_dataset.c Copyright: Oracle Delphix License: CDDL-1.0 Files: module/zfs/dsl_deadlist.c Copyright: Oracle Delphix License: CDDL-1.0 Files: module/zfs/dsl_deleg.c Copyright: Oracle Delphix License: CDDL-1.0 Files: module/zfs/dsl_dir.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/dsl_pool.c Copyright: Oracle Delphix License: CDDL-1.0 Files: module/zfs/dsl_prop.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/dsl_scan.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/dsl_synctask.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/fm.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/gzip.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: module/zfs/lzjb.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/metaslab.c Copyright: Oracle Delphix License: CDDL-1.0 Files: module/zfs/refcount.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/rrwlock.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: module/zfs/sa.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/sha256.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: module/zfs/spa_boot.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: module/zfs/spa.c Copyright: Oracle Nexenta Systems, Inc. Delphix License: CDDL-1.0 Files: module/zfs/space_map.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: module/zfs/spa_config.c Copyright: Oracle Nexenta Systems, Inc. Delphix License: CDDL-1.0 Files: module/zfs/spa_errlog.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/spa_history.c Copyright: Oracle Delphix License: CDDL-1.0 Files: module/zfs/spa_misc.c Copyright: Oracle Delphix Nexenta Systems, Inc. License: CDDL-1.0 Files: module/zfs/txg.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/uberblock.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/unique.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: module/zfs/vdev_cache.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: module/zfs/vdev.c Copyright: Oracle Nexenta Systems, Inc. Delphix License: CDDL-1.0 Files: module/zfs/vdev_file.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/vdev_label.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/vdev_mirror.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: module/zfs/vdev_missing.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: module/zfs/vdev_queue.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: module/zfs/vdev_raidz.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/vdev_root.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: module/zfs/zap.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/zap_leaf.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/zap_micro.c Copyright: Oracle Delphix License: CDDL-1.0 Files: module/zfs/zfs_acl.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/zfs_byteswap.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: module/zfs/zfs_ctldir.c Copyright: Oracle Lawrence Livermore National Security, LLC. License: CDDL-1.0 Files: module/zfs/zfs_debug.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/zfs_dir.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/zfs_fm.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: module/zfs/zfs_fuid.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/zfs_ioctl.c Copyright: Oracle Martin Matuska Pawel Jakub Dawidek Joyent, Inc. Nexenta Systems, Inc. Delphix License: CDDL-1.0 Files: module/zfs/zfs_log.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/zfs_onexit.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/zfs_replay.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/zfs_rlock.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: module/zfs/zfs_sa.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/zfs_vfsops.c Copyright: Oracle Robert Milkowski License: CDDL-1.0 Files: module/zfs/zfs_vnops.c Copyright: Oracle Jeremy Teo Robert Milkowski License: CDDL-1.0 Files: module/zfs/zfs_znode.c Copyright: Oracle Jeremy Teo License: CDDL-1.0 Files: module/zfs/zil.c Copyright: Oracle Delphix Robert Milkowski License: CDDL-1.0 Files: module/zfs/zio.c Copyright: Oracle Delphix Nexenta Systems, Inc. License: CDDL-1.0 Files: module/zfs/zio_checksum.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/zio_compress.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: module/zfs/zio_inject.c Copyright: Oracle License: CDDL-1.0 Files: module/zfs/zle.c Copyright: Sun Microsystems, Inc. License: CDDL-1.0 Files: module/zfs/zpl_export.c Copyright: Gunnar Beutner License: CDDL-1.0 Files: module/zfs/zrlock.c Copyright: Oracle License: CDDL-1.0 Files: module/zpios/pios.c Copyright: Cluster File Systems, Inc. Lawrence Livermore National Security, LLC. License: GPL-2+ Files: scripts/kmodtool Copyright: 2003-2012, Ville Skyttä , 2003-2012, Thorsten Leemhuis 2003-2012, Nicolas Chauvet License: Expat License: Expat 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. License: GPL-2+ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. . This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. . You should have received a copy of the GNU General Public License along with this package; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA . On Debian systems, the full text of the GNU General Public License version 2 can be found in the file /usr/share/common-licenses/GPL-2. License: CDDL-1.0 COMMON DEVELOPMENT AND DISTRIBUTION LICENSE (CDDL) . Version 1.0 . 1. Definitions. . 1.1. “Contributor” means each individual or entity that creates or contributes to the creation of Modifications. . 1.2. “Contributor Version” means the combination of the Original Software, prior Modifications used by a Contributor (if any), and the Modifications made by that particular Contributor. . 1.3. “Covered Software” means (a) the Original Software, or (b) Modifications, or (c) the combination of files containing Original Software with files containing Modifications, in each case including portions thereof. . 1.4. “Executable” means the Covered Software in any form other than Source Code. . 1.5. “Initial Developer” means the individual or entity that first makes Original Software available under this License. . 1.6. “Larger Work” means a work which combines Covered Software or portions thereof with code not governed by the terms of this License. . 1.7. “License” means this document. . 1.8. “Licensable” means having the right to grant, to the maximum extent possible, whether at the time of the initial grant or subsequently acquired, any and all of the rights conveyed herein. . 1.9. “Modifications” means the Source Code and Executable form of any of the following: . A. Any file that results from an addition to, deletion from or modification of the contents of a file containing Original Software or previous Modifications; . B. Any new file that contains any part of the Original Software or previous Modification; or . C. Any new file that is contributed or otherwise made available under the terms of this License. . 1.10. “Original Software” means the Source Code and Executable form of computer software code that is originally released under this License. . 1.11. “Patent Claims” means any patent claim(s), now owned or hereafter acquired, including without limitation, method, process, and apparatus claims, in any patent Licensable by grantor. . 1.12. “Source Code” means (a) the common form of computer software code in which modifications are made and (b) associated documentation included in or with such code. . 1.13. “You” (or “Your”) means an individual or a legal entity exercising rights under, and complying with all of the terms of, this License. For legal entities, “You” includes any entity which controls, is controlled by, or is under common control with You. For purposes of this definition, “control” means (a) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (b) ownership of more than fifty percent (50%) of the outstanding shares or beneficial ownership of such entity. . 2. License Grants. . 2.1. The Initial Developer Grant. . Conditioned upon Your compliance with Section 3.1 below and subject to third party intellectual property claims, the Initial Developer hereby grants You a world-wide, royalty-free, non-exclusive license: . (a) under intellectual property rights (other than patent or trademark) Licensable by Initial Developer, to use, reproduce, modify, display, perform, sublicense and distribute the Original Software (or portions thereof), with or without Modifications, and/or as part of a Larger Work; and . (b) under Patent Claims infringed by the making, using or selling of Original Software, to make, have made, use, practice, sell, and offer for sale, and/or otherwise dispose of the Original Software (or portions thereof). . (c) The licenses granted in Sections 2.1(a) and (b) are effective on the date Initial Developer first distributes or otherwise makes the Original Software available to a third party under the terms of this License. . (d) Notwithstanding Section 2.1(b) above, no patent license is granted: (1) for code that You delete from the Original Software, or (2) for infringements caused by: (i) the modification of the Original Software, or (ii) the combination of the Original Software with other software or devices. . 2.2. Contributor Grant. . Conditioned upon Your compliance with Section 3.1 below and subject to third party intellectual property claims, each Contributor hereby grants You a world-wide, royalty-free, non-exclusive license: . (a) under intellectual property rights (other than patent or trademark) Licensable by Contributor to use, reproduce, modify, display, perform, sublicense and distribute the Modifications created by such Contributor (or portions thereof), either on an unmodified basis, with other Modifications, as Covered Software and/or as part of a Larger Work; and . (b) under Patent Claims infringed by the making, using, or selling of Modifications made by that Contributor either alone and/or in combination with its Contributor Version (or portions of such combination), to make, use, sell, offer for sale, have made, and/or otherwise dispose of: (1) Modifications made by that Contributor (or portions thereof); and (2) the combination of Modifications made by that Contributor with its Contributor Version (or portions of such combination). . (c) The licenses granted in Sections 2.2(a) and 2.2(b) are effective on the date Contributor first distributes or otherwise makes the Modifications available to a third party. . (d) Notwithstanding Section 2.2(b) above, no patent license is granted: (1) for any code that Contributor has deleted from the Contributor Version; (2) for infringements caused by: (i) third party modifications of Contributor Version, or (ii) the combination of Modifications made by that Contributor with other software (except as part of the Contributor Version) or other devices; or (3) under Patent Claims infringed by Covered Software in the absence of Modifications made by that Contributor. . 3. Distribution Obligations. . 3.1. Availability of Source Code. . Any Covered Software that You distribute or otherwise make available in Executable form must also be made available in Source Code form and that Source Code form must be distributed only under the terms of this License. You must include a copy of this License with every copy of the Source Code form of the Covered Software You distribute or otherwise make available. You must inform recipients of any such Covered Software in Executable form as to how they can obtain such Covered Software in Source Code form in a reasonable manner on or through a medium customarily used for software exchange. . 3.2. Modifications. . The Modifications that You create or to which You contribute are governed by the terms of this License. You represent that You believe Your Modifications are Your original creation(s) and/or You have sufficient rights to grant the rights conveyed by this License. . 3.3. Required Notices. . You must include a notice in each of Your Modifications that identifies You as the Contributor of the Modification. You may not remove or alter any copyright, patent or trademark notices contained within the Covered Software, or any notices of licensing or any descriptive text giving attribution to any Contributor or the Initial Developer. . 3.4. Application of Additional Terms. . You may not offer or impose any terms on any Covered Software in Source Code form that alters or restricts the applicable version of this License or the recipients’ rights hereunder. You may choose to offer, and to charge a fee for, warranty, support, indemnity or liability obligations to one or more recipients of Covered Software. However, you may do so only on Your own behalf, and not on behalf of the Initial Developer or any Contributor. You must make it absolutely clear that any such warranty, support, indemnity or liability obligation is offered by You alone, and You hereby agree to indemnify the Initial Developer and every Contributor for any liability incurred by the Initial Developer or such Contributor as a result of warranty, support, indemnity or liability terms You offer. . 3.5. Distribution of Executable Versions. . You may distribute the Executable form of the Covered Software under the terms of this License or under the terms of a license of Your choice, which may contain terms different from this License, provided that You are in compliance with the terms of this License and that the license for the Executable form does not attempt to limit or alter the recipient’s rights in the Source Code form from the rights set forth in this License. If You distribute the Covered Software in Executable form under a different license, You must make it absolutely clear that any terms which differ from this License are offered by You alone, not by the Initial Developer or Contributor. You hereby agree to indemnify the Initial Developer and every Contributor for any liability incurred by the Initial Developer or such Contributor as a result of any such terms You offer. . 3.6. Larger Works. . You may create a Larger Work by combining Covered Software with other code not governed by the terms of this License and distribute the Larger Work as a single product. In such a case, You must make sure the requirements of this License are fulfilled for the Covered Software. . 4. Versions of the License. . 4.1. New Versions. . Sun Microsystems, Inc. is the initial license steward and may publish revised and/or new versions of this License from time to time. Each version will be given a distinguishing version number. Except as provided in Section 4.3, no one other than the license steward has the right to modify this License. . 4.2. Effect of New Versions. . You may always continue to use, distribute or otherwise make the Covered Software available under the terms of the version of the License under which You originally received the Covered Software. If the Initial Developer includes a notice in the Original Software prohibiting it from being distributed or otherwise made available under any subsequent version of the License, You must distribute and make the Covered Software available under the terms of the version of the License under which You originally received the Covered Software. Otherwise, You may also choose to use, distribute or otherwise make the Covered Software available under the terms of any subsequent version of the License published by the license steward. . 4.3. Modified Versions. . When You are an Initial Developer and You want to create a new license for Your Original Software, You may create and use a modified version of this License if You: (a) rename the license and remove any references to the name of the license steward (except to note that the license differs from this License); and (b) otherwise make it clear that the license contains terms which differ from this License. . 5. DISCLAIMER OF WARRANTY. . COVERED SOFTWARE IS PROVIDED UNDER THIS LICENSE ON AN “AS IS” BASIS, WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, WITHOUT LIMITATION, WARRANTIES THAT THE COVERED SOFTWARE IS FREE OF DEFECTS, MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE OR NON-INFRINGING. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE COVERED SOFTWARE IS WITH YOU. SHOULD ANY COVERED SOFTWARE PROVE DEFECTIVE IN ANY RESPECT, YOU (NOT THE INITIAL DEVELOPER OR ANY OTHER CONTRIBUTOR) ASSUME THE COST OF ANY NECESSARY SERVICING, REPAIR OR CORRECTION. THIS DISCLAIMER OF WARRANTY CONSTITUTES AN ESSENTIAL PART OF THIS LICENSE. NO USE OF ANY COVERED SOFTWARE IS AUTHORIZED HEREUNDER EXCEPT UNDER THIS DISCLAIMER. . 6. TERMINATION. . 6.1. This License and the rights granted hereunder will terminate automatically if You fail to comply with terms herein and fail to cure such breach within 30 days of becoming aware of the breach. Provisions which, by their nature, must remain in effect beyond the termination of this License shall survive. . 6.2. If You assert a patent infringement claim (excluding declaratory judgment actions) against Initial Developer or a Contributor (the Initial Developer or Contributor against whom You assert such claim is referred to as “Participant”) alleging that the Participant Software (meaning the Contributor Version where the Participant is a Contributor or the Original Software where the Participant is the Initial Developer) directly or indirectly infringes any patent, then any and all rights granted directly or indirectly to You by such Participant, the Initial Developer (if the Initial Developer is not the Participant) and all Contributors under Sections 2.1 and/or 2.2 of this License shall, upon 60 days notice from Participant terminate prospectively and automatically at the expiration of such 60 day notice period, unless if within such 60 day period You withdraw Your claim with respect to the Participant Software against such Participant either unilaterally or pursuant to a written agreement with Participant. . 6.3. In the event of termination under Sections 6.1 or 6.2 above, all end user licenses that have been validly granted by You or any distributor hereunder prior to termination (excluding licenses granted to You by any distributor) shall survive termination. . 7. LIMITATION OF LIABILITY. . UNDER NO CIRCUMSTANCES AND UNDER NO LEGAL THEORY, WHETHER TORT (INCLUDING NEGLIGENCE), CONTRACT, OR OTHERWISE, SHALL YOU, THE INITIAL DEVELOPER, ANY OTHER CONTRIBUTOR, OR ANY DISTRIBUTOR OF COVERED SOFTWARE, OR ANY SUPPLIER OF ANY OF SUCH PARTIES, BE LIABLE TO ANY PERSON FOR ANY INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES OF ANY CHARACTER INCLUDING, WITHOUT LIMITATION, DAMAGES FOR LOST PROFITS, LOSS OF GOODWILL, WORK STOPPAGE, COMPUTER FAILURE OR MALFUNCTION, OR ANY AND ALL OTHER COMMERCIAL DAMAGES OR LOSSES, EVEN IF SUCH PARTY SHALL HAVE BEEN INFORMED OF THE POSSIBILITY OF SUCH DAMAGES. THIS LIMITATION OF LIABILITY SHALL NOT APPLY TO LIABILITY FOR DEATH OR PERSONAL INJURY RESULTING FROM SUCH PARTY’S NEGLIGENCE TO THE EXTENT APPLICABLE LAW PROHIBITS SUCH LIMITATION. SOME JURISDICTIONS DO NOT ALLOW THE EXCLUSION OR LIMITATION OF INCIDENTAL OR CONSEQUENTIAL DAMAGES, SO THIS EXCLUSION AND LIMITATION MAY NOT APPLY TO YOU. . 8. U.S. GOVERNMENT END USERS. . The Covered Software is a “commercial item,” as that term is defined in 48 C.F.R. 2.101 (Oct. 1995), consisting of “commercial computer software” (as that term is defined at 48 C.F.R. § 252.227-7014(a)(1)) and “commercial computer software documentation” as such terms are used in 48 C.F.R. 12.212 (Sept. 1995). Consistent with 48 C.F.R. 12.212 and 48 C.F.R. 227.7202-1 through 227.7202-4 (June 1995), all U.S. Government End Users acquire Covered Software with only those rights set forth herein. This U.S. Government Rights clause is in lieu of, and supersedes, any other FAR, DFAR, or other clause or provision that addresses Government rights in computer software under this License. . 9. MISCELLANEOUS. . This License represents the complete agreement concerning subject matter hereof. If any provision of this License is held to be unenforceable, such provision shall be reformed only to the extent necessary to make it enforceable. This License shall be governed by the law of the jurisdiction specified in a notice contained within the Original Software (except to the extent applicable law, if any, provides otherwise), excluding such jurisdiction’s conflict-of-law provisions. Any litigation relating to this License shall be subject to the jurisdiction of the courts located in the jurisdiction and venue specified in a notice contained within the Original Software, with the losing party responsible for costs, including, without limitation, court costs and reasonable attorneys’ fees and expenses. The application of the United Nations Convention on Contracts for the International Sale of Goods is expressly excluded. Any law or regulation which provides that the language of a contract shall be construed against the drafter shall not apply to this License. You agree that You alone are responsible for compliance with the United States export administration regulations (and the export control laws and regulation of any other countries) when You use, distribute or otherwise make available any Covered Software. . 10. RESPONSIBILITY FOR CLAIMS. . As between Initial Developer and the Contributors, each party is responsible for claims and damages arising, directly or indirectly, out of its utilization of rights under this License and You agree to work with Initial Developer and Contributors to distribute such responsibility on an equitable basis. Nothing herein is intended or shall be deemed to constitute any admission of liability. debian/zfsutils-linux.vdev.udev0000664000000000000000000000057512656130051014046 0ustar 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}" debian/libzfslinux-dev.install0000664000000000000000000000007612703172737013721 0ustar lib/*.a usr/lib lib/*.la usr/lib lib/*.so usr/lib usr/include debian/libuutil1linux.install0000664000000000000000000000003212703172721013547 0ustar lib/libuutil.so.* usr/lib debian/zfs-doc.docs0000664000000000000000000000003612656130051011405 0ustar COPYRIGHT OPENSOLARIS.LICENSE debian/zfsutils-linux.zfs-share.init0000664000000000000000000000300312656130051014771 0ustar #!/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 debian/zfs.target0000664000000000000000000000022412656130051011177 0ustar [Unit] Description=ZFS startup target Requires=zfs-mount.service Requires=zfs-share.service Wants=zed.service [Install] WantedBy=multi-user.target debian/tree/0000775000000000000000000000000012656130051010126 5ustar debian/tree/zfsutils-linux/0000775000000000000000000000000012656130051013146 5ustar debian/tree/zfsutils-linux/usr/0000775000000000000000000000000012656130051013757 5ustar debian/tree/zfsutils-linux/usr/share/0000775000000000000000000000000012656130051015061 5ustar debian/tree/zfsutils-linux/usr/share/initramfs-tools/0000775000000000000000000000000012656130051020213 5ustar debian/tree/zfsutils-linux/usr/share/initramfs-tools/hooks/0000775000000000000000000000000012656130051021336 5ustar debian/tree/zfsutils-linux/usr/share/initramfs-tools/hooks/zdev0000664000000000000000000000224012656130051022227 0ustar #!/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 debian/tree/zfsutils-linux/usr/share/bash-completion/0000775000000000000000000000000012656130051020145 5ustar debian/tree/zfsutils-linux/usr/share/bash-completion/completions/0000775000000000000000000000000012656130051022501 5ustar debian/tree/zfsutils-linux/usr/share/bash-completion/completions/zfs0000664000000000000000000002610112656130051023226 0ustar # Copyright (c) 2013, Aneurin Price # 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 debian/tree/zfsutils-linux/usr/lib/0000775000000000000000000000000012673776761014554 5ustar debian/tree/zfsutils-linux/usr/lib/zfs-linux/0000775000000000000000000000000012673776761016513 5ustar debian/tree/zfsutils-linux/usr/lib/zfs-linux/scrub0000664000000000000000000000026712673776761017561 0ustar #!/bin/sh -eu # Scrub all healthy pools. zpool list -H -o health,name 2>&1 | \ awk 'BEGIN {FS="\t"} {if ($1 ~ /^ONLINE/) print $2}' | \ while read pool do zpool scrub "$pool" done debian/tree/zfsutils-linux/usr/lib/os-probes/0000775000000000000000000000000012656130051016436 5ustar debian/tree/zfsutils-linux/usr/lib/os-probes/10zvol-test0000775000000000000000000000033012656130051020470 0ustar #!/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 debian/tree/zfsutils-linux/etc/0000775000000000000000000000000012656130051013721 5ustar debian/tree/zfsutils-linux/etc/sudoers.d/0000775000000000000000000000000012701736312015632 5ustar debian/tree/zfsutils-linux/etc/sudoers.d/zfs0000664000000000000000000000136212701736312016361 0ustar ## 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 # ## allow any user to use basic read-only ZFS commands #ALL ALL = (R_ROOT) NOPASSWD: C_ZFS debian/tree/zfs-initramfs/0000775000000000000000000000000012656130051012722 5ustar debian/tree/zfs-initramfs/usr/0000775000000000000000000000000012656130051013533 5ustar debian/tree/zfs-initramfs/usr/share/0000775000000000000000000000000012656130051014635 5ustar debian/tree/zfs-initramfs/usr/share/initramfs-tools/0000775000000000000000000000000012656130051017767 5ustar debian/tree/zfs-initramfs/usr/share/initramfs-tools/conf-hooks.d/0000775000000000000000000000000012656130051022257 5ustar debian/tree/zfs-initramfs/usr/share/initramfs-tools/conf-hooks.d/zfs0000664000000000000000000000007512656130051023006 0ustar # Force the inclusion of Busybox in the initramfs. BUSYBOX=y debian/tree/zfs-initramfs/usr/share/initramfs-tools/conf.d/0000775000000000000000000000000012656130051021136 5ustar debian/tree/zfs-initramfs/usr/share/initramfs-tools/conf.d/zfs0000664000000000000000000000013012656130051021655 0ustar for x in $(cat /proc/cmdline) do case $x in root=ZFS=*) BOOT=zfs ;; esac done debian/tree/zfs-initramfs/usr/share/initramfs-tools/hooks/0000775000000000000000000000000012656130051021112 5ustar debian/tree/zfs-initramfs/usr/share/initramfs-tools/hooks/zfs0000664000000000000000000000320612656130051021640 0ustar #!/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/" # 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 debian/tree/zfs-initramfs/usr/share/initramfs-tools/scripts/0000775000000000000000000000000012703421606021460 5ustar debian/tree/zfs-initramfs/usr/share/initramfs-tools/scripts/zfs0000664000000000000000000000663012703421315022207 0ustar # ZFS boot stub for initramfs-tools. zfs_test_import() { ZFS_STDERR=$(zpool import -o readonly=on -N "$ZFS_RPOOL" 2>&1) ZFS_ERROR=$? if [ "$ZFS_ERROR" -eq 0 ] then ZFS_HEALTH=$(zpool list -H -o health "$ZFS_RPOOL" 2>/dev/null) fi zpool export "$ZFS_RPOOL" >/dev/null 2>&1 } mountroot() { [ "$quiet" != "y" ] && log_begin_msg "Running /scripts/local-top" run_scripts /scripts/local-top [ "$quiet" != "y" ] && log_end_msg [ "$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 modprobe zfs zfs_autoimport_disable=1 ZFS_BOOTFS=${ROOT#ZFS=} ZFS_RPOOL=$(echo "$ZFS_BOOTFS" | sed -e 's,/.*,,') delay=${ROOTDELAY:-0} if [ "$delay" -gt 0 ] then # Try to import the pool read-only. If it does not import with # the ONLINE status, wait and try again. The pool could be # DEGRADED because a drive is really missing, or it might just # be slow to be detected. zfs_test_import retry_nr=0 while [ "$retry_nr" -lt "$delay" ] && [ "$ZFS_HEALTH" != "ONLINE" ] do [ "$quiet" != "y" ] && log_begin_msg "Retrying ZFS read-only import" /bin/sleep 1 zfs_test_import retry_nr=$(( $retry_nr + 1 )) [ "$quiet" != "y" ] && log_end_msg done unset retry_nr unset ZFS_HEALTH fi unset delay # At this point, the pool either imported cleanly, or we ran out of the # allowed time (rootdelay). Perform the read-write import. ZFS_STDERR=$(zpool import -N "$ZFS_RPOOL" 2>&1) ZFS_ERROR=$? if [ "$ZFS_ERROR" -ne 0 ] then panic "Command: zpool import -N $ZFS_RPOOL Message: $ZFS_STDERR Error: $ZFS_ERROR Manually import the root pool at the command prompt and then exit. Hint: Try: zpool import -f -R / -N $ZFS_RPOOL" fi # Set elevator=noop on the root pool's vdevs' disks. ZFS already # does this for wholedisk vdevs (for all pools), so this is only # important for partitions. zpool status -L "$ZFS_RPOOL" 2>/dev/null | awk '/^\t / && !/(mirror|raidz)/ { dev=$1; sub(/[0-9]+$/, "", dev); print dev }' | while read i do if [ -e "/sys/block/$i/queue/scheduler" ] then echo noop > "/sys/block/$i/queue/scheduler" fi done # 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 panic "Command: mount -t zfs -o zfsutil $ZFS_BOOTFS $rootmnt Message: $ZFS_STDERR Error: $ZFS_ERROR Manually mount the root filesystem on $rootmnt and then exit." fi unset ZFS_BOOTFS unset ZFS_RPOOL unset ZFS_STDERR unset ZFS_ERROR [ "$quiet" != "y" ] && log_begin_msg "Running /scripts/local-bottom" run_scripts /scripts/local-bottom [ "$quiet" != "y" ] && log_end_msg } debian/tree/zfs-initramfs/lib/0000775000000000000000000000000012656130051013470 5ustar debian/tree/zfs-initramfs/lib/udev/0000775000000000000000000000000012656130051014433 5ustar debian/tree/zfs-initramfs/lib/udev/rules.d/0000775000000000000000000000000012673753315016024 5ustar debian/tree/zfs-initramfs/lib/udev/rules.d/60-zpool.rules0000664000000000000000000000125512673753315020471 0ustar # This creates symlinks directly in /dev with the same names as those in # /dev/disk/by-id, but only for ZFS partitions. This is necessary for GRUB to # https://bugs.launchpad.net/ubuntu/+source/grub2/+bug/1527727 # https://bugs.launchpad.net/ubuntu/+source/zfs-initramfs/+bug/1530953 # locate the partitions using the output of `zpool status`. KERNEL=="sd*[0-9]", IMPORT{parent}=="ID_*", ENV{ID_PART_ENTRY_SCHEME}=="gpt", ENV{ID_PART_ENTRY_TYPE}=="6a898cc3-1dd2-11b2-99a6-080020736631", SYMLINK+="$env{ID_BUS}-$env{ID_SERIAL}-part%n" KERNEL=="sd*[0-9]", IMPORT{parent}=="ID_*", ENV{ID_FS_TYPE}=="zfs_member", ENV{ID_FS_USAGE}=="raid", SYMLINK+="$env{ID_BUS}-$env{ID_SERIAL}-part%n" debian/tree/zfs-doc/0000775000000000000000000000000012656130051011473 5ustar debian/tree/zfs-doc/etc/0000775000000000000000000000000012656130051012246 5ustar debian/tree/zfs-doc/etc/dpkg/0000775000000000000000000000000012656130051013173 5ustar debian/tree/zfs-doc/etc/dpkg/dpkg.cfg.d/0000775000000000000000000000000012656130051015100 5ustar debian/tree/zfs-doc/etc/dpkg/dpkg.cfg.d/zfs-doc0000664000000000000000000000030212656130051016363 0ustar ## /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/* debian/zfsutils-linux.zfs-mount.service0000664000000000000000000000054112656130051015532 0ustar [Unit] Description=Mount ZFS filesystems DefaultDependencies=no Wants=zfs-import-cache.service Wants=zfs-import-scan.service Requires=systemd-udev-settle.service After=systemd-udev-settle.service After=zfs-import-cache.service After=zfs-import-scan.service Before=local-fs.target [Service] Type=oneshot RemainAfterExit=yes ExecStart=/sbin/zfs mount -a debian/zfs-doc.examples0000664000000000000000000000366512673774353012330 0ustar 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/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 debian/libzfs2linux.install0000664000000000000000000000006512703172727013224 0ustar lib/libzfs.so.* usr/lib lib/libzfs_core.so.* usr/lib debian/zfs-zed.install0000664000000000000000000000022312663232247012146 0ustar etc/zfs/zed.d/zed.rc etc/zfs/zed.d/zed-functions.sh usr/lib/zfs-linux/zfs/zed.d/ usr/lib/zfs-linux/zfs/zed.d usr/sbin/zed usr/share/man/man8/zed.8 debian/zfs-zed.links0000664000000000000000000000011412663232247011617 0ustar usr/lib/zfs-linux/zfs/zed.d/zed-functions.sh etc/zfs/zed.d/zed-functions.sh debian/zfsutils-linux.zfs-import-scan.service0000664000000000000000000000052712656130051016630 0ustar [Unit] Description=Import ZFS pools by device scanning DefaultDependencies=no Requires=systemd-udev-settle.service After=systemd-udev-settle.service After=cryptsetup.target ConditionPathExists=!/etc/zfs/zpool.cache [Service] Type=oneshot RemainAfterExit=yes ExecStartPre=/sbin/modprobe zfs ExecStart=/sbin/zpool import -d /dev/disk/by-id -aN debian/zfsutils-linux.triggers0000664000000000000000000000003212656130051013752 0ustar activate update-initramfs