Re: [zfs-discuss] Oops, ran zfs destroy after renaming a folder and deleted my file system.

2010-02-25 Thread Kjetil Torgrim Homme
tomwaters tomwat...@chadmail.com writes:

 I created a zfs file system, cloud/movies and shared it.
 I then filled it with movies and music.
 I then decided to rename it, so I used rename in the Gnome to change
 the folder name to media...ie cloud/media.  MISTAKE
 I then noticed the zfs share was pointing to /cloud/movies which no
 longer exists.

I think you should file a bug against Nautilus (the GNOME file manager).
When you rename a directory, it should check for it being a mountpoint
and warn appropriately.  (adding ZFS specific code to DTRT is perhaps
asking for a bit too much.)  evidently it got an error for the rename(2)
and instead started to copy/delete the original.  *inside* some
filesystems, this is probably correct behaviour, but when the object is
a filesystem, I don't think anyone want this behaviour.  if they want to
move data off the filesystem, they should go inside, mark all files, and
drag (or ^X ^V) the files wherever they should go.

 So, I removed cloud/movies with zfs destroy --- BIGGER MISTAKE

I see the reasoning behind this, but as you've learnt the hard way:
always double-check before using zfs destroy.

-- 
Kjetil T. Homme
Redpill Linpro AS - Changing the game

___
zfs-discuss mailing list
zfs-discuss@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss


Re: [zfs-discuss] Oops, ran zfs destroy after renaming a folder and deleted my file system.

2010-02-25 Thread tomwaters
Yes, I am glad that I learned this lesson now, rather than in 6 months when I 
have re-purposed the exiting drives...makes me all the more committed to 
maintaining an up to date remote backup.

The reality is that I can not afford to mirror the 8TB in the zpool, so I'll 
balance the risk and just backup the important items like music, document and 
photo's.

ISO's and DVD's I can always recreate.

Thanks guys for the support. I'll do alot more reading on ZFS/datasets etc. 
befor I mess with the server again!...hmmm, actually, I just had a thought, I 
will also create a playpool when I can try out things before using them on the 
main pool.
-- 
This message posted from opensolaris.org
___
zfs-discuss mailing list
zfs-discuss@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss


Re: [zfs-discuss] Oops, ran zfs destroy after renaming a folder and deleted my file system.

2010-02-25 Thread Francois Dion
On Thu, Feb 25, 2010 at 6:59 AM, tomwaters tomwat...@chadmail.com wrote:
 Yes, I am glad that I learned this lesson now, rather than in 6 months when I 
 have re-purposed the exiting drives...makes me all the more committed to 
 maintaining an up to date remote backup.

 The reality is that I can not afford to mirror the 8TB in the zpool, so I'll 
 balance the risk and just backup the important items like music, document and 
 photo's.

 ISO's and DVD's I can always recreate.

 Thanks guys for the support. I'll do alot more reading on ZFS/datasets etc. 
 befor I mess with the server again!...hmmm, actually, I just had a thought, I 
 will also create a playpool when I can try out things before using them on 
 the main pool.

In that regard, you can use a file based zpool, no need to slice your
disks that way.

Francois
___
zfs-discuss mailing list
zfs-discuss@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss


Re: [zfs-discuss] Oops, ran zfs destroy after renaming a folder and deleted my file system.

2010-02-24 Thread Ed Jobs
On Thursday 25 of February 2010 03:46, tomwaters wrote:
 Ok, I know NOW that I should have used zfs rename...but just for the
 record, and to give you folks a laugh, this is the mistake I made...
 
 I created a zfs file system, cloud/movies and shared it.
 I then filled it with movies and music.
 I then decided to rename it, so I used rename in the Gnome to change the
 folder name to media...ie cloud/media.  MISTAKE I then noticed the
 zfs share was pointing to /cloud/movies which no longer exists. So, I
 removed cloud/movies with zfs destroy --- BIGGER MISTAKE
 
 So, now I am restoring my media from backup.

just for the record:
did you want to rename the mountpoint or the dataset?

-- 
Real programmers don't document. If it was hard to write, it should be hard to 
understand.


signature.asc
Description: This is a digitally signed message part.
___
zfs-discuss mailing list
zfs-discuss@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss


Re: [zfs-discuss] Oops, ran zfs destroy after renaming a folder and deleted my file system.

2010-02-24 Thread tomwaters
well, both I guess...

I thought the dataset name was based upon the file system...so I was assuming 
that if i renamed the zfs filesystem (with zfs rename) it would also rename the 
dataset...

ie...
#zfs create tank/fred
gives...
NAMEUSED  AVAIL  REFER  MOUNTPOINT 
tank/fred   26.0K  4.81G  10.0K  /tank/fred

 and then 
#zfs rename tank/fred tank/mary
will give...
NAMEUSED  AVAIL  REFER  MOUNTPOINT 
tank/mary   26.0K  4.81G  10.0K  /tank/mary

It's all rather confusing to a newbit like me I must admit...so please post 
examples so I can understand it.
-- 
This message posted from opensolaris.org
___
zfs-discuss mailing list
zfs-discuss@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss


Re: [zfs-discuss] Oops, ran zfs destroy after renaming a folder and deleted my file system.

2010-02-24 Thread David Dyer-Bennet

On 2/24/2010 7:46 PM, tomwaters wrote:

Ok, I know NOW that I should have used zfs rename...but just for the record, 
and to give you folks a laugh, this is the mistake I made...

I created a zfs file system, cloud/movies and shared it.
I then filled it with movies and music.
I then decided to rename it, so I used rename in the Gnome to change the folder 
name to media...ie cloud/media. MISTAKE
I then noticed the zfs share was pointing to /cloud/movies which no longer 
exists.
So, I removed cloud/movies with zfs destroy--- BIGGER MISTAKE

So, now I am restoring my media from backup.
   


And THAT is one of the reasons why backups are important even with 
redundant safe fileservers.  (Software bugs, physical destruction, and 
user error!)


--
David Dyer-Bennet, d...@dd-b.net; http://dd-b.net/
Snapshots: http://dd-b.net/dd-b/SnapshotAlbum/data/
Photos: http://dd-b.net/photography/gallery/
Dragaera: http://dragaera.info

___
zfs-discuss mailing list
zfs-discuss@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss