From nobody@FreeBSD.org  Mon Jan 14 22:49:15 2013
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1])
	by hub.freebsd.org (Postfix) with ESMTP id 624B0D2A
	for <freebsd-gnats-submit@FreeBSD.org>; Mon, 14 Jan 2013 22:49:15 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from red.freebsd.org (red.freebsd.org [IPv6:2001:4f8:fff6::22])
	by mx1.freebsd.org (Postfix) with ESMTP id 5245B129
	for <freebsd-gnats-submit@FreeBSD.org>; Mon, 14 Jan 2013 22:49:15 +0000 (UTC)
Received: from red.freebsd.org (localhost [127.0.0.1])
	by red.freebsd.org (8.14.5/8.14.5) with ESMTP id r0EMnEMc026884
	for <freebsd-gnats-submit@FreeBSD.org>; Mon, 14 Jan 2013 22:49:14 GMT
	(envelope-from nobody@red.freebsd.org)
Received: (from nobody@localhost)
	by red.freebsd.org (8.14.5/8.14.5/Submit) id r0EMnE28026883;
	Mon, 14 Jan 2013 22:49:14 GMT
	(envelope-from nobody)
Message-Id: <201301142249.r0EMnE28026883@red.freebsd.org>
Date: Mon, 14 Jan 2013 22:49:14 GMT
From: Garrett Cooper <yaneurabeya@gmail.com>
To: freebsd-gnats-submit@FreeBSD.org
Subject: [patch] add "dump" fs type support to rc.d/dumpon
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         175311
>Category:       conf
>Synopsis:       [patch] add "dump" fs type support to rc.d/dumpon
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-rc
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Mon Jan 14 22:50:00 UTC 2013
>Closed-Date:    
>Last-Modified:  Sun Feb 03 22:32:04 UTC 2013
>Originator:     Garrett Cooper
>Release:        10-CURRENT
>Organization:
EMC Isilon
>Environment:
FreeBSD gran-tourismo.west.isilon.com 10.0-CURRENT FreeBSD 10.0-CURRENT #1 r+294c6eb: Fri Jan  4 07:38:46 PST 2013     root@gran-tourismo.west.isilon.com:/usr/obj/usr/src/sys/GRAN-TOURISMO  amd64
>Description:
savecore(8) notes that you can use dump for the FS type, but dumpon only supports swap for the FS type. The attached patch enhances both FS types to work with dumpon + savecore.
>How-To-Repeat:

>Fix:


Patch attached with submission follows:

From 16921efded40ef4c7800f07157f0e52be4cf8121 Mon Sep 17 00:00:00 2001
From: Garrett Cooper <yaneurabeya@gmail.com>
Date: Mon, 14 Jan 2013 14:39:59 -0800
Subject: [PATCH] Support the pseudo fs_vfstype == "dump" noted in savecore(8)

Signed-off-by: Garrett Cooper <yaneurabeya@gmail.com>
---
 etc/rc.d/dumpon | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/etc/rc.d/dumpon b/etc/rc.d/dumpon
index ce5fc1c..981ff84 100755
--- a/etc/rc.d/dumpon
+++ b/etc/rc.d/dumpon
@@ -40,7 +40,12 @@ dumpon_start()
 			return $?
 		fi
 		while read dev mp type more ; do
-			[ "${type}" = "swap" ] || continue
+			case "$type" in
+			dump|swap)
+				;;
+			*)
+				continue;;
+			esac
 			[ -c "${dev}" ] || continue
 			dumpon_try "${dev}" 2>/dev/null && return 0
 		done </etc/fstab
-- 
1.8.0.2



>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-bugs->freebsd-rc 
Responsible-Changed-By: linimon 
Responsible-Changed-When: Tue Jan 15 04:14:28 UTC 2013 
Responsible-Changed-Why:  
Over to maintainer(s). 

http://www.freebsd.org/cgi/query-pr.cgi?pr=175311 

From: Xin Li <delphij@delphij.net>
To: Garrett Cooper <yaneurabeya@gmail.com>
Cc: freebsd-gnats-submit@FreeBSD.org
Subject: Re: conf/175311: [patch] add "dump" fs type support to rc.d/dumpon
Date: Fri, 18 Jan 2013 16:43:08 -0800

 -----BEGIN PGP SIGNED MESSAGE-----
 Hash: SHA512
 
 On 01/14/13 14:49, Garrett Cooper wrote:
 > 
 >> Number:         175311 Category:       conf Synopsis:
 >> [patch] add "dump" fs type support to rc.d/dumpon Confidential:
 >> no Severity:       non-critical Priority:       low Responsible:
 >> freebsd-bugs State:          open Quarter: Keywords: 
 >> Date-Required: Class:          sw-bug Submitter-Id:
 >> current-users Arrival-Date:   Mon Jan 14 22:50:00 UTC 2013 
 >> Closed-Date: Last-Modified: Originator:     Garrett Cooper 
 >> Release:        10-CURRENT Organization:
 > EMC Isilon
 >> Environment:
 > FreeBSD gran-tourismo.west.isilon.com 10.0-CURRENT FreeBSD
 > 10.0-CURRENT #1 r+294c6eb: Fri Jan  4 07:38:46 PST 2013
 > root@gran-tourismo.west.isilon.com:/usr/obj/usr/src/sys/GRAN-TOURISMO
 > amd64
 >> Description:
 > savecore(8) notes that you can use dump for the FS type, but dumpon
 > only supports swap for the FS type. The attached patch enhances
 > both FS types to work with dumpon + savecore.
 >> How-To-Repeat:
 > 
 >> Fix:
 > 
 > 
 > Patch attached with submission follows:
 > 
 > From 16921efded40ef4c7800f07157f0e52be4cf8121 Mon Sep 17 00:00:00
 > 2001 From: Garrett Cooper <yaneurabeya@gmail.com> Date: Mon, 14 Jan
 > 2013 14:39:59 -0800 Subject: [PATCH] Support the pseudo fs_vfstype
 > == "dump" noted in savecore(8)
 > 
 > Signed-off-by: Garrett Cooper <yaneurabeya@gmail.com> --- 
 > etc/rc.d/dumpon | 7 ++++++- 1 file changed, 6 insertions(+), 1
 > deletion(-)
 > 
 > diff --git a/etc/rc.d/dumpon b/etc/rc.d/dumpon index
 > ce5fc1c..981ff84 100755 --- a/etc/rc.d/dumpon +++
 > b/etc/rc.d/dumpon @@ -40,7 +40,12 @@ dumpon_start() return $? fi 
 > while read dev mp type more ; do -			[ "${type}" = "swap" ] ||
 > continue +			case "$type" in +			dump|swap) +				;; +			*) +
 > continue;; +			esac
 
 Why not just:
 
 [ "${type}" = "swap" -o  "${type}" = "dump" ] || continue?
 
 - -- 
 Xin LI <delphij@delphij.net>    https://www.delphij.net/
 FreeBSD - The Power to Serve!           Live free or die
 -----BEGIN PGP SIGNATURE-----
 
 iQEcBAEBCgAGBQJQ+ewcAAoJEG80Jeu8UPuzD40IAKe2N2o8ZVNODj65hXWWgiZa
 BlTyog+MUxr9FwQQMelaZqUz7jywuyLFWeiFZcBohmOonthKIwX8saUyozphW6nc
 jqpfKiZcywN6EaQfNucSsF55QdO2ndqCsXCDu+e4iyYK3KdTnc38gz+YbfzJOdxZ
 Y2W7QNNKIBINXngFyRdvhOk2W+okEcbsu7tMxzp8tYu+bDQLWNHo7183gKjjnqeX
 md/xhyHiFrRB48fZQ1+voAisnarI7ElKVNZVDwKBPzzsaNUsF56L+jmoQ2sqlhZF
 oAThcW1tC9AMDlR8RWWmvWDwoDjeubKNOPr/3Yl+z2vsmeSIEf/7IIjidNILfzM=
 =6mng
 -----END PGP SIGNATURE-----

From: Garrett Cooper <yaneurabeya@gmail.com>
To: d@delphij.net
Cc: freebsd-gnats-submit@FreeBSD.org
Subject: Re: conf/175311: [patch] add "dump" fs type support to rc.d/dumpon
Date: Fri, 18 Jan 2013 16:47:44 -0800

 On Jan 18, 2013, at 4:43 PM, Xin Li wrote:
 
 > -----BEGIN PGP SIGNED MESSAGE-----
 > Hash: SHA512
 > 
 > On 01/14/13 14:49, Garrett Cooper wrote:
 >> 
 >>> Number:         175311 Category:       conf Synopsis:
 >>> [patch] add "dump" fs type support to rc.d/dumpon Confidential:
 >>> no Severity:       non-critical Priority:       low Responsible:
 >>> freebsd-bugs State:          open Quarter: Keywords: 
 >>> Date-Required: Class:          sw-bug Submitter-Id:
 >>> current-users Arrival-Date:   Mon Jan 14 22:50:00 UTC 2013 
 >>> Closed-Date: Last-Modified: Originator:     Garrett Cooper 
 >>> Release:        10-CURRENT Organization:
 >> EMC Isilon
 >>> Environment:
 >> FreeBSD gran-tourismo.west.isilon.com 10.0-CURRENT FreeBSD
 >> 10.0-CURRENT #1 r+294c6eb: Fri Jan  4 07:38:46 PST 2013
 >> root@gran-tourismo.west.isilon.com:/usr/obj/usr/src/sys/GRAN-TOURISMO
 >> amd64
 >>> Description:
 >> savecore(8) notes that you can use dump for the FS type, but dumpon
 >> only supports swap for the FS type. The attached patch enhances
 >> both FS types to work with dumpon + savecore.
 >>> How-To-Repeat:
 >> 
 >>> Fix:
 >> 
 >> 
 >> Patch attached with submission follows:
 >> 
 >> From 16921efded40ef4c7800f07157f0e52be4cf8121 Mon Sep 17 00:00:00
 >> 2001 From: Garrett Cooper <yaneurabeya@gmail.com> Date: Mon, 14 Jan
 >> 2013 14:39:59 -0800 Subject: [PATCH] Support the pseudo fs_vfstype
 >> == "dump" noted in savecore(8)
 >> 
 >> Signed-off-by: Garrett Cooper <yaneurabeya@gmail.com> --- 
 >> etc/rc.d/dumpon | 7 ++++++- 1 file changed, 6 insertions(+), 1
 >> deletion(-)
 >> 
 >> diff --git a/etc/rc.d/dumpon b/etc/rc.d/dumpon index
 >> ce5fc1c..981ff84 100755 --- a/etc/rc.d/dumpon +++
 >> b/etc/rc.d/dumpon @@ -40,7 +40,12 @@ dumpon_start() return $? fi 
 >> while read dev mp type more ; do -			[ "${type}" = "swap" ] ||
 >> continue +			case "$type" in +			dump|swap) +				;; +			*) +
 >> continue;; +			esac
 > 
 > Why not just:
 > 
 > [ "${type}" = "swap" -o  "${type}" = "dump" ] || continue?
 
 That's valid too -- didn't realize it had been converted to a built-in:
 
 $ type [ 
 [ is a shell builtin
 
 Thanks!
 -Garrett
>Unformatted:
