From idefix@fechner.net  Tue Mar 25 08:34:31 2014
Return-Path: <idefix@fechner.net>
Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115])
	(using TLSv1 with cipher ADH-AES256-SHA (256/256 bits))
	(No client certificate requested)
	by hub.freebsd.org (Postfix) with ESMTPS id 936F6E44
	for <FreeBSD-gnats-submit@freebsd.org>; Tue, 25 Mar 2014 08:34:31 +0000 (UTC)
Received: from anny.lostinspace.de (anny.lostinspace.de [IPv6:2a01:138:a006::2])
	(using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits))
	(No client certificate requested)
	by mx1.freebsd.org (Postfix) with ESMTPS id 2562FB05
	for <FreeBSD-gnats-submit@freebsd.org>; Tue, 25 Mar 2014 08:34:30 +0000 (UTC)
Received: from server.idefix.lan (ppp-93-104-90-241.dynamic.mnet-online.de [93.104.90.241])
	(authenticated bits=0)
	by anny.lostinspace.de (8.14.7/8.14.7) with ESMTP id s2P8YM4L082939
	(version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO)
	for <FreeBSD-gnats-submit@freebsd.org>; Tue, 25 Mar 2014 09:34:26 +0100 (CET)
	(envelope-from idefix@fechner.net)
Received: by server.idefix.lan (Postfix, from userid 1001)
	id 0BB4270B93; Tue, 25 Mar 2014 09:34:22 +0100 (CET)
Message-Id: <20140325083422.0BB4270B93@server.idefix.lan>
Date: Tue, 25 Mar 2014 09:34:22 +0100 (CET)
From: Matthias Fechner <idefix@fechner.net>
Reply-To: Matthias Fechner <idefix@fechner.net>
To: FreeBSD-gnats-submit@freebsd.org
Cc:
Subject: zfs-snapshot-mgmt-20090201_2 stopped working with FreeBSD10
X-Send-Pr-Version: 3.114
X-GNATS-Notify:

>Number:         187922
>Category:       ports
>Synopsis:       sysutils/zfs-snapshot-mgmt 20090201_2 stopped working with FreeBSD10
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Tue Mar 25 08:40:00 UTC 2014
>Closed-Date:    
>Last-Modified:  Tue Apr 29 23:30:00 UTC 2014
>Originator:     Matthias Fechner
>Release:        FreeBSD 10.0-STABLE amd64
>Organization:
>Environment:
System: FreeBSD server.idefix.lan 10.0-STABLE FreeBSD 10.0-STABLE #11 r263665: Sun Mar 23 21:08:06 CET 2014 root@server.idefix.lan:/usr/obj/usr/src/sys/GENERIC amd64


>Description:
	The zfs-snapshot tool is called from crontab every five minutes:
        */5 * * * *   root   /usr/local/bin/zfs-snapshot-mgmt
        Every call causes the error message:
        /usr/local/bin/zfs-snapshot-mgmt:130:in `join': can't convert nil into String (TypeError)
	from /usr/local/bin/zfs-snapshot-mgmt:130:in `snapshots'
	from /usr/local/bin/zfs-snapshot-mgmt:137:in `snapshots_to_remove'
	from /usr/local/bin/zfs-snapshot-mgmt:145:in `remove_snapshots'
	from /usr/local/bin/zfs-snapshot-mgmt:213:in `block in <main>'
	from /usr/local/bin/zfs-snapshot-mgmt:210:in `each'
	from /usr/local/bin/zfs-snapshot-mgmt:210:in `<main>'

>How-To-Repeat:
	Just install on FreeBSD 10-stable or release and wait till it is called from crontab or execute it manually with:
        /usr/local/bin/zfs-snapshot-mgmt

>Fix:



>Release-Note:
>Audit-Trail:

From: Mark Martinec <Mark.Martinec@ijs.si>
To: bug-followup@FreeBSD.org, idefix@fechner.net
Cc:  
Subject: Re: ports/187922: sysutils/zfs-snapshot-mgmt
 =?UTF-8?Q?=32=30=30=39=30=32=30=31=5F=32=20stopped=20working=20with=20Fre?=
 =?UTF-8?Q?eBSD=31=30?=
Date: Wed, 30 Apr 2014 01:22:22 +0200

 > /usr/local/bin/zfs-snapshot-mgmt:130:in `join':
 >    can't convert nil into String (TypeError)
 
 This happens when a ZFS file system has no mountpoint.
 
 In case of a bsdinstall-ed FreeBSD-10 such filesystems are
 the top filesystem and a top/ROOT below it (both are empty).
 It is only the top/ROOT/default which has its mountpoint '/'.
 
 The zfs-snapshot-mgmt should not bail out on filesystems
 with no mountpoints, or at least it should issue a
 sensible error message.
 
 Currently a workaround is to either supply some dummy
 mountpoints for such filesystems, or avoid specifying
 in the zfs-snapshot-mgmt.conf the top file system
 (hoping the "recursive: true" would deal with the rest),
 but only list each mounted filesystem individually.
 
>Unformatted:
