]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Revert r367291 (KEYWORD: shutdown for rc.d/zfs)
authorMateusz Piotrowski <0mp@FreeBSD.org>
Fri, 20 Nov 2020 14:37:07 +0000 (14:37 +0000)
committerMateusz Piotrowski <0mp@FreeBSD.org>
Fri, 20 Nov 2020 14:37:07 +0000 (14:37 +0000)
commite5912dcf20718573bdb694b085d1cf3bc10a2eb5
treec3bc9515d84b5164558c6945659faf275a1ac22b
parent77602e977e0c6d1d8cd6e1e2b5fc7c1be95b79aa
Revert r367291 (KEYWORD: shutdown for rc.d/zfs)

The problem is that zfs is asked to stop too early in the shutdown
sequence. Other services, such as syslog may still be running and have some
files open (e.g., under /var/log). This of course causes the messages like:

  cannot unmount '/var/run': umount failed
  cannot unmount '/var/log': umount failed
  cannot unmount '/var': umount failed
  cannot unmount '/usr/home': umount failed
  cannot unmount '/usr': umount failed
  cannot unmount '/': umount failed

For now, let's remove the shutdown KEYWORD from the zfs service, as people are
reporting problems in their setups:
https://lists.freebsd.org/pipermail/freebsd-current/2020-November/077559.html

In the future, we may think of stopping zfs on shutdown after all the other
services and just before init(8) exits. Another interesting option might be to
a new rcorder(8) KEYWORD like "shutdownjail", but this idea would need to be
discussed a bit.

Reported by: Johan Hendriks <joh.hendriks gmail.com>
Reported by: Yasuhiro KIMURA <yasu utahime.org>
Reported by: Tomoaki AOKI <junchoon dec.sakura.ne.jp>
Approved by: kevans (src)
MFC: 3 days
Differential Revision: https://reviews.freebsd.org/D27263
libexec/rc/rc.d/zfs