Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 3 Nov 2020 10:02:53 +0000 (UTC)
From:      Mateusz Piotrowski <0mp@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r367291 - head/libexec/rc/rc.d
Message-ID:  <202011031002.0A3A2rVo070445@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: 0mp (doc,ports committer)
Date: Tue Nov  3 10:02:52 2020
New Revision: 367291
URL: https://svnweb.freebsd.org/changeset/base/367291

Log:
  rc.d/zfs: Add shutdown to KEYWORDS
  
  The problem is that Without walling /etc/rc.d/zfs on shutdown, resources
  associated with ZFS mounts are not freed and the jails will remain in dying
  state. In addition, the dataset is now in a dangling state, as the jail it
  is attached to is dying.
  
  A known workaround for jails was to add the following lines
  to /etc/jail.conf, to make sure that "service zfs stop" is run
  when the jail is stopped:
  
      exec.stop = "/bin/sh /etc/rc.shutdown";
      exec.stop += "/usr/sbin/service zfs stop || /usr/bin/true";
  
  While the workaround seems to be okay-ish for the jail situation, it is
  still unclean. However, for physical hosts this may wreak havoc with the
  pool if shared spares are used, as "zfs unshare" is never invoked on
  shutdown.
  
  PR:		147444
  Submitted by:	Markus Stoff <markus__stoffdv_at>
  Reported by:	Mykah <mburkhardt__exavault_com>
  Reviewed by:	cy
  Approved by:	cy (src)
  MFC after:	1 week
  Relnotes:	yes
  Differential Revision:	https://reviews.freebsd.org/D27039

Modified:
  head/libexec/rc/rc.d/zfs

Modified: head/libexec/rc/rc.d/zfs
==============================================================================
--- head/libexec/rc/rc.d/zfs	Tue Nov  3 02:10:54 2020	(r367290)
+++ head/libexec/rc/rc.d/zfs	Tue Nov  3 10:02:52 2020	(r367291)
@@ -6,6 +6,7 @@
 # PROVIDE: zfs
 # REQUIRE: zfsbe
 # BEFORE: FILESYSTEMS var
+# KEYWORD: shutdown
 
 . /etc/rc.subr
 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202011031002.0A3A2rVo070445>