Rollback to an old snapshot of a jail

Status
Not open for further replies.

madtulip

Explorer
Joined
Mar 28, 2015
Messages
64
Hello!

I made a snapshot ever 2h from a certain jail. Now i would like to roll back that jail by say 1 week. How to do that? i only found the rollback button for the very last snapshot.

Thanks!
 

cyberjock

Inactive Account
Joined
Mar 25, 2012
Messages
19,526
Follow the manual to rollback. :)
 

madtulip

Explorer
Joined
Mar 28, 2015
Messages
64
i didnt do a clone of the snapshot and copied over the "raw" files as i was not sure how that would interact with the jail beeing bound/connected to the root OS. so i should shut down the jail and then do a clone of the snapshot i want to roll back to. then i would delete all files in the jail and copy in the cloned version? that sounds like stuff could break to me which is why i stopped there and asked in the first place.
 

madtulip

Explorer
Joined
Mar 28, 2015
Messages
64
operation not permitted while deleting some of the files. so i canceled and rolled back that approach.
 

madtulip

Explorer
Joined
Mar 28, 2015
Messages
64
hmm. so as far as i understand the snapshot system does not have the option to roll back further than just one step via the gui which makes the whole system unsuitable for a repeated small footprint backup process unless you just want to backup a few human edited files. in my case where i wanted to roll back a whole OS this snapshot system doesnt seem to be suitable at all. And i thought of this to be one of the basics required functions of a storage/backup/server device, no? i find it realy hard to understand why this is implemented in this for automation and large data ammounts close to useless way.
 

SweetAndLow

Sweet'NASty
Joined
Nov 6, 2013
Messages
6,421
The FreeNAS GUI lets you roll back to any snapshot you want. I'm not sure what you are doing but you probably aren't following the procedure laid out in the manual(LINK).
 

madtulip

Explorer
Joined
Mar 28, 2015
Messages
64
Ah thats realy good then its jsut a case of the user (me) beeing to stupid. I did read the manual about 5 times now and it must be the case that i just dont get it.

what i did:
create a periodic snapshot task which will snapshot main/jails/myjail ever 2h.

so lets say the first created snapshot was called 1, the one made 2h later was called 2 and so on. i got 1,2,3,...,10. now 10 is the last. now under storage->snapshots i only have 3 buttons (clone, destroy, rollback) next to the snapshot number 10. all other snapshots 1,2,...,9 have only 2 buttons (clone, destroy). i would like to rollback to state 5. as there is no button next to 5 the first thing i did was to rollback to 10 in the hope that afterwards i can roll back to 9 and so on. doing so rolls back to 10 but doesnt kill the last snapshot so this doesnt allow me to go further back in time.

i then checked (on the left side) the snapshots 5,6,7,8,9,10 and hit the rollback button next to 10. this would take me back to 10 and not 5 aswell.

for testing i was then marking snapshot 8,9,10 on the left side and delete them in the hope that this would enable me to roll back to 7. doing so created a new snapshot (lets call it A) which combines the differential information in the deleted snapshots (8,9,10) if i understood that correclty. rolling back to A brings me back to 10 effectively. so thats no gain.

so i concluded i can only roll back to the very last snapshot doing this (10). i then stopped execution of the jail and created a clone of 5. i sshed into the main system and went to the place where the jail and its clone are now mounted (main/jails/myjail next to mail/jails/myjailCLONE_OF_5). i triied to manualy delete all files in main/jails/myjail in order to replace them by the files in mail/jails/myjailCLONE_OF_5. as root i couldnt delete some of the system files (like main/jails/myjail/etc/passwd) due to "permission denied" or similar error. i was kinda exspecting that this wouldnt work and thought of the whole thing as beeing a very bad idea (i got the idea from "the manual") due to the main/jails/myjail beeing included/mounted/bound somehow by the top level operating system. so as this raw copy of clone approach was a fail i rolled back the myjail to 10 (the last snapshot i had) i order to clean up the mess.

so where is "da button" or what did i miss in the manual?

thanks for your time!
 

ovizii

Patron
Joined
Jun 30, 2014
Messages
435
@madtulip: I had a look adn read your post and I'm totally getting you. Just commenting and subscribing as I'd also like to know what we are overlooking :-(
 

nick779

Contributor
Joined
Dec 17, 2014
Messages
189
Apparently there isnt a fix for this... which kinda stinks
 

ovizii

Patron
Joined
Jun 30, 2014
Messages
435
is this a definite answer, as in there is no way to roll-back to a specific old snapshot?
I'm still hoping we're doing this wrong and someone who is using snapshots can tell us how this works...
 

nick779

Contributor
Joined
Dec 17, 2014
Messages
189
is this a definite answer, as in there is no way to roll-back to a specific old snapshot?
I'm still hoping we're doing this wrong and someone who is using snapshots can tell us how this works...

I dont know, Im just assuming there isnt one since this thread died.
 

Jailer

Not strong, but bad
Joined
Sep 12, 2014
Messages
4,977
Status
Not open for further replies.
Top