Deleted jail's dataset still exists

Status
Not open for further replies.

saurav

Contributor
Joined
Jul 29, 2012
Messages
139
I have recursive snapshots and replication set my Jail Root "tank/jails". Today, I deleted one of the jails I don't need anymore from the gui, and expected the jail's dataset to be destroyed alongwith, which didn't happen. Did the snapshots save the jail's dataset?

Also, it looks like the dataset was snapshot'ed even after the jail was deleted, so if snapshots prevented the dataset from getting destroyed along with the jail, it doesn't look like the dataset will ever be destroyed automatically. Do I have to destroy the deleted jail's dataset myself?

Or should I just wait for a couple of weeks (the snapshot lifetime for "tank/jails") to see if it sorts out automatically?

Thanks,
Saurav.
 
D

dlavigne

Guest
You could change the snapshot task to not be recursive. Otherwise, I think you have to delete (though disable might work) the snapshot task, delete the dataset, then recreate (or reenable if disable worked) the snapshot task.
 

saurav

Contributor
Joined
Jul 29, 2012
Messages
139
What about deleting the snapshots themselves? Will changing the snapshot task to not be recursive, or disabling or deleting it automatically remove all the snapshots?
 

saurav

Contributor
Joined
Jul 29, 2012
Messages
139
Sorry, haven't had much time to think about this.

Btw, I have deleted a plug-in and its jail persists too. And the snapshots are still happening. I have reduced the snapshot lifetime to have the middleware remove them. Once they are mostly gone, I will disable the recursive snapshot on jailroot and see if the remaining snapshots will also get removed, and if they do, whether the jails' datasets will also get removed automatically once the last snapshot is gone.

But it all seems unlikely and I have a feeling that the final part of this will have to be done "by hand".
 

saurav

Contributor
Joined
Jul 29, 2012
Messages
139
It seems reducing the snapshot lifetime affects only new snapshots. Older snapshots will live by their own lifetimes, set when they were created.

Unless I'm ok with waiting for the lifetime of older snapshots, there seems to be no way to make the middleware remove them by itself. I will have to delete those by hand (after removing or disabling the recursive snapshot task on the parent).

Anyway, today is not the day to do these things.

Happy New Year, everyone!
 

saurav

Contributor
Joined
Jul 29, 2012
Messages
139
So it looks like disabling a recursive snapshot doesn't clean the snapshots, but making it non-recursive does. My old snapshots are going away, without creating any new ones.

I have SMART errors on one of the discs, and am waiting for the RMA to arrive. I won't do much experimentation until I have replaced the disc.
 

saurav

Contributor
Joined
Jul 29, 2012
Messages
139
Sorry, forgot about this thread since I had issues replacing the bad disk. Its all sorted out now, and I can update what happened with the recursive snapshots.

  1. Making the periodic snapshot task non-recursive made the child snapshots go away, but retained all the snapshots on the parent dataset. And since the snapshot task was enabled, it kept creating new snapshots of the parent dataset.
  2. Since I also had a replication task for that parent dataset, once all the snapshots went away ALL the files/dirs in the child datasets on the replication target were gone (but not on the replication source). This might be obvious in hindsight, but it still doesn't feel intuitive to me.

  3. Any manual snapshots created on the source were replicated and automatically removed from the target as the subsequent snapshots expired.

Anyway, the datasets I wanted gone (corresponding to the plugins/jails I had deleted) where NOT automatically removed. So I just destroyed them myself from Storage => Active Volumes.
 
Status
Not open for further replies.
Top