From owner-freebsd-fs@FreeBSD.ORG Thu Nov 14 19:30:42 2013 Return-Path: Delivered-To: freebsd-fs@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 883EE4C2 for ; Thu, 14 Nov 2013 19:30:42 +0000 (UTC) Received: from mail1.multiplay.co.uk (mail1.multiplay.co.uk [85.236.96.23]) (using TLSv1 with cipher RC4-MD5 (128/128 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 2846E27C3 for ; Thu, 14 Nov 2013 19:30:41 +0000 (UTC) Received: from r2d2 ([82.69.141.170]) by mail1.multiplay.co.uk (mail1.multiplay.co.uk [85.236.96.23]) (MDaemon PRO v10.0.4) with ESMTP id md50006719847.msg for ; Thu, 14 Nov 2013 19:30:39 +0000 X-Spam-Processed: mail1.multiplay.co.uk, Thu, 14 Nov 2013 19:30:39 +0000 (not processed: message from valid local sender) X-MDDKIM-Result: neutral (mail1.multiplay.co.uk) X-MDRemoteIP: 82.69.141.170 X-Return-Path: prvs=10308a6844=killing@multiplay.co.uk X-Envelope-From: killing@multiplay.co.uk X-MDaemon-Deliver-To: freebsd-fs@freebsd.org Message-ID: <333D57C6A4544067880D9CFC04F02312@multiplay.co.uk> From: "Steven Hartland" To: "Steven Hartland" , "Matt Magoffin" , References: <0C9FD4E1-0549-4849-BFC5-D8C5D4A34D64@msqr.us> <54D3B3C002184A52BEC9B1543854B87F@multiplay.co.uk> Subject: Re: ZFS snapshot renames failing after upgrade to 9.2 Date: Thu, 14 Nov 2013 19:30:33 -0000 MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset="iso-8859-1"; reply-type=response Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2900.5931 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.6157 X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 14 Nov 2013 19:30:42 -0000 This could also be due to the following issue which there will be a fix soon: https://www.illumos.org/issues/4322 Regards Steve ----- Original Message ----- From: "Steven Hartland" To: "Matt Magoffin" ; Sent: Thursday, November 14, 2013 6:43 PM Subject: Re: ZFS snapshot renames failing after upgrade to 9.2 > Sounds like you may have an automatic hold still present. > > What does the following report: > zfs holds -r > > Regards > Steve > ----- Original Message ----- > From: "Matt Magoffin" > To: > Sent: Thursday, November 14, 2013 6:35 PM > Subject: ZFS snapshot renames failing after upgrade to 9.2 > > > Hello, > > I have a system that had been running FreeBSD 9.1 for some time, and I recently upgraded to 9.2. I've been using this simple > script to create daily, rotating ZFS snapshots via cron: > > http://andyleonard.com/2010/04/07/automatic-zfs-snapshot-rotation-on-freebsd/ > > Essentially the snapshots are renamed and then a new snapshot is created with the same name as the most recently created > snapshot. Since the upgrade to 9.2, however, the snapshots aren't able to be renamed. I end up with an error like this: > > cannot rename 'zdata/home': a child dataset already has a snapshot with the new name > cannot create snapshot 'zdata/home@daily.0': dataset already exists > > Once that happens, zfs will show two snapshots: > > # zfs list -t snapshot -o name,creation,used,referenced |grep zdata/home > zdata/home@daily.1 Wed Nov 13 0:00 2013 50.5K 91.0G > zdata/home@daily.0 Thu Nov 14 0:00 2013 0 91.0G > > However, trying to list the snapshots results in this error: > > # ls .zfs/snapshot/ > ls: daily.1: Device busy > daily.0 > > I can destroy the daily.1 snapshot: > > # zfs destroy zdata/home@daily.1 > # zfs list -t snapshot -o name,creation,used,referenced |grep zdata/home > zdata/home@daily.0 Thu Nov 14 0:00 2013 0 91.0G > # ls .zfs/snapshot/ > daily.0 > > Then if I try to rename it like the script would, I end up in the same "Device busy" state: > > # zfs rename zdata/home@daily.0 zdata/home@daily.1 > # zfs list -t snapshot -o name,creation,used,referenced |grep zdata/home > zdata/home@daily.1 Thu Nov 14 0:00 2013 0 91.0G > # ls .zfs/snapshot/ > ls: daily.1: Device busy > > Does anyone have any ideas how to get the renames working? > > -- m@ > > > > ================================================ > This e.mail is private and confidential between Multiplay (UK) Ltd. and the person or entity to whom it is addressed. In the > event of misdirection, the recipient is prohibited from using, copying, printing or otherwise disseminating it or any > information contained in it. > In the event of misdirection, illegible or incomplete transmission please telephone +44 845 868 1337 > or return the E.mail to postmaster@multiplay.co.uk. > > _______________________________________________ > freebsd-fs@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-fs > To unsubscribe, send any mail to "freebsd-fs-unsubscribe@freebsd.org" > ================================================ This e.mail is private and confidential between Multiplay (UK) Ltd. and the person or entity to whom it is addressed. In the event of misdirection, the recipient is prohibited from using, copying, printing or otherwise disseminating it or any information contained in it. In the event of misdirection, illegible or incomplete transmission please telephone +44 845 868 1337 or return the E.mail to postmaster@multiplay.co.uk.