Date: Sun, 28 Aug 2011 00:26:26 -0700 From: Trent Nelson <trent@snakebite.org> To: "fs@freebsd.org" <fs@freebsd.org> Subject: How do you zfs rename a dataset that has children? Message-ID: <5B89610A-4D16-422A-9E52-F182CAF76D68@snakebite.org>
index | next in thread | raw e-mail
This has me scratching my head: [root@usbkey/ttypts/0(~)#] zfs create tank/host/foo [root@usbkey/ttypts/0(~)#] zfs create tank/host/foo/bar [root@usbkey/ttypts/0(~)#] zfs rename tank/host/foo tank/host/test Assertion failed: (!clp->cl_alldependents), file /usr/src/cddl/lib/libzfs/../../../cddl/contrib/opensolaris/lib/libzfs/common/libzfs_changelist.c, line 470. zsh: abort (core dumped) zfs rename tank/host/foo tank/host/test Say wha'? Renaming the child dataset first works, but it's not what I want, obviously: [root@usbkey/ttypts/0(~)#] zfs rename tank/host/foo/bar tank/host/test/bar cannot create 'tank/host/test/bar': parent does not exist [root@usbkey/ttypts/0(~)#] zfs rename -p tank/host/foo/bar tank/host/test/bar [root@usbkey/ttypts/0(~)#] zfs rename tank/host/foo tank/host/test/bar cannot rename 'tank/host/foo': dataset already exists [root@usbkey/ttypts/0(~)#] uname -a FreeBSD usbkey.home.trent.me 8.2-STABLE FreeBSD 8.2-STABLE #2 r224667M: Sat Aug 6 04:11:46 EDT 2011 root@home.trent.me:/usr/obj/usr/src/sys/GENERIC amd64 (The 'M' in r224667M is due to a device ID I changed in e1000.h; unrelated to this issue.) What am I doing wrong? (My actual use case is more complicated than the test case above; I built a new system, named 'fulcrum', from an existing build, named 'flanker'. I want to rename tank/host/flanker -> tank/host/fulcrum (hence booting from the usbkey).) Regards, Trent.help
Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?5B89610A-4D16-422A-9E52-F182CAF76D68>
