From owner-freebsd-fs@FreeBSD.ORG Thu Nov 14 18:43:30 2013 Return-Path: Delivered-To: freebsd-fs@freebsd.org 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 C0640D7 for ; Thu, 14 Nov 2013 18:43:30 +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 609AC246C for ; Thu, 14 Nov 2013 18:43:30 +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 md50006719423.msg for ; Thu, 14 Nov 2013 18:43:27 +0000 X-Spam-Processed: mail1.multiplay.co.uk, Thu, 14 Nov 2013 18:43:27 +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: <54D3B3C002184A52BEC9B1543854B87F@multiplay.co.uk> From: "Steven Hartland" To: "Matt Magoffin" , References: <0C9FD4E1-0549-4849-BFC5-D8C5D4A34D64@msqr.us> Subject: Re: ZFS snapshot renames failing after upgrade to 9.2 Date: Thu, 14 Nov 2013 18:43:25 -0000 MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset="Windows-1252"; reply-type=original 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 18:43:30 -0000 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.