commit zfs-fuse for openSUSE:Factory
Hello community, here is the log from the commit of package zfs-fuse for openSUSE:Factory checked in at Tue Jan 25 10:33:17 CET 2011. -------- New Changes file: --- /dev/null 2010-08-26 16:28:41.000000000 +0200 +++ /mounts/work_src_done/STABLE/zfs-fuse/zfs-fuse.changes 2010-12-02 12:58:22.000000000 +0100 @@ -0,0 +1,85 @@ +------------------------------------------------------------------- +Thu Dec 2 12:00:21 UTC 2010 - gber@opensuse.org + +- added BuildRequires: udev to fix the build + +------------------------------------------------------------------- +Wed Nov 17 14:25:15 UTC 2010 - gber@opensuse.org + +- replaced source tarball with unmodified version 0.6.9 from + upstream +- cleanup + + install zfs_pool_alert below _libexecdir + + renamed zfs-fuse-fix_strncat_buffer_overflow.patch (there is + no buffer oveflow possible) + + cleaned up specfile + + no need for rpmlintrc any more +- added patch to make stack non-executable on x86 +- install zfsstress.py, arcstat.pl, and bash completion +- added custom zfsrc +- added custom init script for openSUSE which follows + recommendations from + http://rudd-o.com/en/linux-and-free-software/starting-zfs-fuse-up-properly +- added custom sysconfig file allowing for tweaks (prevention of + unintended restarts, nice value) +- added manpage for zfs-fuse + +------------------------------------------------------------------- +Wed Aug 11 17:30:59 UTC 2010 - pascal.bleser@opensuse.org + +- add patch to fix buffer overflow +- add patch to pass CCFLAGS, CPPFLAGS and LINKFLAGS from the environment (and hence the .spec file); + includes passing them to the configure script for src/lib/libumem +- rpmlintrc to disable false positives + +------------------------------------------------------------------- +Tue Jun 8 20:55:25 UTC 2010 - lenz@grimmer.com + +- Update to version 0.6.9 final + +------------------------------------------------------------------- +Tue Jun 8 20:27:45 UTC 2010 - lenz@grimmer.com + +- Update to version 0.6.9_beta3, refreshed the patch files +- Moved the package changelog from the spec file to a separate + .changes logfile +- Aligned the spec file with the one included in the package + +------------------------------------------------------------------- +Thu Dec 17 00:00:00 UTC 2009 - lenz@grimmer.com + +- Updated to version 0.6.0 (official release on 2009-12-06) + +------------------------------------------------------------------- +Wed Sep 2 00:00:00 UTC 2009 - lenz@grimmer.com + +- Updated to version 0.6.0-433snapshot (created via make-dist from the git repo) +- Added man pages and sysconfig file +- Updated init script patch + +------------------------------------------------------------------- +Fri Aug 14 00:00:00 UTC 2009 - lenz@grimmer.com + +- Updated to version 0.5.1r414 (hg snapshot taken from http://git.rudd-o.com/zfs/) + +------------------------------------------------------------------- +Mon Dec 15 00:00:00 UTC 2008 - lenz@grimmer.com + +- Updated to version 0.5.0r375 (hg snapshot) +- Removed build patch (now included upstream) + +------------------------------------------------------------------- +Thu Sep 18 00:00:00 UTC 2008 - lenz@grimmer.com + +- Updated to version 0.5.0 + +------------------------------------------------------------------- +Tue Aug 26 00:00:00 UTC 2008 - lenz@grimmer.com + +- Added rczfs-fuse convenience symlink + +------------------------------------------------------------------- +Sun Aug 24 00:00:00 UTC 2008 - lenz@grimmer.com + +- Initial package, based on hg revision 346 of the trunk + calling whatdependson for head-i586 New: ---- sysconfig.zfs-fuse zfs-fuse-0.6.9-fix-buildsystem.patch zfs-fuse-0.6.9-fix-executable-stack.patch zfs-fuse-0.6.9-fix-strncat-usage.patch zfs-fuse-0.6.9-gcc-4.5-fix.patch zfs-fuse-0.6.9.tar.bz2 zfs-fuse.8.xml zfs-fuse.changes zfs-fuse.init zfs-fuse.spec zfsrc ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ zfs-fuse.spec ++++++ # # spec file for package zfs-fuse # # Copyright (c) 2011 SUSE LINUX Products GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed # upon. The license for this file, and modifications and additions to the # file, is the same license as for the pristine package itself (unless the # license for the pristine package is not an Open Source License, in which # case the license is the MIT License). An "Open Source License" is a # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. # Please submit bugfixes or comments via http://bugs.opensuse.org/ # Name: zfs-fuse Version: 0.6.9 Release: 1 Summary: A port of ZFS to the FUSE framework for the Linux operating system License: CDDL 1.0 Group: System/Filesystems Url: http://zfs-fuse.net/ Source: http://zfs-fuse.net/releases/%{version}/zfs-fuse-%{version}.tar.bz2 Source1: zfs-fuse.init Source2: sysconfig.zfs-fuse Source3: zfsrc Source4: zfs-fuse.8.xml Patch1: zfs-fuse-0.6.9-fix-buildsystem.patch Patch2: zfs-fuse-0.6.9-fix-strncat-usage.patch Patch3: zfs-fuse-0.6.9-fix-executable-stack.patch Patch4: zfs-fuse-0.6.9-gcc-4.5-fix.patch BuildRequires: fuse-devel BuildRequires: libattr-devel BuildRequires: libaio-devel BuildRequires: libacl-devel BuildRequires: zlib-devel BuildRequires: scons BuildRequires: openssl-devel BuildRequires: docbook-xsl-stylesheets BuildRequires: libxslt BuildRequires: udev Requires: fuse Requires(pre): %insserv_prereq Requires(pre): %fillup_prereq Provides: fuse-zfs = %{version} BuildRoot: %{_tmppath}/%{name}-%{version}-build %description zfs-fuse is a port of ZFS to the FUSE framework and makes it possible to create, mount, use and manage ZFS file systems under Linux, bringing the uncontested reliability and large feature set of ZFS to the Linux world. Authors: -------- <rudd-o@rudd-o.com> Ricardo Correia <rcorreia@wizy.org> %prep %setup -q %patch1 -p1 %patch2 -p1 %patch3 -p1 %patch4 -p1 %__mkdir examples %__mv contrib/zfsstress.py contrib/arcstat.pl examples %build export CCFLAGS="%{optflags}" export CPPFLAGS="%{optflags}" scons --no-cache -C src xsltproc --nonet \ http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl \ %SOURCE4 %install %__install -d -m 755 %{buildroot}%{_sysconfdir}/zfs scons -C src \ install_dir=%{buildroot}%{_sbindir} \ cfg_dir=%{buildroot}%{_libexecdir}/%{name} \ libexec_dir=%{buildroot}%{_libexecdir}/%{name} \ man_dir=%{buildroot}%{_mandir}/man8/ \ install %__install -D -p -m 755 %{SOURCE1} %{buildroot}%{_initddir}/%{name} %__ln_s %{_sysconfdir}/init.d/zfs-fuse %{buildroot}%{_sbindir}/rczfs-fuse %__install -D -p -m 644 %{SOURCE2} \ %{buildroot}%{_var}/adm/fillup-templates/sysconfig.%{name} %__install -D -p -m 644 %{SOURCE3} %{buildroot}%{_sysconfdir}/%{name}/zfsrc %__install -D -p -m 644 zfs-fuse.8 %{buildroot}%{_mandir}/man8/zfs-fuse.8 %__install -D -p -m 644 contrib/zfs_completion.bash \ %{buildroot}%{_sysconfdir}/bash_completion.d/zfs-fuse.sh %clean %__rm -rf %{buildroot} %post %fillup_and_insserv %name %restart_on_update %name %preun %stop_on_removal %name %postun %insserv_cleanup %files %defattr(-,root,root,-) %doc BUGS CHANGES HACKING INSTALL LICENSE README README.NFS STATUS TESTING TODO %doc examples %doc %{_mandir}/man8/* %dir %{_sysconfdir}/%{name} %config %{_sysconfdir}/%{name}/zfsrc %{_sysconfdir}/bash_completion.d/zfs-fuse.sh %{_initddir}/%{name} %dir %{_libexecdir}/%{name} %{_libexecdir}/%{name}/zfs_pool_alert %{_sbindir}/rczfs-fuse %{_sbindir}/zdb %{_sbindir}/zfs %{_sbindir}/zpool %{_sbindir}/ztest %{_sbindir}/zfs-fuse %{_sbindir}/zstreamdump %{_var}/adm/fillup-templates/sysconfig.%{name} %changelog ++++++ sysconfig.zfs-fuse ++++++ ## Path: System/Filesystem/ZFS ## Description: ZFS FUSE ## ServiceReload: zfs-fuse ## Type: integer(-20:19) ## Default: 0 # # Nice value of the zfs-fuse daemon # ZFS_NICE_LEVEL=0 ## Type: yesno ## Default: yes # # Determines whether it is possible to restart the zfs-fuse daemon. This must # be set to "no" if vital filesystems which must not be unmounted (during a # package upgrade or unlevel changes) are using ZFS. # ZFS_ALLOW_RELOAD=yes ++++++ zfs-fuse-0.6.9-fix-buildsystem.patch ++++++ diff -ur zfs-fuse-0.6.9.orig/src/lib/libumem/SConscript zfs-fuse-0.6.9/src/lib/libumem/SConscript --- zfs-fuse-0.6.9.orig/src/lib/libumem/SConscript 2010-06-04 21:03:04.000000000 +0200 +++ zfs-fuse-0.6.9/src/lib/libumem/SConscript 2010-11-17 15:38:58.000000000 +0100 @@ -1,5 +1,5 @@ Import('env') -Command("Makefile", [], ["cd lib/libumem && ./configure"]) +Command("Makefile", [], [env.subst("cd lib/libumem && CFLAGS=\"$CCFLAGS\" CPPFLAGS=\"$CPPFLAGS\" LDFLAGS=\"$LINKFLAGS\" ./configure").replace("-std=c99", "-std=gnu99")]) Command("libumem.a", [Glob('*.c'),'Makefile',Glob('*.h')], ["cd lib/libumem && make && rm -f libumem.a && ln -s .libs/libumem.a"]) diff -ur zfs-fuse-0.6.9.orig/src/lib/libzpool/vdev.c zfs-fuse-0.6.9/src/lib/libzpool/vdev.c --- zfs-fuse-0.6.9.orig/src/lib/libzpool/vdev.c 2010-06-04 21:03:04.000000000 +0200 +++ zfs-fuse-0.6.9/src/lib/libzpool/vdev.c 2010-11-17 15:21:45.000000000 +0100 @@ -43,6 +43,10 @@ #include <syslog.h> #include <libintl.h> +#ifndef LIBEXECDIR +#define LIBEXECDIR "/usr/lib" +#endif + /* * Virtual device management. */ @@ -3056,7 +3060,7 @@ return; // nothing of interest here } if (strcasecmp(top->spa_name,"$import")) { - snprintf(cmd,2048,"/etc/zfs/zfs_pool_alert %s &",top->spa_name); + snprintf(cmd,2048,LIBEXECDIR "/zfs_pool_alert %s &",top->spa_name); syslog(LOG_WARNING,"running zfs_pool_alert for pool %s, status %s prev status %s",top->spa_name,zpool_state_to_name(state,save_state), zpool_state_to_name(save_state,state)); int ret = system(cmd); diff -ur zfs-fuse-0.6.9.orig/src/SConstruct zfs-fuse-0.6.9/src/SConstruct --- zfs-fuse-0.6.9.orig/src/SConstruct 2010-06-04 21:03:04.000000000 +0200 +++ zfs-fuse-0.6.9/src/SConstruct 2010-11-17 15:24:44.000000000 +0100 @@ -8,6 +8,7 @@ install_dir = ARGUMENTS.get('install_dir', '/usr/local/sbin') man_dir = ARGUMENTS.get('man_dir', '/usr/local/share/man/man8/') cfg_dir = ARGUMENTS.get('cfg_dir', '/etc/zfs') +libexec_dir = ARGUMENTS.get('libexec_dir', '/usr/local/lib/zfs-fuse') env = Environment() @@ -16,28 +17,22 @@ f.close() env.CacheDir('/tmp/.zfs-fuse.scons') -env['CC'] = 'gcc' +if 'CC' in os.environ: + env['CC'] = os.environ['CC'] +else: + env['CC'] = 'gcc' env['LINKFLAGS'] = Split('-pipe -Wall') +if 'LDFLAGS' in os.environ: + env.Append(LINKFLAGS = " "+os.environ['LDFLAGS']) env['CCFLAGS'] = Split('-pipe -Wall -std=c99 -Wno-switch -Wno-unused -Wno-missing-braces -Wno-parentheses -Wno-uninitialized -fno-strict-aliasing -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_REENTRANT -DTEXT_DOMAIN=\\"zfs-fuse\\" ') if osname == "Linux": env.Append(CPPFLAGS = " -DLINUX_AIO") -debug = int(ARGUMENTS.get('debug', '0')) - -if not debug: - env.Append(LINKFLAGS = ['-s']) - env.Append(CCFLAGS = Split('-s -O2 -DNDEBUG')) -else: - env.Append(LINKFLAGS = ['-ggdb']) - env.Append(CCFLAGS = ['-ggdb']) -# Be careful here, one of DEBUG or NDEBUG must be defined, if you undef both, you'll get unexpected results - if debug == 1: - env.Append(CCFLAGS = Split('-O2 -DDEBUG')) - elif debug == 2: - env.Append(CCFLAGS = ['-DDEBUG']) - elif debug == 3: - env.Append(CCFLAGS = Split('-finstrument-functions -DDEBUG')) +if 'CPPFLAGS' in os.environ: + env.Append(CPPFLAGS = " "+os.environ['CPPFLAGS']) +if 'CCFLAGS' in os.environ: + env.Append(CPPFLAGS = " "+os.environ['CCFLAGS']) env['CPPPATH'] = [] @@ -99,7 +94,7 @@ env.Install(install_dir, 'cmd/zfs/zfs') env.Install(install_dir, 'zfs-fuse/zfs-fuse') env.Install(install_dir, 'cmd/zstreamdump/zstreamdump') -env.Install(cfg_dir, '../contrib/zfs_pool_alert') +env.Install(libexec_dir, '../contrib/zfs_pool_alert') env.Install(man_dir, '../doc/zdb.8.gz') env.Install(man_dir, '../doc/zfs.8.gz') @@ -110,4 +105,4 @@ print "updating tags..." os.system("ctags --extra=+f `find -name '*.c'` `find -name '*.h'`") -env.Alias('install', [install_dir, man_dir, cfg_dir]) +env.Alias('install', [install_dir, man_dir, cfg_dir, libexec_dir]) ++++++ zfs-fuse-0.6.9-fix-executable-stack.patch ++++++ diff -ur zfs-fuse-0.6.9.orig/src/lib/libsolcompat/amd64/atomic.S zfs-fuse-0.6.9/src/lib/libsolcompat/amd64/atomic.S --- zfs-fuse-0.6.9.orig/src/lib/libsolcompat/amd64/atomic.S 2010-06-22 10:31:58.000000000 +0200 +++ zfs-fuse-0.6.9/src/lib/libsolcompat/amd64/atomic.S 2010-11-11 20:04:08.000000000 +0100 @@ -605,3 +605,7 @@ SET_SIZE(membar_consumer) #endif /* !_KERNEL */ + +#ifdef __ELF__ +.section .note.GNU-stack,"",%progbits +#endif diff -ur zfs-fuse-0.6.9.orig/src/lib/libsolcompat/i386/atomic.S zfs-fuse-0.6.9/src/lib/libsolcompat/i386/atomic.S --- zfs-fuse-0.6.9.orig/src/lib/libsolcompat/i386/atomic.S 2010-06-22 10:31:58.000000000 +0200 +++ zfs-fuse-0.6.9/src/lib/libsolcompat/i386/atomic.S 2010-11-11 20:04:01.000000000 +0100 @@ -740,3 +740,7 @@ SET_SIZE(membar_consumer) #endif /* !_KERNEL */ + +#ifdef __ELF__ +.section .note.GNU-stack,"",%progbits +#endif ++++++ zfs-fuse-0.6.9-fix-strncat-usage.patch ++++++ diff -ur zfs-fuse-0.6.9.orig/src/lib/libzfs/libzfs_sendrecv.c zfs-fuse-0.6.9/src/lib/libzfs/libzfs_sendrecv.c --- zfs-fuse-0.6.9.orig/src/lib/libzfs/libzfs_sendrecv.c 2010-06-04 21:03:04.000000000 +0200 +++ zfs-fuse-0.6.9/src/lib/libzfs/libzfs_sendrecv.c 2010-11-17 16:07:02.000000000 +0100 @@ -2341,7 +2341,7 @@ */ (void) strcpy(zc.zc_top_ds, tosnap); (void) strcpy(zc.zc_value, tosnap); - (void) strncat(zc.zc_value, chopprefix, sizeof (zc.zc_value)); + (void) strncat(zc.zc_value, chopprefix, sizeof (zc.zc_value)-strlen(zc.zc_value)-1); free(cp); if (!zfs_name_valid(zc.zc_value, ZFS_TYPE_SNAPSHOT)) { zcmd_free_nvlists(&zc); ++++++ zfs-fuse-0.6.9-gcc-4.5-fix.patch ++++++ From: Seth Heeren <sgheeren@hotmail.com> Date: Thu, 3 Jun 2010 20:33:51 +0000 (+0200) Subject: gcc 4.5 patch submitted by Piotr Pawłow X-Git-Url: http://gitweb.zfs-fuse.net/?p=emmanuel;a=commitdiff_plain;h=4659528a01952f2c... gcc 4.5 patch submitted by Piotr Pawłow --- diff --git a/src/zfs-fuse/zfs_operations.c b/src/zfs-fuse/zfs_operations.c index e1874eb..9199371 100644 --- a/src/zfs-fuse/zfs_operations.c +++ b/src/zfs-fuse/zfs_operations.c @@ -245,6 +245,11 @@ static int int_zfs_enter(zfsvfs_t *zfsvfs) { static void zfsfuse_listxattr(fuse_req_t req, fuse_ino_t ino, size_t size) { + union { + char buf[DIRENT64_RECLEN(MAXNAMELEN)]; + struct dirent64 dirent; + } entry; + /* It's like a lookup, but passing LOOKUP_XATTR as a flag to VOP_LOOKUP */ MY_LOOKUP_XATTR(); @@ -256,10 +261,6 @@ static void zfsfuse_listxattr(fuse_req_t req, fuse_ino_t ino, size_t size) // Now try a readdir... char *outbuf = NULL; int alloc = 0,used = 0; - union { - char buf[DIRENT64_RECLEN(MAXNAMELEN)]; - struct dirent64 dirent; - } entry; struct stat fstat = { 0 }; ++++++ zfs-fuse.8.xml ++++++ <?xml version='1.0' encoding='ISO-8859-1'?> <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN" "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd" [ <!-- Process this file with an XSLT processor: `xsltproc \ -''-nonet /usr/share/sgml/docbook/stylesheet/xsl/nwalsh/\ manpages/docbook.xsl manpage.dbk'. A manual page <package>.<section> will be generated. You may view the manual page with: nroff -man <package>.<section> | less'. A typical entry in a Makefile or Makefile.am is: DB2MAN=/usr/share/sgml/docbook/stylesheet/xsl/nwalsh/\ manpages/docbook.xsl XP=xsltproc -''-nonet manpage.1: manpage.dbk $(XP) $(DB2MAN) $< The xsltproc binary is found in the xsltproc package. The XSL files are in docbook-xsl. Please remember that if you create the nroff version in one of the debian/rules file targets (such as build), you will need to include xsltproc and docbook-xsl in your Build-Depends control field. --> <!-- Fill in your name for FIRSTNAME and SURNAME. --> <!ENTITY dhfirstname "<firstname>Bryan</firstname>"> <!ENTITY dhsurname "<surname>Donlan</surname>"> <!-- Please adjust the date whenever revising the manpage. --> <!ENTITY dhdate "<date>2010-06-09</date>"> <!-- SECTION should be 1-8, maybe w/ subsection other parameters are allowed: see man(7), man(1). --> <!ENTITY dhsection "<manvolnum>8</manvolnum>"> <!ENTITY dhemail "<email>bdonlan@gmail.com</email>"> <!ENTITY dhusername "Bryan Donlan"> <!ENTITY dhucpackage "<refentrytitle>zfs-fuse</refentrytitle>"> <!ENTITY dhpackage "zfs-fuse"> <!ENTITY debian "<productname>Debian</productname>"> <!ENTITY gnu "<acronym>GNU</acronym>"> <!ENTITY gpl "&gnu; <acronym>GPL</acronym>"> ]> <refentry> <refentryinfo> <address> &dhemail; </address> <copyright> <year>2010</year> <holder>&dhusername;</holder> </copyright> &dhdate; </refentryinfo> <refmeta> &dhucpackage; &dhsection; </refmeta> <refnamediv> <refname>&dhpackage;</refname> <refpurpose>ZFS filesystem daemon</refpurpose> </refnamediv> <refsynopsisdiv> <cmdsynopsis> <command>&dhpackage;</command> <arg><option>--pidfile <replaceable>filename</replaceable></option></arg> <arg><option>--no-daemon</option></arg> <arg><option>--no-kstat-mount</option></arg> <arg><option>--disable-block-cache</option></arg> <arg><option>--disable-page-cache</option></arg> <arg><option>--fuse-attr-timeout <replaceable>SECONDS</replaceable></option></arg> <arg><option>--fuse-entry-timeout <replaceable>SECONDS</replaceable></option></arg> <arg><option>--log-uberblocks</option></arg> <arg><option>--max-arc-size <replaceable>MB</replaceable></option></arg> <arg><option>--fuse-mount-options <replaceable>OPT,OPT,OPT...</replaceable></option></arg> <arg><option>--min-uberblock-txg <replaceable>MIN</replaceable></option></arg> <arg><option>--stack-size=<replaceable>size</replaceable></option></arg> <arg><option>--help</option></arg> </cmdsynopsis> </refsynopsisdiv> <refsect1> <title>DESCRIPTION</title> <para>This manual page documents briefly the <command>&dhpackage;</command> command.</para> <para><command>&dhpackage;</command> is a daemon which provides support for the ZFS filesystem, via fuse. Ordinarily this daemon will be invoked from system boot scripts.</para> </refsect1> <refsect1> <title>OPTIONS</title> <para>This program follows the usual &gnu; command line syntax, with long options starting with two dashes (`-'). A summary of options is included below. For a complete description, see the <application>Info</application> files.</para> <variablelist> <varlistentry> <term><option>-h</option> <option>--help</option> </term> <listitem> <para>Show summary of options.</para> </listitem> </varlistentry> <varlistentry> <term><option>-p <replaceable>filename</replaceable></option> <option>--pidfile <replaceable>filename</replaceable></option> </term> <listitem> <para>Write the daemon's PID to <replaceable>filename</replaceable> after daemonizing. Ignored if <option>--no-daemon</option> is passed. <replaceable>filename</replaceable> should be a fully-qualified path. </para> </listitem> </varlistentry> <varlistentry> <term> <option>-n</option> <option>--no-daemon</option> </term> <listitem> <para>Stay in foreground, don't daemonize.</para> </listitem> </varlistentry> <varlistentry> <term> <option>--no-kstat-mount</option> </term> <listitem> <para> Do not mount kstats in /zfs-kstat </para> </listitem> </varlistentry> <varlistentry> <term> <option>--disable-block-cache</option> </term> <listitem> <para> Enable direct I/O for disk operations. Completely disables caching reads and writes in the kernel block cache. Breaks mmap() in ZFS datasets too. </para> </listitem> </varlistentry> <varlistentry> <term> <option>--disable-page-cache</option> </term> <listitem> <para> Disable the page cache for files residing within ZFS filesystems. Not recommended as it slows down I/O operations considerably. </para> </listitem> </varlistentry> <varlistentry> <term> <option>-a <replaceable>SECONDS</replaceable></option> <option>--fuse-attr-timeout <replaceable>SECONDS</replaceable></option> </term> <listitem> <para> Sets timeout for caching FUSE attributes in kernel. Defaults to 0.0. Higher values give a 40% performance boost. </para> </listitem> </varlistentry> <varlistentry> <term> <option>-e <replaceable>SECONDS</replaceable></option> <option>--fuse-entry-timeout <replaceable>SECONDS</replaceable></option> </term> <listitem> <para> Sets timeout for caching FUSE entries in kernel. Defaults to 0.0. Higher values give a 10000% performance boost but cause file permission checking security issues. </para> </listitem> </varlistentry> <varlistentry> <term> <option>--log-uberblocks</option> </term> <listitem> <para> Logs uberblocks of any mounted filesystem to syslog </para> </listitem> </varlistentry> <varlistentry> <term> <option>-m <replaceable>MB</replaceable></option> <option>--max-arc-size <replaceable>MB</replaceable></option> </term> <listitem> <para> Forces the maximum ARC size (in megabytes). Range: 16 to 16384. </para> </listitem> </varlistentry> <varlistentry> <term> <option>-o <replaceable>OPT...</replaceable></option> <option>--fuse-mount-options <replaceable>OPT,OPT,OPT...</replaceable></option> </term> <listitem> <para> Sets FUSE mount options for all filesystems. Format: comma-separated string of characters. </para> </listitem> </varlistentry> <varlistentry> <term> <option>-u <replaceable>MIN</replaceable></option> <option>--min-uberblock-txg <replaceable>MIN</replaceable></option> </term> <listitem> <para> Skips uberblocks with a TXG < <replaceable>MIN</replaceable> when mounting any fs </para> </listitem> </varlistentry> <varlistentry> <term> <option>-v <replaceable>MB</replaceable></option> <option>--vdev-cache-size <replaceable>MB</replaceable></option> </term> <listitem> <para> adjust the size of the vdev cache. Default : 10 </para> </listitem> </varlistentry> <varlistentry> <term> <option>--zfs-prefetch-disable</option> </term> <listitem> <para> Disable the high level prefetch cache in zfs. This thing can eat up to 150 Mb of ram, maybe more </para> </listitem> </varlistentry> <varlistentry> <term> <option>--stack-size=<replaceable>size</replaceable></option> </term> <listitem> <para> Limit the stack <replaceable>size</replaceable> of threads (in kb). default : no limit (8 Mb for linux) </para> </listitem> </varlistentry> <varlistentry> <term> <option>-h</option> <option>--help</option> </term> <listitem> <para> Show this usage summary. </para> </listitem> </varlistentry> </variablelist> </refsect1> <refsect1> <title>REMARKS ON PRECEDENCE</title> <para>Note that the parameters passed on the command line take precedence over those supplied through /etc/zfs/zfsrc.</para> </refsect1> <refsect1> <title>BUGS/CAVEATS</title> <para>The path to the configuration file (/etc/zfs/zfsrc) cannot at this time be configured.</para> <para>Most existing packages suggest settings can be set at the top of their init script. These get frequently overridden by a (distribution specific) /etc/default/zfs-fuse file, if it exists. Be sure to look at these places if you want your changes to options to take effect.</para> <para>The /etc/zfs/zfsrc is going to be the recommended approach in the future. So, packagers, please refrain from passing commandline parameters within the initscript (except for --pid-file).</para> </refsect1> <refsect1> <title>SEE ALSO</title> <para>zfs (8), zpool (8), zdb(8), zstreamdump(8), /etc/zfs/zfsrc</para> </refsect1> <refsect1> <title>AUTHOR</title> <para>This manual page was written by &dhusername; &dhemail; for the &debian; system (but may be used by others). Permission is granted to copy, distribute and/or modify this document under the terms of the &gnu; General Public License, Version 2 any later version published by the Free Software Foundation, or the Common Development and Distribution License. </para> <para>Revised by Seth Heeren <email>zfs-fuse@sehe.nl</email></para> <para> On Debian systems, the complete text of the GNU General Public License can be found in /usr/share/common-licenses/GPL. The text of the Common Development and Distribution Licence may be found at /usr/share/doc/zfs-fuse/copyright </para> </refsect1> </refentry> ++++++ zfs-fuse.init ++++++ #!/bin/bash # ### BEGIN INIT INFO # Provides: zfs-fuse # Required-Start: $remote_fs # Required-Stop: $remote_fs # Default-Start: S # Default-Stop: 0 6 # Short-Description: ZFS FUSE # Description: Start/stops the ZFS FUSE daemon and mounts/unmounts # existing ZFS filesystems ### END INIT INFO ZFS_FUSE=/usr/sbin/zfs-fuse ZFS_FUSE_CONFIG=/etc/sysconfig/zfs-fuse ZFS_NICE_LEVEL=0 ZFS_ALLOW_RELOAD=no PIDFILE=/var/run/zfs/zfs-fuse.pid LOCKFILE=/var/lock/subsys/zfs-fuse PATH=/sbin:/bin:/usr/sbin:/usr/bin LC_ALL=C export PATH LC_ALL ulimit -v unlimited ulimit -c 512000 ulimit -l unlimited ulimit -s unlimited parse_boolean () { case $1 in [yY][eE][sS]|[tT][rR][uU][eE]) return 0 ;; [nN][oO]|[fF][aA][lL][sS][eE]) return 1 ;; *) return 2 ;; esac } function start { # start daemon startproc -l ${ZFS_NICE_LEVEL} -p "${PIDFILE}" \ ${ZFS_FUSE} --pidfile "${PIDFILE}" >/dev/null 2>&1 || return $? read -r zfs_fuse_pid < "${PIDFILE}" [[ ${zfs_fuse_pid} != "" ]] || return 1 # protect against OOM-killer printf -- "-17\n" > "/proc/${zfs_fuse_pid}/oom_adj" # mount all filesystems zfs mount -a return 0 } function stop { # check if running checkproc -k -p "${PIDFILE}" ${ZFS_FUSE} || return 0 read -r zfs_fuse_pid < "${PIDFILE}" [[ ${zfs_fuse_pid} != "" ]] || return 1 # try to unmount all filesystems if ! zfs umount -a; then # when shutting down forcibly unmount, otherwise return an error if ((RUNLEVEL == 0)) || ((RUNLEVEL == 6)); then zfs umount -a -f else return 1 fi fi # terminate zfs-fuse daemon killproc -p "${PIDFILE}" ${ZFS_FUSE} for ((i=0; i<10; i++)); do kill -0 "${zfs_fuse_pid}" >/dev/null 2>&1 || return 0 sleep 1 done return 3 } function restart { if ! parse_boolean "${ZFS_ALLOW_RELOAD}"; then return 1 fi stop || return $? start || return $? } function status { checkproc -k -p "${PIDFILE}" ${ZFS_FUSE} } if [[ ! -x ${ZFS_FUSE} ]]; then printf "zfs-fuse is not installed\n" [[ $1 == stop ]] && exit 0 || exit 5 fi if [[ ! -r ${ZFS_FUSE_CONFIG} ]]; then printf "zfs fuse is not configured, %s does not exist\n" \ "${ZFS_FUSE_CONFIG}" [[ $1 == "stop" ]] && exit 0 || exit 6 fi . "${ZFS_FUSE_CONFIG}" . /etc/rc.status rc_reset case $1 in start) printf "Starting zfs-fuse daemon" start rc_status -v ;; stop) printf "Shutting down zfs-fuse daemon" stop rc_status -v ;; try-restart) if status; then printf "Restarting zfs-fuse daemon" restart rc_status -v else exit 0 fi ;; restart|force-reload) printf "Restarting zfs-fuse daemon" restart rc_status -v ;; status) printf "Checking for zfs-fuse daemon" status rc_status -v ;; *) printf "Usage: %s {start|stop|status|try-restart|restart|force-reload}\n" "${0##*/}" exit 2 ;; esac rc_exit ++++++ zfsrc ++++++ # vdev-cache-size : size of the prefetch cache for each vdev defined # so if you are using 2 pools defined in 2 devices, you'll get 2 vdev caches # default size : 10, you can set it to 0 to disable it if you wish vdev-cache-size = 10 # Maximum arc size : this is the main cache for zfs in Mb # default size : 128 Mb, minimum size : 16 Mb # Notice that arc is also used for the hash tables if you use the dedup option max-arc-size = 100 # zfs-prefetch-disable : disable zfs high level prefetch cache. # This setting can eat as much as 150 Mb of ram, so uncomment if you want # to save some ram and are ready to loose a little speed. zfs-prefetch-disable # disable-block-cache : uncomment this to enable direct i/o and disable the # kernel block cache. It's not adviced to do this unless you want to test # something specific about ARC. # disable-block-cache # disable-page-cache : uncomment this to disable fuse page cache. # This cache allows fuse to cache high level read requests # there is no reason to disable it usually, except for testing. # disable-page-cache # fuse-*-timeout : sets timeout for caching fuse attributes in kernel (in # seconds) # These 2 values have a big impact on performance for small io operations # There are 3 possibilities : # 1) if you use fuese-mount-options=default_permissions then you can set these # 2 as high as you want (that's the case here). It's probably the best option # 2) Otherwise if you still want to keep posix file permissions without loosing # too much speed, set these 2 to at least 1s. # 3) Last case : you want perfect posix conformance, wihtout default_permissions # in this case set these to 0, but be ready to loose quite some speed ! # Default is to use default_permissions, so these as high as you want. fuse-attr-timeout = 3600 fuse-entry-timeout = 3600 # fuse-mount-options : supplemental fuse mount options for the zfs volumes. # fuse mount options which are always passed include : # allow_other,suid,dev # and big_writes if you are using fuse >= 2.8. # Now default_permissions has a special handling and is adviced as a default option. fuse-mount-options = default_permissions # stack-size : # zfs-fuse uses lots of threads (about 150), and the default stack size for # a thread is 8 Mb. This affects only the virtual memory usage, not the real # memory, but it's still an impressive number for some unused ram. # So you can limit it here, in kb. Default is no limit # stack-size = 32 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Remember to have fun... -- To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-commit+help@opensuse.org
participants (1)
-
root@hilbert.suse.de