Recovery Tactics

Status
Not open for further replies.

sab5449

Cadet
Joined
Jun 3, 2017
Messages
7
Just got my first FreeNAS (v 9.10.2-U3) system up and running and I'm looking for a bit of explanation surrounding recovery techniques.

We've got:
1. Snapshots
2. System->Advanced->Backup
3. Replication tasks
4. Rsync tasks
Is there anything else I've missed?

My goal with this FreeNAS is primarily data integrity, and preventing against data loss. I have a raidz2 configuration composed of 4 2TB disks and I want to make sure that if 3/4 drives were to fail that I still will not have lost any data or that I'm able to restore to some recent state.

My understanding/questions-

1. I understand that snapshots are not a backup and that they are just there to allow me to restore the pool back to the way it looked at a previous point in time (or recover a lost file(s) without actually rolling back to previous state).
2. What is this?
3. This a complete backup of a zfs pool based on a particular snapshot. How is this intended to be used?
4. Copies data from on system to another over the network, is this pretty much the same as a replication task?
 

Robert Trevellyan

Pony Wrangler
Joined
May 16, 2014
Messages
3,778
  1. Right.
  2. This allows you to save the system configuration to your client machine. You should do this whenever you change any settings.
  3. A replication allows a snapshot to be replicated to another host. It need not be an entire pool. The granularity of snapshots and associated replications is per dataset (but they can be recursive, which could encompass an entire pool).
  4. Rsync is a general purpose *nix replication tool, not limited to ZFS. It normally operates within a single filesystem, and it doesn't preserve ZFS pool structure or snapshot history.
 

Spearfoot

He of the long foot
Moderator
Joined
May 13, 2015
Messages
2,478
Hello, and welcome to the forums!

My goal with this FreeNAS is primarily data integrity, and preventing against data loss. I have a raidz2 configuration composed of 4 2TB disks and I want to make sure that if 3/4 drives were to fail that I still will not have lost any data or that I'm able to restore to some recent state.
Just to be clear, since I'm not sure what you mean by '3/4 drives': if you lose 3 of the 4 drives in your RAIDZ2 pool, you will lose all of the data on that pool, including any snapshots. Your only option for recovery would be to restore your data from backup.

My understanding/questions-

1. I understand that snapshots are not a backup and that they are just there to allow me to restore the pool back to the way it looked at a previous point in time (or recover a lost file(s) without actually rolling back to previous state).
2. What is this?
3. This a complete backup of a zfs pool based on a particular snapshot. How is this intended to be used?
4. Copies data from on system to another over the network, is this pretty much the same as a replication task?
ZFS replication copies snapshots between pools. A snapshot is the state of the file system at a particular point in time. The pools can be located on the same or separate servers.

Rsync can be used to achieve the same purpose, but it doesn't use snapshots. It's a 'smart' data synchronization program, but is UNIX-oriented and has problems copying permissions on Windows datasets that ZFS replication doesn't have.

FWIW, I use both replication and rsync. I use replication to backup my main FreeNAS server to my secondary FreeNAS server, the end goal being to have a backup of my data.

Creating good backups is a problem that many users ignore, to their great peril. It's easy to fall into the trap of thinking "Hey, I've got this wonderful, redundant FreeNAS server, so why worry about backups?!", but redundancy is not a backup. You're wise not to ignore the issue.

Good luck!
 

sab5449

Cadet
Joined
Jun 3, 2017
Messages
7
  1. Right.
  2. This allows you to save the system configuration to your client machine. You should do this whenever you change any settings.
  3. A replication allows a snapshot to be replicated to another host. It need not be an entire pool. The granularity of snapshots and associated replications is per dataset (but they can be recursive, which could encompass an entire pool).
  4. Rsync is a general purpose *nix replication tool, not limited to ZFS. It normally operates within a single filesystem, and it doesn't preserve ZFS pool structure or snapshot history.
2. What is the difference between that and System->General->Save Config?

Sounds like I want to use replication then, because ideally I'd like to backup then entire pool snapshots and all. I definitely don't want to spend the money to setup another identical server just for the sake of storing the replication, but it looks like the system storing the replication data must also be a ZFS system. Looks like I'll have to create another pool on the same server, and store the replicate on that? What's the best way to set this up?
 

Robert Trevellyan

Pony Wrangler
Joined
May 16, 2014
Messages
3,778

sab5449

Cadet
Joined
Jun 3, 2017
Messages
7
Hello, and welcome to the forums!

Just to be clear, since I'm not sure what you mean by '3/4 drives': if you lose 3 of the 4 drives in your RAIDZ2 pool, you will lose all of the data on that pool, including any snapshots. Your only option for recovery would be to restore your data from backup.

ZFS replication copies snapshots between pools. A snapshot is the state of the file system at a particular point in time. The pools can be located on the same or separate servers.

Rsync can be used to achieve the same purpose, but it doesn't use snapshots. It's a 'smart' data synchronization program, but is UNIX-oriented and has problems copying permissions on Windows datasets that ZFS replication doesn't have.

FWIW, I use both replication and rsync. I use replication to backup my main FreeNAS server to my secondary FreeNAS server, the end goal being to have a backup of my data.

Creating good backups is a problem that many users ignore, to their great peril. It's easy to fall into the trap of thinking "Hey, I've got this wonderful, redundant FreeNAS server, so why worry about backups?!", but redundancy is not a backup. You're wise not to ignore the issue.

Good luck!

I realize that if I lose 3/4 drives all my data will be lost. I meant that I would like to be able to restore the server to it's pre-failure state through the use of a backup. What if you didn't have a second FreeNAS server? How would you configure your backups?
 

Spearfoot

He of the long foot
Moderator
Joined
May 13, 2015
Messages
2,478
I realize that if I lose 3/4 drives all my data will be lost. I meant that I would like to be able to restore the server to it's pre-failure state through the use of a backup. What if you didn't have a second FreeNAS server? How would you configure your backups?
Well, there are quite a few different ways of going about backing up your data.

I'm a 'Belt & Suspenders' kind of guy. ;)

I replicate my main FreeNAS server to a secondary server...

I also replicate the primary pool on my main FreeNAS server to a second pool on the same server, made up of a single 6TB disk. I have two of these disks, and I rotate them between the server and a fireproof safe. This approach - a backup pool made up of a single disk - may be the easiest route for you to take as all you need to get started is a single disk large enough to hold your data. You have 4 x 2TB disks in a RAIDZ2 vdev, so your data must be less than 4TB all-in. A 6TB disk would be large enough. A 4TB disk would work, too, depending on how full your pool is. A single-disk pool doesn't have any redundancy, but it's better than nothing.
 
Status
Not open for further replies.
Top