From owner-freebsd-ports-bugs@FreeBSD.ORG Sat Apr 19 11:30:02 2008 Return-Path: Delivered-To: freebsd-ports-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 44013106566C for ; Sat, 19 Apr 2008 11:30:02 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 2045D8FC25 for ; Sat, 19 Apr 2008 11:30:02 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.14.2/8.14.2) with ESMTP id m3JBU2b2068442 for ; Sat, 19 Apr 2008 11:30:02 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.2/8.14.1/Submit) id m3JBU1Ju068441; Sat, 19 Apr 2008 11:30:01 GMT (envelope-from gnats) Resent-Date: Sat, 19 Apr 2008 11:30:01 GMT Resent-Message-Id: <200804191130.m3JBU1Ju068441@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-ports-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Dominic Fandrey Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8C6BF106566C for ; Sat, 19 Apr 2008 11:23:47 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21]) by mx1.freebsd.org (Postfix) with ESMTP id 7B5AB8FC21 for ; Sat, 19 Apr 2008 11:23:47 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (localhost [127.0.0.1]) by www.freebsd.org (8.14.2/8.14.2) with ESMTP id m3JBNVwL098563 for ; Sat, 19 Apr 2008 11:23:31 GMT (envelope-from nobody@www.freebsd.org) Received: (from nobody@localhost) by www.freebsd.org (8.14.2/8.14.1/Submit) id m3JBNVw3098534; Sat, 19 Apr 2008 11:23:31 GMT (envelope-from nobody) Message-Id: <200804191123.m3JBNVw3098534@www.freebsd.org> Date: Sat, 19 Apr 2008 11:23:31 GMT From: Dominic Fandrey To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Cc: Subject: ports/122907: [patch] sysutils/fusefs-kmod dataloss on write shortly (e.g. 15 minutes) before shutdown X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 19 Apr 2008 11:30:02 -0000 >Number: 122907 >Category: ports >Synopsis: [patch] sysutils/fusefs-kmod dataloss on write shortly (e.g. 15 minutes) before shutdown >Confidential: no >Severity: serious >Priority: medium >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Sat Apr 19 11:30:01 UTC 2008 >Closed-Date: >Last-Modified: >Originator: Dominic Fandrey >Release: RELENG_7 >Organization: private >Environment: FreeBSD mobileKamikaze.norad 7.0-STABLE FreeBSD 7.0-STABLE #0: Sat Apr 19 01:05:43 CEST 2008 root@mobileKamikaze.norad:/usr/obj/HP6510b/amd64/usr/src/sys/HP6510b amd64 >Description: Fusefs mounts can loose data written shortly before shutdown and cause file system corruption. The problem is that the cache gets written back when the systems are unmounted. But the short timespan between stopping and thus unmounting and the system reset/powerdown often does not suffice to write all data back. This will change the rc script so that it hangs around until all data has safely been written back. It can still be shot by the watchdog, but it greatly reduces the risk of data corruption. >How-To-Repeat: Use fusefs-ntfs or something similar, write some data (~100M split into a couple of files should do) to a mount and immediately run 'shutdown -p now'. The data will be (partly) missing upon the next boot. >Fix: --- ports/sysutils/fusefs-kmod/files/fusefs.in.orig 2008-04-19 13:08:43.000000000 +0200 +++ ports/sysutils/fusefs-kmod/files/fusefs.in 2008-04-19 13:09:51.000000000 +0200 @@ -50,7 +50,9 @@ ;; esac done - kldunload $kmod + until kldunload $kmod; do + /bin/sleep 0.25 + done } load_rc_config $name >Release-Note: >Audit-Trail: >Unformatted: