]> git.proxmox.com Git - mirror_zfs-debian.git/log
mirror_zfs-debian.git
13 years agoMerge branch 'upstream'
Darik Horn [Wed, 20 Apr 2011 12:48:22 +0000 (07:48 -0500)]
Merge branch 'upstream'

13 years agoAdd parted and lsscsi dependencies to zfs-test
Brian Behlendorf [Tue, 19 Apr 2011 22:01:37 +0000 (15:01 -0700)]
Add parted and lsscsi dependencies to zfs-test

The zfault.sh and zconfig.sh test scripts requires the parted
utility, the lsscsi utility, and the scsi_debug module.  To
ensure the utilities are available they have been added as
dependencies to zfs-test package.  Checking for scsi_debug
is a little more problematic because if it's missing you will
need to build it.  For clarity the documention has been updated
to mention this.

Closes #205
Closes #206

13 years agoAdd Gunnar Beutner to AUTHORS for his contributions
Brian Behlendorf [Tue, 19 Apr 2011 21:12:08 +0000 (14:12 -0700)]
Add Gunnar Beutner to AUTHORS for his contributions

13 years agoTruncate the xattr znode when updating existing attributes.
Gunnar Beutner [Sun, 17 Apr 2011 18:31:33 +0000 (20:31 +0200)]
Truncate the xattr znode when updating existing attributes.

If the attribute's new value was shorter than the old one the old
code would leave parts of the old value in the xattr znode.

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes #203

13 years agoAdded missing initialization for va.va_dentry in zfs_get_xattrdir.
Gunnar Beutner [Sun, 17 Apr 2011 17:42:33 +0000 (19:42 +0200)]
Added missing initialization for va.va_dentry in zfs_get_xattrdir.

Without this we may mistakenly believe we have a dentry and try to
d_instantiate() it.  This will result in the following BUG.  It's
important to note that while the xattr directory has an inode
assoicated with it we never create a dentry for it.

  kernel BUG at fs/dcache.c:1418!

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes #202

13 years agoSupport IEC base-2 prefixes
Richard Laager [Sun, 10 Apr 2011 23:08:53 +0000 (18:08 -0500)]
Support IEC base-2 prefixes

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
13 years agoCleanup various Sun/Solaris-isms
Richard Laager [Sat, 9 Apr 2011 03:54:47 +0000 (22:54 -0500)]
Cleanup various Sun/Solaris-isms

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
13 years agoUpdate the version in the zpool upgrade example
Richard Laager [Sat, 9 Apr 2011 03:51:04 +0000 (22:51 -0500)]
Update the version in the zpool upgrade example

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
13 years agoNormalize the deferred destruction language
Richard Laager [Sat, 9 Apr 2011 03:47:11 +0000 (22:47 -0500)]
Normalize the deferred destruction language

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
13 years agoImprove the wording about hot spares
Richard Laager [Sat, 9 Apr 2011 03:41:40 +0000 (22:41 -0500)]
Improve the wording about hot spares

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
13 years agoImprove some quoting consistency
Richard Laager [Sat, 9 Apr 2011 03:39:36 +0000 (22:39 -0500)]
Improve some quoting consistency

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
13 years agoRemove a stray tab
Richard Laager [Sat, 9 Apr 2011 03:37:37 +0000 (22:37 -0500)]
Remove a stray tab

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
13 years agoLinux has "partitions", not "slices"
Richard Laager [Sat, 9 Apr 2011 03:34:37 +0000 (22:34 -0500)]
Linux has "partitions", not "slices"

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
13 years agoUse Linux disk names in zpool.8
Richard Laager [Sat, 9 Apr 2011 03:27:25 +0000 (22:27 -0500)]
Use Linux disk names in zpool.8

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
13 years agoMore and correct an example in zpool.8
Richard Laager [Sat, 9 Apr 2011 02:54:05 +0000 (21:54 -0500)]
More and correct an example in zpool.8

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
13 years agoChange /dev/dsk -> /dev in the man pages
Richard Laager [Sat, 9 Apr 2011 02:45:13 +0000 (21:45 -0500)]
Change /dev/dsk -> /dev in the man pages

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
13 years agoCorrect man page section numbers for Linux
Richard Laager [Sat, 9 Apr 2011 02:31:11 +0000 (21:31 -0500)]
Correct man page section numbers for Linux

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
13 years agoSet -Wno-unused-but-set-variable globally
Brian Behlendorf [Tue, 19 Apr 2011 17:39:31 +0000 (10:39 -0700)]
Set -Wno-unused-but-set-variable globally

As of gcc-4.6 the option -Wunused-but-set-variable is enabled by
default.  While this is a useful warning there are numerous places
in the ZFS code when a variable is set and then only checked in an
ASSERT().  To avoid having to update every instance of this in the
code we now set -Wno-unused-but-set-variable to suppress the warning.

Additionally, when building with --enable-debug and -Werror set these
warning also become fatal.  We can reevaluate the suppression of these
error at a later time if it becomes an issue.  For now we are basically
just reverting to the previous gcc behavior.

13 years agoFix gcc configure warnings
Brian Behlendorf [Tue, 19 Apr 2011 17:02:21 +0000 (10:02 -0700)]
Fix gcc configure warnings

Newer versions of gcc are getting smart enough to detect the sloppy
syntax used for the autoconf tests.  It is now generating warnings
for unused/undeclared variables.  Newer version of gcc even have
the -Wunused-but-set-variable option set by default.  This isn't a
problem except when -Werror is set and they get promoted to an error.
In this case the autoconf test will return an incorrect result which
will result in a build failure latter on.

To handle this I'm tightening up many of the autoconf tests to
explicitly mark variables as unused to suppress the gcc warning.
Remember, all of the autoconf code can never actually be run we
just want to get a clean build error to detect which APIs are
available.  Never using a variable is absolutely fine for this.

Closes #176

13 years agoFix gcc compiler warning, parse_option()
Brian Behlendorf [Mon, 18 Apr 2011 23:44:22 +0000 (16:44 -0700)]
Fix gcc compiler warning, parse_option()

When compiling ZFS in user space gcc-4.6.0 correctly identifies
the variable 'value' as being set but never used.  This generates a
warning and a build failure when using --enable-debug.  Once again
this is correct but I'm reluctant to remove 'value' because we are
breaking the string in to name/value pairs.  While it is not used
now there's a good chance it will be soon and I'd rather not have
to reinvent this.  To suppress the warning with just as a VERIFY().
This was observed under Fedora 15.

  cmd/mount_zfs/mount_zfs.c: In function ‘parse_option’:
  cmd/mount_zfs/mount_zfs.c:112:21: error: variable ‘value’ set but not
  used [-Werror=unused-but-set-variable]

13 years agoFix gcc compiler warning, dsl_pool_create()
Brian Behlendorf [Mon, 18 Apr 2011 23:27:45 +0000 (16:27 -0700)]
Fix gcc compiler warning, dsl_pool_create()

When compiling ZFS in user space gcc-4.6.0 correctly identifies
the variable 'os' as being set but never used.  This generates a
warning and a build failure when using --enable-debug.  However,
the code is correct we only want to use 'os' for the kernel space
builds.  To suppress the warning the call was wrapped with a
VERIFY() which has the nice side effect of ensuring the 'os'
actually never is NULL.  This was observed under Fedora 15.

  module/zfs/dsl_pool.c: In function ‘dsl_pool_create’:
  module/zfs/dsl_pool.c:229:12: error: variable ‘os’ set but not used
  [-Werror=unused-but-set-variable]

13 years agoLinux 2.6.39 compat, invalidate_inodes()
Brian Behlendorf [Mon, 18 Apr 2011 21:12:28 +0000 (14:12 -0700)]
Linux 2.6.39 compat, invalidate_inodes()

Update code to use the spl_invalidate_inodes() wrapper.  This hides
some of the complexity of determining if invalidate_inodes() was
exported, and if so what is its prototype.  The second argument
of spl_invalidate_inodes() determined the behavior of how dirty
inodes are handled.  By passing a zero we are indicated that we
want those inodes to be treated as busy and skipped.

13 years agoAutogen refresh for kernel-insert-inode-locked.m4
Brian Behlendorf [Mon, 18 Apr 2011 19:48:44 +0000 (12:48 -0700)]
Autogen refresh for kernel-insert-inode-locked.m4

Several Makefile.in's were accidentally not updated when the
kernel-insert-inode-locked.m4 check was added.  This change simply
refreshes the missed files.

13 years agoMerge branch 'kfreebsd'
Darik Horn [Sat, 9 Apr 2011 02:21:03 +0000 (21:21 -0500)]
Merge branch 'kfreebsd'

13 years agoAdd a NEWS entry for the decomposition and rename.
Darik Horn [Fri, 8 Apr 2011 19:21:25 +0000 (14:21 -0500)]
Add a NEWS entry for the decomposition and rename.

13 years agoFix rebuildable RPMs for el6/ch5
Brian Behlendorf [Fri, 8 Apr 2011 17:22:42 +0000 (10:22 -0700)]
Fix rebuildable RPMs for el6/ch5

When rebuilding the source RPM under el5 you need to append the
target_cpu.  However, under el6/ch5 things are packaged correctly
and the arch is already part of kver.  For this reason it also
needs to be stripped from kver when setting kverpkg.

13 years agoAlign closing fi in mount-zfs.sh
Ned Bass [Fri, 8 Apr 2011 16:41:41 +0000 (09:41 -0700)]
Align closing fi in mount-zfs.sh

13 years agoUse consistent indentation in mount-zfs.sh
Ned Bass [Thu, 7 Apr 2011 20:45:57 +0000 (13:45 -0700)]
Use consistent indentation in mount-zfs.sh

13 years agoFix a couple comments
Richard Laager [Thu, 7 Apr 2011 06:47:02 +0000 (23:47 -0700)]
Fix a couple comments

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
13 years agoLinux 2.6.29 compat, credentials
Brian Behlendorf [Thu, 7 Apr 2011 21:23:45 +0000 (14:23 -0700)]
Linux 2.6.29 compat, credentials

The .sync_fs fix as applied did not use the updated SPL credential
API.  This broke builds on Debian Lenny, this change applies the
needed fix to use the portable API.  The original credential changes
are part of commit 81e97e21872a9c38ad66c37fafe1436ee25abee3.

13 years agoAdd a zfs-grub dependency to zfs-initramfs.
Darik Horn [Thu, 7 Apr 2011 18:59:29 +0000 (13:59 -0500)]
Add a zfs-grub dependency to zfs-initramfs.

The grub-common package at ppa:dajhorn/zfs-grub provides a
virtual zfs-grub package.

Updating the initrd on a system with a ZFS root filesystem
requires that the grub-probe utility from the grub2 source
package be compiled against a native libzfs.

The /etc/grub.d runparts must also recognize the ZFS root
filesystem so that appropriate kernel command line
parameters are added to the /boot/grub/grub.cfg file.

13 years agoUse git-dch to update the debian/changelog.
Darik Horn [Thu, 7 Apr 2011 18:52:30 +0000 (13:52 -0500)]
Use git-dch to update the debian/changelog.

13 years agoMerge branch 'upstream' into kfreebsd
Darik Horn [Thu, 7 Apr 2011 18:48:28 +0000 (13:48 -0500)]
Merge branch 'upstream' into kfreebsd

13 years agoPrep zfs-0.6.0-rc3 tag
Brian Behlendorf [Thu, 7 Apr 2011 17:49:55 +0000 (10:49 -0700)]
Prep zfs-0.6.0-rc3 tag

Create the third 0.6.0 release candidate tag (rc3).

13 years agoUpdate zfs.fedora init script
Manuel Amador (Rudd-O) [Thu, 7 Apr 2011 17:34:20 +0000 (10:34 -0700)]
Update zfs.fedora init script

Apply all of Rudd-O's changes for the Fedora init script.  The
initial init script was one I threw together based on Rudd-O's
original work.  It worked for me but it has some flaws.

Rudd-O has invested considerable time updating it to be significantly
smarter.  It now handles using ZFS as your root filesystem plus
various other quirks.  Since he is familiar with the right
way to do things on Fedora and has tested this init script we
are integrating all of his changes.

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
13 years agoUpstream zfs-0.6.0-rc3 tag. Use 0.6.0.7 instead.
Darik Horn [Thu, 7 Apr 2011 17:40:25 +0000 (12:40 -0500)]
Upstream zfs-0.6.0-rc3 tag. Use 0.6.0.7 instead.

13 years agoMerge branch 'upstream' into kfreebsd
Darik Horn [Thu, 7 Apr 2011 17:39:50 +0000 (12:39 -0500)]
Merge branch 'upstream' into kfreebsd

13 years agoPermit both mountpoint=legacy and mountpoint=/ in initrd
Manuel Amador (Rudd-O) [Wed, 6 Apr 2011 16:52:58 +0000 (09:52 -0700)]
Permit both mountpoint=legacy and mountpoint=/ in initrd

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
13 years agoAdded .gitignore for mount.zfs and zvol_id
Manuel Amador (Rudd-O) [Wed, 23 Mar 2011 05:18:07 +0000 (22:18 -0700)]
Added .gitignore for mount.zfs and zvol_id

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
13 years agoFix ASSERTION(!dsl_pool_sync_context(tx->tx_pool))
Brian Behlendorf [Thu, 31 Mar 2011 17:05:58 +0000 (10:05 -0700)]
Fix ASSERTION(!dsl_pool_sync_context(tx->tx_pool))

Disable the normal reclaim path for the txg_sync thread.  This
ensures the thread will never enter dmu_tx_assign() which can
otherwise occur due to direct reclaim.  If this is allowed to
happen the system can deadlock.  Direct reclaim call path:

  ->shrink_icache_memory->prune_icache->dispose_list->
  clear_inode->zpl_clear_inode->zfs_inactive->dmu_tx_assign

13 years agoAdd direct+indirect ARC reclaim
Brian Behlendorf [Wed, 30 Mar 2011 01:08:59 +0000 (18:08 -0700)]
Add direct+indirect ARC reclaim

Under OpenSolaris all memory reclaim is done asyncronously.  Under
Linux memory reclaim is done asynchronously _and_ synchronously.
When a process allocates memory with GFP_KERNEL it explicitly allows
the kernel to do reclaim on its behalf to satify the allocation.
If that GFP_KERNEL allocation fails the kernel may take more drastic
measures to reclaim the memory such as killing user space processes.

This was observed to happen with ZFS because the ARC could consume
a large fraction of the system memory but no synchronous reclaim
could be performed on it.  The result was GFP_KERNEL allocations
could fail resulting in OOM events, and only moments latter the
arc_reclaim thread would free unused memory from the ARC.

This change leaves the arc_thread in place to manage the fundamental
ARC behavior.  But it adds a synchronous (direct) reclaim path for
the ARC which can be called when memory is badly needed.  It also
adds an asynchronous (indirect) reclaim path which is called
much more frequently to prune the ARC slab caches.

13 years agoAdd missing arcstats
Brian Behlendorf [Thu, 24 Mar 2011 19:13:55 +0000 (12:13 -0700)]
Add missing arcstats

The following useful values were missing the arcstats.  This change
adds them in to provide greater visibility in to the arcs behavior.

arc_no_grow                     4    0
arc_tempreserve                 4    0
arc_loaned_bytes                4    0
arc_meta_used                   4    624774592
arc_meta_limit                  4    400785408
arc_meta_max                    4    625594176

13 years agoCall d_instantiate before unlocking inode
Brian Behlendorf [Wed, 30 Mar 2011 06:04:39 +0000 (23:04 -0700)]
Call d_instantiate before unlocking inode

Under Linux a dentry referencing an inode must be instantiated before
the inode is unlocked.  To accomplish this without overly modifing
the core ZFS code the dentry it passed via the vattr_t.  There are
cases such as replay when a dentry is not available.  In which case
it is obviously not initialized at inode creation time, if a dentry
is needed it will be spliced as when required via d_lookup().

13 years agoUse git-dch to update the debian/changelog.
Darik Horn [Thu, 7 Apr 2011 15:53:18 +0000 (10:53 -0500)]
Use git-dch to update the debian/changelog.

13 years agoPartial autogen updates.
Darik Horn [Wed, 6 Apr 2011 14:04:00 +0000 (09:04 -0500)]
Partial autogen updates.

The previous commit failed to compile properly in the PPA build
environment because the configure script was not updated.

13 years agoUse git-dch to update the debian/changelog.
Darik Horn [Wed, 6 Apr 2011 03:11:03 +0000 (22:11 -0500)]
Use git-dch to update the debian/changelog.

13 years agoFull upstream merge. Use zfs-0.6.0.6 as the unofficial upstream version.
Darik Horn [Wed, 6 Apr 2011 03:05:43 +0000 (22:05 -0500)]
Full upstream merge. Use zfs-0.6.0.6 as the unofficial upstream version.

13 years agoRemove volume and swap handling from the init script.
Darik Horn [Wed, 6 Apr 2011 02:41:01 +0000 (21:41 -0500)]
Remove volume and swap handling from the init script.

Managing volumes and swap areas in the init script like
Debian kFreeBSD does is appealing, but providing an
alternative management facility for these things adds
unnecessary complexity.

13 years agoAdd ${shlibs:Depends} to each control stanza.
Darik Horn [Wed, 6 Apr 2011 02:15:17 +0000 (21:15 -0500)]
Add ${shlibs:Depends} to each control stanza.

Satisfy the dpkg-gencontrol warning and specify the external
dependencies for each library package.

13 years agoMove udev rules from /etc to /lib.
Darik Horn [Wed, 6 Apr 2011 01:44:56 +0000 (20:44 -0500)]
Move udev rules from /etc to /lib.

Install 60-zpool.rules and 60-zvol.rules to /lib/udev/rules.d
instead of /etc/udev/rules.d according to packaging convention.

13 years agoDisable dracut instead of reverting it.
Darik Horn [Wed, 6 Apr 2011 01:29:51 +0000 (20:29 -0500)]
Disable dracut instead of reverting it.

13 years agoRename /etc/default/zfsload during upgrades.
Darik Horn [Wed, 6 Apr 2011 01:06:00 +0000 (20:06 -0500)]
Rename /etc/default/zfsload during upgrades.

Preserve the /etc/default/zfsload configuration file by
renaming it to /etc/default/zfs during the replacement
upgrade from the zfs package to the zfsutils package.

13 years agoIgnore `zfs unmount -a` errors in the init script.
Darik Horn [Wed, 6 Apr 2011 00:42:49 +0000 (19:42 -0500)]
Ignore `zfs unmount -a` errors in the init script.

The default dh_installinit prerm script tries to stop the zfs init
script, which causes package upgrade errors on busy systems.

13 years agoRemove `make distclean` kludge.
Darik Horn [Wed, 6 Apr 2011 00:37:00 +0000 (19:37 -0500)]
Remove `make distclean` kludge.

The module/Makefile.in template is updated such that
`make distclean` succeeds after `./configure --with-config=user`.

13 years agoMerge branch 'upstream' into kfreebsd
Darik Horn [Wed, 6 Apr 2011 00:36:11 +0000 (19:36 -0500)]
Merge branch 'upstream' into kfreebsd

13 years agoMerge branch 'upstream'
Darik Horn [Tue, 5 Apr 2011 22:04:09 +0000 (17:04 -0500)]
Merge branch 'upstream'

13 years agoFix `make distclean` for `./configure --with-config=user
Brian Behlendorf [Tue, 5 Apr 2011 20:13:01 +0000 (13:13 -0700)]
Fix `make distclean` for `./configure --with-config=user

    Making distclean in module
    make[1]: Entering directory `/zfs/module'
    make -C  SUBDIRS=`pwd`  clean
    make: Entering an unknown directory
    make: *** SUBDIRS=/zfs/module: No such file or directory.  Stop.

When using --with-config=user the 'distclean' target would fail
because it assumes the kernel configuration infrastrure is set up.
This is not the case, nor does it need to be, because the
'--with-config=user' option will prune the entire ./module subtree
from SUBDIRS.  This prevents most build rules from operating in the
./module directory.

However, the 'dist*' rules will still traverse this directory
because it is listed in DIST_SUBDIRS.  This is correct because we
need to ensure the dist rules package the directory contents
regardless of the configuration for the 'dist' rule.  The correct
way to handle this is to only invoke the kernel build system as
part of the 'clean' rule when CONFIG_KERNEL_TRUE is set.

Initial fix provided by Darik Horn <dajhorn@vanadac.com>.
This commit is a slightly refined form of the original.

13 years agoCall udevadm trigger more safely
Ned Bass [Fri, 1 Apr 2011 16:47:05 +0000 (09:47 -0700)]
Call udevadm trigger more safely

Some udev hooks are not designed to be idempotent, so calling udevadm
trigger outside of the distribution's initialization scripts can have
unexpected (and potentially dangerous) side effects.  For example, the
system time may change or devices may appear multiple times.  See Ubuntu
launchpad bug 320200 and this mailing list post for more details:

https://lists.ubuntu.com/archives/ubuntu-devel/2009-January/027260.html

To avoid these problems we call udevadm trigger with --action=change
--subsystem-match=block.  The first argument tells udev just to refresh
devices, and make sure everything's as it should be.  The second
argument limits the scope to block devices, so devices belonging to
other subsystems cannot be affected.

This doesn't fix the problem on older udev implementations that don't
provide udevadm but instead have udevtrigger as a standalone program.
In this case the above options aren't available so there's no way to
call call udevtrigger safely.  But we can live with that since this
issue only exists in optional test and helper scripts, and most
zfs-on-linux users are running newer systems anyways.

13 years agoUpdate CHAOS 5 Packaging
Brian Behlendorf [Thu, 31 Mar 2011 20:43:49 +0000 (13:43 -0700)]
Update CHAOS 5 Packaging

The CHAOS 5 kernels are now packaged identially to the RHEL6 kernels.
Therefore we can simply use the RHEL6 rules in the spec file when
building packages.

13 years agoFix libzpool cv_* build error
Brian Behlendorf [Thu, 31 Mar 2011 19:16:24 +0000 (12:16 -0700)]
Fix libzpool cv_* build error

This build failure was accidentally introduced by previous commit
bfd214a which fixed the load average.  Unfortunately, the wrapper
for cv_wait_interruptible was not available in the zfs_context.h
user compatibility code.  I failed to notice this because I didn't
rebuild everything cleanly before committing.

  undefined reference to `cv_wait_interruptible'
  collect2: ld returned 1 exit status

Closes #181

13 years agoFix inflated load average
Brian Behlendorf [Fri, 1 Apr 2011 00:07:12 +0000 (17:07 -0700)]
Fix inflated load average

Kernel threads which sleep uninterruptibly on Linux are marked in the (D)
state.  These threads are usually in the process of performing IO and are
thus counted against the load average.  The txg_quiesce and txg_sync threads
were always sleeping uninterruptibly and thus inflating the load average.

This change makes them sleep interruptibly.  Some care is required however
because these threads may now be woken early by signals.  In this case the
callers are all careful to check that the required conditions are met after
waking up.  If we're woken early due to a signal they will simply go back
to sleep.  In this case these changes are safe.

Closes #175

13 years agoManually update the debian/changelog.
Darik Horn [Thu, 31 Mar 2011 16:04:23 +0000 (11:04 -0500)]
Manually update the debian/changelog.

13 years agoForce the dkms.conf file into the zfs-dkms package.
Darik Horn [Thu, 31 Mar 2011 15:54:06 +0000 (10:54 -0500)]
Force the dkms.conf file into the zfs-dkms package.

Rename the debian/dkms file to debian/zfs-dkms.dkms so that
the dkms.conf file is included in the zfs-dkms package.

The dh_dkms debhelper put the dkms.conf file into the
libavl0 package after the library decomposition, which
caused upgrade errors.

13 years agoManually update the debian/changelog.
Darik Horn [Wed, 30 Mar 2011 21:14:16 +0000 (16:14 -0500)]
Manually update the debian/changelog.

13 years agoAdd the /etc/default/zfs import to the init script.
Darik Horn [Wed, 30 Mar 2011 21:00:45 +0000 (16:00 -0500)]
Add the /etc/default/zfs import to the init script.

The init script is disabled by default.

13 years agoLink /proc/mounts to /etc/mtab.
Darik Horn [Wed, 30 Mar 2011 20:37:08 +0000 (15:37 -0500)]
Link /proc/mounts to /etc/mtab.

During system start, the /etc/init/mountall.conf on Ubuntu is unable to
generate the /etc/mtab file from the /proc/mounts file if a ZFS filesystem is
already mounted.

However, mountall 2.18 behaves properly if /etc/mtab is a symlink to
/proc/mounts.  This version was first published in Ubuntu Maverick.

Additionally, the mountall package is peculiar to Ubuntu, so the mountall
dependency breaks Debian compatibility.  A better solution would be to update
mountall to recognize ZFS mounts, or to find a proc syntax that mountall
already recognizes.

13 years agoManually update the debian/changelog.
Darik Horn [Wed, 30 Mar 2011 18:56:13 +0000 (13:56 -0500)]
Manually update the debian/changelog.

13 years agoMerge branch 'master' into kfreebsd
Darik Horn [Wed, 30 Mar 2011 17:25:02 +0000 (12:25 -0500)]
Merge branch 'master' into kfreebsd

Conflicts:
debian/changelog

13 years agoPrint initramfs errors in a sensible order.
Darik Horn [Wed, 30 Mar 2011 04:35:14 +0000 (23:35 -0500)]
Print initramfs errors in a sensible order.

If the zfs script must drop into a recovery shell, then print the error message
and error number after the command invocation that failed.

13 years agoUse `mount.zfs` instead of `zfs mount` in the initramfs.
Darik Horn [Wed, 30 Mar 2011 04:07:29 +0000 (23:07 -0500)]
Use `mount.zfs` instead of `zfs mount` in the initramfs.

Revert to mounting the root filesytem like this:

  mount -t zfs -o zfsutil "$ZFS_BOOTFS" "$rootmnt"

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 filesystems after the
pivot into the regular root, which later breaks things like `zfs mount -a` and
the /etc/mtab refresh.

Assuming one filesystem on the pivot and implicitly remapping it is sensible
behavior for the exec init.  Keeping the -R prefix is similarly sensible
behavior for the zfs utility.  Thus, the initramfs is probably the best place
to do something unusual.

13 years agoDisable volinit and volfini in the init script.
Darik Horn [Tue, 29 Mar 2011 17:49:43 +0000 (12:49 -0500)]
Disable volinit and volfini in the init script.

The `zfs volinit` and `zfs volfini` commands are unimplemented.

13 years agoDisable `zfs ushare -a`, which is unimplemented on Linux.
Darik Horn [Tue, 29 Mar 2011 17:46:51 +0000 (12:46 -0500)]
Disable `zfs ushare -a`, which is unimplemented on Linux.

13 years agoAdd standard Linux paths to the init script.
Darik Horn [Tue, 29 Mar 2011 17:26:13 +0000 (12:26 -0500)]
Add standard Linux paths to the init script.

13 years agoManually update the debian/changelog.
Darik Horn [Tue, 29 Mar 2011 17:19:34 +0000 (12:19 -0500)]
Manually update the debian/changelog.

13 years agoAdd a zfs conflict to the zfsutils package.
Darik Horn [Tue, 29 Mar 2011 17:13:07 +0000 (12:13 -0500)]
Add  a zfs conflict to the zfsutils package.

This is required because the kFreeBSD /etc/init.d/zfs script
conflicts with the KQ /etc/init.d/zfsload script.

13 years agoChange BSD runlevels to Linux runlevels.
Darik Horn [Tue, 29 Mar 2011 17:02:14 +0000 (12:02 -0500)]
Change BSD runlevels to Linux runlevels.

The unmodified init script from Debian kFreeBSD causes
these warnings during installation:

  update-rc.d: warning: zfs start runlevel arguments (2 3 4 5)
    do not match LSB Default-Start values (S)
  update-rc.d: warning: zfs stop runlevel arguments (0 1 6)
    do not match LSB Default-Stop values (0 6)

13 years agoManually update the debian/changelog.
Darik Horn [Tue, 29 Mar 2011 16:07:46 +0000 (11:07 -0500)]
Manually update the debian/changelog.

13 years agoAdd a zfs-lib replacement to each constituent library.
Darik Horn [Tue, 29 Mar 2011 16:04:56 +0000 (11:04 -0500)]
Add a zfs-lib replacement to each constituent library.

Add "Replaces: zfs-lib" to each library in the debian/control
so that upgrades happen smooothly.

13 years agoUse git-dch to update the debian/changelog.
Darik Horn [Tue, 29 Mar 2011 14:19:11 +0000 (09:19 -0500)]
Use git-dch to update the debian/changelog.

13 years agoChange usr/lib/include to usr/include in the libzfs-dev.install file.
Darik Horn [Tue, 29 Mar 2011 14:10:30 +0000 (09:10 -0500)]
Change usr/lib/include to usr/include in the libzfs-dev.install file.

The libzfs-dev.install file has an incorrect path.

13 years agoAdd libzfs-dev to the debian/control file.
Darik Horn [Thu, 24 Mar 2011 20:38:28 +0000 (15:38 -0500)]
Add libzfs-dev to the debian/control file.

The libzfs-dev package provides a virtual libuutil-dev
and a virtual libnvpair-for compatibility with Debian kFreeBSD.

13 years agoUse git-dch to update the debian/changelog.
Darik Horn [Mon, 28 Mar 2011 03:14:51 +0000 (22:14 -0500)]
Use git-dch to update the debian/changelog.

13 years agoHandle the GRUB zfs-bootfs parameter in the initramfs.
Darik Horn [Sat, 26 Mar 2011 05:23:31 +0000 (00:23 -0500)]
Handle the GRUB zfs-bootfs parameter in the initramfs.

13 years agoUse /sbin/mount.zfs for the root mount in the initramfs.
Darik Horn [Sat, 26 Mar 2011 04:04:38 +0000 (23:04 -0500)]
Use /sbin/mount.zfs for the root mount in the initramfs.

13 years agoSpec file compat, %{datadir}
Fajar A. Nugraha [Fri, 25 Mar 2011 17:01:28 +0000 (10:01 -0700)]
Spec file compat, %{datadir}

The dracut change caused an error during "make rpm".  The cause
is simple, RHEL5 does not recognize the %{datarootdir} macro in
zfs.spec.  It was changed to %{datadir} which fixes the build.

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
13 years agoSet cmd paths in udev rules using --prefix
Brian Behlendorf [Thu, 24 Mar 2011 18:34:41 +0000 (11:34 -0700)]
Set cmd paths in udev rules using --prefix

The udev/rules.d scripts must use absolute paths to their support
binaries.  However, where those binaries get installed depends
on what --prefix was set to when the package was configured.
This change makes the udev/rules.d helpers to *.in files which
are processed by configure.  This allows them to be dynamically
updated to include the specified --prefix.

Additionally, this change updates 60-zvol.rules to handle both
the 'add' and 'change' actions.  This ensures that that all
valid zvol devices are correctly linked.

13 years agoReplace zfs-lib by libzfs0 and zfs by zfsutils
Darik Horn [Thu, 24 Mar 2011 20:29:15 +0000 (15:29 -0500)]
Replace zfs-lib by libzfs0 and zfs by zfsutils
in the debian/control file.

13 years agoCheck zvols for Linux swap areas instead of FreeBSD swap areas.
Darik Horn [Thu, 24 Mar 2011 19:58:56 +0000 (14:58 -0500)]
Check zvols for Linux swap areas instead of FreeBSD swap areas.

Debian kFreeBSD checks for the org.freebsd:swap property on
zvols at startup, so do the same on Linux systems.

13 years agoImport the zfsutils init script from Debian kFreeBSD.
Darik Horn [Thu, 24 Mar 2011 19:56:54 +0000 (14:56 -0500)]
Import the zfsutils init script from Debian kFreeBSD.

13 years agoRemove the KQ init script that was imported from zfs-linux/lzfs.
Darik Horn [Thu, 24 Mar 2011 19:54:39 +0000 (14:54 -0500)]
Remove the KQ init script that was imported from zfs-linux/lzfs.

13 years agoRestrict the package architecture to linux-any.
Darik Horn [Thu, 24 Mar 2011 19:29:37 +0000 (14:29 -0500)]
Restrict the package architecture to linux-any.

This source package is specifically for Linux and incompatible
with the Hurd and kFreeBSD kernels.

13 years agoDecompose the zfs-lib package.
Darik Horn [Thu, 24 Mar 2011 19:21:49 +0000 (14:21 -0500)]
Decompose the zfs-lib package.

The constituent packages are libspl0, libavl0, libefi0, libnvpair0,
libunicode0, libuutil0, libzpool0, and libzfs0.

This change reflects the Debian kFreeBSD packaging.

13 years agoFixes to enable zvol symlink creation
Fajar A. Nugraha [Thu, 24 Mar 2011 08:22:52 +0000 (15:22 +0700)]
Fixes to enable zvol symlink creation

This commit fixes issue on
https://github.com/behlendorf/zfs/issues/#issue/172
Changes:
- update BLKZNAME to use _IOR instead of _IO.  Kernel 2.6.32 allows
read parameters (copy_to_user) with _IO, while newer kernels (tested
Archlinux's 2.6.37 kernel) enforces _IOR (which is correct)
- fix return code and message on error

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
13 years agoRename the zfs-lib package to libzfs0.
Darik Horn [Thu, 24 Mar 2011 18:36:47 +0000 (13:36 -0500)]
Rename the zfs-lib package to libzfs0.

This change reflects the Debian kFreeBSD packaging.

13 years agoRename the zfs package to zfsutils.
Darik Horn [Thu, 24 Mar 2011 18:33:56 +0000 (13:33 -0500)]
Rename the zfs package to zfsutils.

This change reflects the Debian kFreeBSD packaging.

13 years agoUse git-dch to update the debian/changelog.
Darik Horn [Thu, 24 Mar 2011 17:38:16 +0000 (12:38 -0500)]
Use git-dch to update the debian/changelog.

13 years agoInclude /sbin/mount.zfs in the zfs package.
Darik Horn [Thu, 24 Mar 2011 17:36:58 +0000 (12:36 -0500)]
Include /sbin/mount.zfs in the zfs package.

13 years agoUse git-dch to update the debian/changelog.
Darik Horn [Wed, 23 Mar 2011 04:08:52 +0000 (23:08 -0500)]
Use git-dch to update the debian/changelog.

13 years agoRemove the whack-bang and execute bit from the initramfs boot script.
Darik Horn [Wed, 23 Mar 2011 02:08:15 +0000 (21:08 -0500)]
Remove the whack-bang and execute bit from the initramfs boot script.

This change reflects the scripts/local and scripts/nfs files that
are provided by the initramfs-tools package.

13 years agoProperly strip the bootfs= and rpool= kernel command line parameters.
Darik Horn [Wed, 23 Mar 2011 02:02:59 +0000 (21:02 -0500)]
Properly strip the bootfs= and rpool= kernel command line parameters.