summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Automake 1.10.1 compat: AM_SILENT_RULESBrian Behlendorf2013-04-021-1/+1
| | | | | | | | | | | | | | | | | | | Part of the automated testing involves building the source on Debian Lenny which ships an ancient version of automake (1.10.1). Historically, this has caused a non-fatal warning about AM_SILENT_RULES not being defined. But when the autogen.sh script was updated to use autoreconf the warning became fatal. configure.ac:31: warning: macro `AM_SILENT_RULES' not found in library autoreconf: running: /usr/bin/autoconf --force configure.ac:34: error: possibly undefined macro: AM_SILENT_RULES If this token and others are legitimate, please use m4_pattern_allow. To resolve this build issue the call to AM_SILENT_RULES has been wrapped by m4_ifdef(). This prevents the macro from being expanded on platforms where it's undefined. Signed-off-by: Brian Behlendorf <[email protected]>
* build: do not call boilerplate ourselfJan Engelhardt2013-04-024-5/+8
| | | | | | | | | | Rationale see section 3.5 "Using `autoreconf' to Update `configure' Scripts" of the autoconf manual. http://www.gnu.org/software/autoconf/manual/autoconf-2.67/html_node/autoreconf-Invocation.html Signed-off-by: Jan Engelhardt <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]>
* gitignore: anchor entries at their respective directoryJan Engelhardt2013-04-023-11/+12
| | | | | | | .ko is specific to module, .m4 to config, etc. Signed-off-by: Jan Engelhardt <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]>
* build: use CPPFLAGSJan Engelhardt2013-04-021-3/+3
| | | | | | | | -D and -I are preprocessor flags, so should preferably be in the appropriate variable. Signed-off-by: Jan Engelhardt <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]>
* build: resolve orthographic and other grammatical errorsJan Engelhardt2013-04-025-12/+12
| | | | | Signed-off-by: Jan Engelhardt <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]>
* Man page updates for SMBTurbo Fredriksson2013-04-021-2/+14
| | | | | | | | | | | | * Update manpage with more information about the ACL, guest access and that samba needs to be able to authenticate user(s). * Add information that 'net' can be used to modify the share after ZFS sharing and that it will be undone with a 'zfs unshare'. * Give an example on how to mount a SMB filesystem shared via ZFS. Signed-off-by: Brian Behlendorf <[email protected]> Closes #1181 Issue #1170
* Add smb_available() sanity checksTurbo Fredriksson2013-04-021-1/+9
| | | | | | | | Do basic sanity checks in smb_available() to verify that the 'net' command and the usershare directory exists. Signed-off-by: Brian Behlendorf <[email protected]> Closes #1124
* Correct typos in renaming exampleNick Garvey2013-04-021-3/+3
| | | | | Signed-off-by: Brian Behlendorf <[email protected]> Closes #1373
* Tag zfs-0.6.1zfs-0.6.1Brian Behlendorf2013-03-265-11/+10
| | | | | | META file and release log updated. Signed-off-by: Brian Behlendorf <[email protected]>
* Include init scripts in packagesBrian Behlendorf2013-03-261-2/+1
| | | | | | | | | | The distribution specific init scripts where excluded from the packaging when it was reworked. The intention is to replace them with systemd equivilants. However, that work has not yet been done and the init scripts are still useful so they have been added back in to the packaging. Signed-off-by: Brian Behlendorf <[email protected]>
* Provide ${kmodname}-devel-kmod for yum-builddepBrian Behlendorf2013-03-253-3/+6
| | | | | | | | | | | | | | In order to ensure that yum-builddep pulls in all the build requirements a generic ${kmodname}-devel-kmod provides line is added. This allows a version of the development headers to be included without requiring knowledge of the kernel version. This is important because unlike rpmbuild which does correctly expand the source rpm spec file, yum-builddep does not. Without this generic provides line mock which relies on yum-builddep is unable to automatically satisfy the dependency. Signed-off-by: Brian Behlendorf <[email protected]>
* Use 'git describe' for working buildsBrian Behlendorf2013-03-222-10/+28
| | | | | | | | | | | | | | | | | When building from an arbitrary commit in the git tree it's useful for the resulting packages to be uniquely identifiable. Therefore, the build system has been updated to detect if your compiling in git tree. If you are building in a git tree, and there are commits after the last annotated tag. Then the <id>-<hash> component of 'git describe' will be used to overwrite the 'Release:' field in the META file. The only tricky part is that to ensure the 'make dist' tarball is built using the correct release. A dist-hook was added to the top level make file to rewrite the META file using the correct release. Signed-off-by: Brian Behlendorf <[email protected]>
* Fix minor typos and update marketing copy.Darik Horn2013-03-213-16/+9
| | | | | | | | | | | | | | | Correct spelling mistakes in the AUTHORS and DISCLAIMER files, and update the README.markdown file to credit Illumos and mention that the ZPL is finished. The README.markdown file is also the first impression for a handful of new users that discover ZoL through a web search because it doubles as the splash page for the Github repository. The build blurbs are therefore removed because these people should be encouraged to visit the regular home page before installing the product. Signed-off-by: Brian Behlendorf <[email protected]> Closes #1366
* Use requested kernel for dkms buildsBrian Behlendorf2013-03-211-0/+2
| | | | | | | | The --with-linux and --with-linux-obj options must be specified as part of the dkms build otherwise the package will be built against the running kernel. Signed-off-by: Brian Behlendorf <[email protected]>
* Use BUILD_DEPENDS option for dkms buildsBrian Behlendorf2013-03-211-0/+1
| | | | | | | | | Support was added to dkms so build dependencies can be specified. This allows us to ensure that the spl package will always be built before the zfs package. Those patches have not yet been merged upstream but they are available in the zfsonlinux/dkms repository. Signed-off-by: Brian Behlendorf <[email protected]>
* Remove zfs-dkms conflict with zfs-kmodBrian Behlendorf2013-03-211-1/+0
| | | | | | | | | | | | Because the zfs-dkms package also provides zfs-kmod for the zfs user package yum flags this as a conflict. To avoid the problem remove the Conflicts tag from zfs-dkms and just rely on the one in zfs-kmod. zfs-dkms-0.6.0-rc14.fc18.noarch has installed conflicts zfs-kmod: zfs-dkms-0.6.0-rc14.fc18.noarch Signed-off-by: Brian Behlendorf <[email protected]>
* Refresh dracut module setupBrian Behlendorf2013-03-211-2/+5
| | | | | | | | 60-zpool.rules was retired some time ago in favor of 69-vdev.rules. Additionally, there is no guarentee a zpool.cache file exists so only install it conditionally upon its existance. Signed-off-by: Brian Behlendorf <[email protected]>
* Add missing dependenciesBrian Behlendorf2013-03-212-1/+4
| | | | | | | | | | The spl, zfs-test, and zfs-dracut packages should be pulled in by the core zfs package. This allows all the required zfs packages to be installed from a yum repository by running: yum install zfs Signed-off-by: Brian Behlendorf <[email protected]>
* Add spl-dkms dependency to zfs-dkmsBrian Behlendorf2013-03-191-0/+1
| | | | | | | | | | | | | | Adding the 'spl-dkms = VERSION' dependency to the zfs-dkms package ensures the spl will be installed before zfs. This cleanly handles the initial 'yum localinstall' case. However, this does not address the dkms rebuilds caused by a new kernel being installed. For that we still rely on the clunky --with-spl-timeout=<timeout> configure option which allows the zfs compilation to be briefly delayed while the spl components are built. Signed-off-by: Brian Behlendorf <[email protected]>
* Create fsck.zfs and zhack man pages.Darik Horn2013-03-195-3/+178
| | | | | | | | The automake templates have been updated to install them, and the existing packaging will automatically include them. Signed-off-by: Brian Behlendorf <[email protected]> Supplements #518
* Add zio_ddt_free()+ddt_phys_decref() error handlingBrian Behlendorf2013-03-192-4/+9
| | | | | | | | | | | | | | | | | The assumption in zio_ddt_free() is that ddt_phys_select() must always find a match. However, if that fails due to a damaged DDT or some other reason the code will NULL dereference in ddt_phys_decref(). While this should never happen it has been observed on various platforms. The result is that unless your willing to patch the ZFS code the pool is inaccessible. Therefore, we're choosing to more gracefully handle this case rather than leave it fatal. http://mail.opensolaris.org/pipermail/zfs-discuss/2012-February/050972.html Signed-off-by: Brian Behlendorf <[email protected]> Closes #1308
* Add metaslab_debug optionBrian Behlendorf2013-03-181-1/+6
| | | | | | | | | Enabling metaslab debugging will prevent space maps from being automatically unloaded. This can significantly increase the memory footprint but being able to dynamically control this is helpful for debugging and certain performance testing. Signed-off-by: Brian Behlendorf <[email protected]>
* Refresh RPM packagingBrian Behlendorf2013-03-1826-895/+1222
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Refresh the existing RPM packaging to conform to the 'Fedora Packaging Guidelines'. This includes adopting the kmods2 packaging standard which is used fod kmods distributed by rpmfusion for Fedora/RHEL. http://fedoraproject.org/wiki/Packaging:Guidelines http://rpmfusion.org/Packaging/KernelModules/Kmods2 While the spec files have been entirely rewritten from a user perspective the only major changes are: * The Fedora packages now have a build dependency on the rpmfusion repositories. The generic kmod packages also have a new dependency on kmodtool-1.22 but it is bundled with the source rpm so no additional packages are needed. * The kernel binary module packages have been renamed from zfs-modules-* to kmod-zfs-* as specificed by kmods2. * The is now a common kmod-zfs-devel-* package in addition to the per-kernel devel packages. The common package contains the development headers while the per-kernel package contains kernel specific build products. Signed-off-by: Brian Behlendorf <[email protected]> Closes #1341
* Configure --with-spl{-obj} auto-detect cleanupBrian Behlendorf2013-03-131-37/+49
| | | | | | | | | | | | | | | | | | | | | | | | | | Because the install location for the spl/zfs-devel headers was changed we need to refresh the auto-detect code. Note that for packaging which already explicitly calls --with-spl{-obj} nothing has changed. The updated code is now structured like that in ZFS_AC_KERNEL and should be cleaner and easier to maintain. In addition, it's stricter about detecting a valid source and object directory. It requires: * The source directory contains the file 'spl.release' * The object directory contains the file 'spl_config.h' * The following paths will be checked. Notice the /var/lib/ and /usr/src paths require that the spl and zfs version be matched. This is done to prevent accidentally mixing releases. dnl # 1) /var/lib/dkms/spl/<version>/build dnl # 2) /usr/src/spl-<version>/<kernel-version> dnl # 3) /usr/src/spl-<version> dnl # 4) ../spl dnl # 5) /usr/src/kernels/<kernel-version> Signed-off-by: Brian Behlendorf <[email protected]>
* Change zfs-kmod-devel install pathBrian Behlendorf2013-03-137-16/+12
| | | | | | | | | | | | | | | Install the common zfs kernel development headers under /usr/src/zfs-<version>/ rather than in a kernel specific directory. The kernel specific build products such as zfs_config.h and Modules.symvers are left installed under /usr/src/zfs-<version>/<kernel>. This was done to be consistent with where dkms expects kernel module source to be packaged. It also allows for a common zfs-kmod-devel package which includes the headers, and per-kernel zfs-kmod-devel-<kernel> packages. Signed-off-by: Brian Behlendorf <[email protected]>
* Remove COPYINGBrian Behlendorf2013-03-132-3/+1
| | | | | | | | There's no reason to keep this file around it's redundant with the COPYRIGHT and OPENSOLARIS.LICENSE files and causes lintian to emit an extra-license-file warning. Signed-off-by: Brian Behlendorf <[email protected]>
* Create mount.zfs, zinject, and zpios man pages.Darik Horn2013-03-138-2/+488
| | | | | | | And update the automake templates to install them. Signed-off-by: Brian Behlendorf <[email protected]> Closes #518
* Import ztest.1 man page.Michael Gebetsroither2013-03-131-0/+153
| | | | | | | | | | | | | Create a nroff man page for ZoL from: http://grml.org/online-docs/ztest.1.html Which itself was derived from: http://opensolaris.org/os/community/zfs/ztest/ Signed-off-by: Brian Behlendorf <[email protected]> Issue #518
* Linux 3.9 compat: Undefine GCC_VERSIONRichard Yao2013-03-061-0/+8
| | | | | | | | | | | | The mainline kernel started defining GCC_VERSION with commit torvalds/linux@3f3f8d2f48acfd8ed3b8e6b7377935da57b27b16. Unfortunately, LZ4 also defines this macro, but the two defintions are incompatible. We undefine GCC_VERSION in lz4.c to handle this. Signed-off-by: Richard Yao <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]> Closes #1339
* Merge branch 'build-system'Brian Behlendorf2013-03-0628-329/+63
|\
| * Fix zdb.8 macro warningBrian Behlendorf2013-03-061-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Detected by rpmlint the 'rpool/export/home' section was being interpretted by troff as an undefined macro. This resulted in the 'rpool/export/home' output being omitted from 'man zdb'. This was caused by starting the line with a ' character. By moving the 'in' down to the next line we're able to fix it. zfs.x86_64: W: manual-page-warning /usr/share/man/man8/zdb.8.gz 450: warning: macro `rpool/export/home'' not defined Signed-off-by: Brian Behlendorf <[email protected]>
| * Refresh links to web siteNed Bass2013-03-067-8/+8
| | | | | | | | | | | | | | | | A few files still refer to @behlendorf's private fork on github. Use the primary web site URL instead. Two typos are also corrected. Signed-off-by: Brian Behlendorf <[email protected]>
| * Retire ZFS.RELEASE fileBrian Behlendorf2013-03-063-4/+2
| | | | | | | | | | | | | | | | | | | | | | | | The ZFS.RELEASE file was originally added to document which version of OpenSolaris the ZoL code was based on. However, that's no longer particularly important or useful. We'll likely never see a new onnv_* drop from Solaris, and even if we do the ZoL changes are now extensive enough they could not be easily applied. We now treat Illumos as the official upstream and cherry pick the patches we need. Signed-off-by: Brian Behlendorf <[email protected]>
| * Remove ARCH packagingBrian Behlendorf2013-03-069-211/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The kernel modules are now available in the Arch User Repository (AUR) via zfs. Since their packaging is maintained and superior to ours it is being removed from the tree. https://wiki.archlinux.org/index.php/ZFS Now that various distributions are picking up the packages we should eventually be able to remove most of this infrastructure. Packaging belongs with the distributions not upstream. Signed-off-by: Brian Behlendorf <[email protected]>
| * Add --with-dracutdir configure optionBrian Behlendorf2013-03-064-3/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | The standard dracut directory has moved from /usr/share/dracut to /usr/lib/dracut. To ensure the dracut modules get installed in the correct location provide a --with-dracutdir configure option to set the path. The default install location has been updated to /usr/lib/dracut which is used by more current versions of Fedora. However, this default is overriden by the RPM packaging for consistency. Signed-off-by: Brian Behlendorf <[email protected]>
| * Add KMODDIR to install targetBrian Behlendorf2013-03-061-8/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | Provide a mechanism to control the directory name the modules are installed in. The kernel privdes INSTALL_MOD_DIR for this but it was hardcoded to be 'addon/zfs'. Add a KMODDIR variable which can be passed to 'make install' to override the default directory name. While we're here change the default from 'addon/zfs' to 'extra' which is the kernel.org default. Signed-off-by: Brian Behlendorf <[email protected]>
| * Fix zfs_config.h install permissionsBrian Behlendorf2013-03-061-1/+1
| | | | | | | | | | | | | | The default permissions used by install are 755. Since this file isn't executable 644 is more appropriate. Signed-off-by: Brian Behlendorf <[email protected]>
| * Replace libexecdir with datadirBrian Behlendorf2013-03-067-92/+17
|/ | | | | | | | | | According to the FHS. Testing scripts and examples which are all architecture independent should be installed in a subdirectory under /usr/share. http://www.pathname.com/fhs/2.2/fhs-4.11.html Signed-off-by: Brian Behlendorf <[email protected]>
* Add snapdev=[hidden|visible] dataset propertyEric Dillmann2013-03-059-3/+103
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The new snapdev dataset property may be set to control the visibility of zvol snapshot devices. By default this value is set to 'hidden' which will prevent zvol snapshots from appearing under /dev/zvol/ and /dev/<dataset>/. When set to 'visible' all zvol snapshots for the dataset will be visible. This functionality was largely added because when automatic snapshoting is enabled large numbers of read-only zvol snapshots will be created. When creating these devices the kernel will attempt to read their partition tables, and blkid will attempt to identify any filesystems on those partitions. This leads to a variety of issues: 1) The zvol partition tables will be read in the context of the `modprobe zfs` for automatically imported pools. This is undesirable and should be done asynchronously, but for now reducing the number of visible devices helps. 2) Udev expects to be able to complete its work for a new block devices fairly quickly. When many zvol devices are added at the same time this is no longer be true. It can lead to udev timeouts and missing /dev/zvol links. 3) Simply having lots of devices in /dev/ can be aukward from a management standpoint. Hidding the devices your unlikely to ever use helps with this. Any snapshot device which is needed can be made visible by changing the snapdev property. NOTE: This patch changes the default behavior for zvols which was effectively 'snapdev=visible'. Signed-off-by: Brian Behlendorf <[email protected]> Closes #1235 Closes #945 Issue #956 Issue #756
* Merge zvol.c changes from PSARC 2010/306 Read-only ZFS poolsGeorge Wilson2013-03-041-5/+8
| | | | | | | | | | | | | | | | | | The changes to zvol.c were never merged from the last onnv_147 bulk update. This was because zvol.c was largely rewritten for Linux making it fairly easy to miss these sorts of changes. This causes a regression when importing a zpool with zvols read-only. This does not impact pool which only contain filesystem datasets. References: illumos/illumos-gate@f9af39b Signed-off-by: Richard Yao <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]> Closes #1332 Closes #1333
* Constify structures containing function pointersRichard Yao2013-03-0413-59/+59
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The PaX team modified the kernel's modpost to report writeable function pointers as section mismatches because they are potential exploit targets. We could ignore the warnings, but their presence can obscure actual issues. Proper const correctness can also catch programming mistakes. Building the kernel modules against a PaX/GrSecurity patched Linux 3.4.2 kernel reports 133 section mismatches prior to this patch. This patch eliminates 130 of them. The quantity of writeable function pointers eliminated by constifying each structure is as follows: vdev_opts_t 52 zil_replay_func_t 24 zio_compress_info_t 24 zio_checksum_info_t 9 space_map_ops_t 7 arc_byteswap_func_t 5 The remaining 3 writeable function pointers cannot be addressed by this patch. 2 of them are in zpl_fs_type. The kernel's sget function requires that this be non-const. The final writeable function pointer is created by SPL_SHRINKER_DECLARE. The kernel's set_shrinker() and remove_shrinker() functions also require that this be non-const. Signed-off-by: Richard Yao <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]> Closes #1300
* Eliminate runtime function pointer mods in autotools checksRichard Yao2013-03-0410-150/+113
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PaX/GrSecurity patched kernels implement a dialect of C that relies on a GCC plugin for enforcement. A basic idea in this dialect is that function pointers in structures should not change during runtime. This causes code that modifies function pointers at runtime to fail to compile in many instances. The autotools checks rely on whether or not small test cases compile against a given kernel. Some autotools checks assume some default case if other cases fail. When one of these autotools checks tests a PaX/GrSecurity patched kernel by modifying a function pointer at runtime, the default case will be used. Early detection of such situations is possible by relying on compiler warnings, which are compiler errors when --enable-debug is used. Unfortunately, very few people build ZFS with --enable-debug. The more common situation is that these issues manifest themselves as runtime failures in the form of NULL pointer exceptions. Previous patches that addressed such issues with PaX/GrSecurity compatibility largely relied on rewriting autotools checks to avoid runtime function pointer modification or the addition of PaX/GrSecurity specific checks. This patch takes the previous work to its logical conclusion by eliminating the use of runtime function pointer modification. This permits the removal of PaX-specific autotools checks in favor of ones that work across all supported kernels. This should resolve issues that were reported to occur with PaX/GrSecurity-patched Linux 3.7.5 kernels on Gentoo Linux. https://bugs.gentoo.org/show_bug.cgi?id=457176 We should be able to prevent future regressions in PaX/GrSecurity compatibility by ensuring that all changes to ZFSOnLinux avoid runtime function pointer modification. At the same time, this does not solve the issue of silent failures triggering default cases in the autotools check, which is what permitted these regressions to become runtime failures in the first place. This will need to be addressed in a future patch. Reported-by: Marcin MirosÅ‚aw <[email protected]> Signed-off-by: Richard Yao <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]> Closes #1300
* Fix hot sparesBrian Behlendorf2013-03-013-82/+115
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The issue with hot spares in ZoL is because it opens all leaf vdevs exclusively (O_EXCL). On Linux, exclusive opens cause subsequent exclusive opens to fail with EBUSY. This could be resolved by not opening any of the devices exclusively, which is what Illumos does, but the additional protection offered by exclusive opens is desirable. It cleanly prevents you from accidentally adding an in-use non-ZFS device to your pool. To fix this we very slightly relaxed the usage of O_EXCL in the following ways. 1) Functions which open the device but only read had the O_EXCL flag removed and were updated to use O_RDONLY. 2) A common holder was added to the vdev disk code. This allow the ZFS code to internally open the device multiple times but non-ZFS callers may not. 3) An exception was added to make_disks() for hot spare when creating partition tables. For hot spare devices which are already opened exclusively we skip creating the partition table because this must already have been done when the disk was originally added as a hot spare. Additional minor changes include fixing check_in_use() to use a partition instead of a slice suffix. And is_spare() was moved above make_disks() to avoid adding a forward reference. Signed-off-by: Brian Behlendorf <[email protected]> Closes #250
* Remove wholedisk check from vdev_disk_open()Brian Behlendorf2013-02-281-14/+0
| | | | | | | | | As described by the comment and enforced the by assertion the v->vdev_wholedisk will never be -1. The wholedisk handling is performed by the user space utilities. To prevent confusion this dead code is being removed. Signed-off-by: Brian Behlendorf <[email protected]>
* Leaf vdevs should not be reopenedBrian Behlendorf2013-02-281-3/+16
| | | | | | | | | | | | | | | | | | | When vdev_disk.c was implemented for Linux we failed to handle the reopen case. According to the vdev_reopen() comment leaf vdevs should not be closed or opened when v->vdev_reopening is set. Under Linux we would always close and open the device. This issue was only noticed when a 'zpool scrub' command was run while the leaf vdev device names in /dev/disk/by-vdev were missing. The scrub command calls vdev_reopen() which caused the vdevs to be closed but they couldn't be reopened due to the missing links. The result was that all the vdevs were marked unavailable and the pool was halted due to failmode=wait. This patch adds the missing functionality in a similiar fashion to to the Illumos code. Signed-off-by: Brian Behlendorf <[email protected]>
* -x shouldn't warn about old on-disk format or unavailable featuresTim Connors2013-02-282-2/+5
| | | | | | | | | `zpool status -x` should only flag errors or where the pool is unavailable. If it imported fine but isn't using the latest features available in the code, that's not an error. Signed-off-by: Brian Behlendorf <[email protected]> Closes #1319
* Remove the bio_empty_barrier() check.Etienne Dechamps2013-02-243-29/+0
| | | | | | | | | | | | | | | | | | | | | | | To determine whether the kernel is capable of handling empty barrier BIOs, we check for the presence of the bio_empty_barrier() macro, which was introduced in 2.6.24. If this macro is defined, then we can flush disk vdevs; if it isn't, then flushing is disabled. Unfortunately, the bio_empty_barrier() macro was removed in 2.6.37, even though the kernel is still capable of handling empty barrier BIOs. As a result, flushing is effectively disabled on kernels >= 2.6.37, meaning that starting from this kernel version, zfs doesn't use barriers to guarantee on-disk data consistency. This is quite bad and can lead to potential data corruption on power failures. This patch fixes the issue by removing the configure check for bio_empty_barrier(), as we don't support kernels <= 2.6.24 anymore. Thanks to Richard Kojedzinszky for catching this nasty bug. Signed-off-by: Brian Behlendorf <[email protected]> Closes #1318
* Use -Werror for all kernel configure tests.Etienne Dechamps2013-02-244-11/+1
| | | | | | | | | | | | | As a matter of fact, we're already using -Werror for most tests because of a bug in kernel-bio-empty-barrier.m4 which sets -Werror without reverting it afterwards. This meant that all tests which ran after this one was using -Werror. This patch simply makes it clear that we're using -Werror and makes the code more readable and more predictable. Signed-off-by: Brian Behlendorf <[email protected]> Closes #1317
* Enable zfs_arc_memory_throttle_disable by defaultBrian Behlendorf2013-02-211-1/+1
| | | | | | | | | | | | | | | | | | | The zfs_arc_memory_throttle_disable module option was introduced by commit 0c5493d47059f25ce9dbf20c9fe87655f55102a1 to resolve a memory miscalculation which could result in the txg_sync thread spinning. When this was first introduced the default behavior was left unchanged until enough real world usage confirmed there were no unexpected issues. We've now reached that point. Linux's direct reclaim is working as expected so we're enabling this behavior by default. This helps pave the way to retire the spl_kmem_availrmem() functionality in the SPL layer. This was the only caller. Signed-off-by: Brian Behlendorf <[email protected]> Issue #938
* Fix broken RPATH in spec fileBrian Behlendorf2013-02-121-5/+2
| | | | | | | | | | | | | | | | | | | | | | Rather then setting _prefix=/ and having to override all the default install locations. It's cleaner, and more understandable, to leave prefix=/usr and only override _sbindir and _libdir. This fixes three issues: * The commands no longer get built with an incorrect rpath for the libraries. This is good because fixing this sort of thing is required by the Fedora packaging guidelines. http://fedoraproject.org/wiki/Packaging:Guidelines#Beware_of_Rpath * The various AUTHORS, COPYRIGHT, etc files are now correctly installed under /usr/share/doc instead of /share/doc. * _libexecdir is now handled properly for each distribution. Fedora/RHEL=/usr/libexec, OpenSUSE/SLES=/usr/lib, Debian=/usr/lib/rpm Signed-off-by: Brian Behlendorf <[email protected]> Closes #1058