ZFS advice on mirror creation

Hi, I'want to make regulars backups of my media(photos,videos,etc) , but I dont have another Cpu to make ZFS snapshots , so, I'will connect 2 hard disks in my machine(same sata port,same order) to make the backup,shutdown the machine and storage the sata disks in a safe place..

Is a safe way create a mirror in this mode? (2 2TB hardisks)
Connect the 2 disks, make a ZFS pool in one, and make a mirror in the second one,and from to time to time,connect the 2,make the backup and disconnect from the machine
 
Depends what you mean by safe. You'll lose redundancy during the time that they're apart and during resilvering you won't have that backup. And the more you do this the more likely it is that you'll run into issues related to typing something stupid. You also won't get any protection against changes between times when you sync things up.

You can do that, it would be functionally the same as if you have to replace a failed drive, but if you've got a 3rd disk, it's a lot safer as now you've got some ability to repair damage between swaps, even though the additional disk wouldn't be an actual backup.

In the past when I've had mirrored systems, I'll pull one of the disks out when I'm about to do something major like an upgrade as it's a bit faster to recover from if something does go wrong and I'm able to avoid the uncertainty of whether I really did back everything up.

Personally, I found the whole thing to be more of a hassle than it was really worth and now I collocate a drive offsite that gets the deduplicated backups with borgbackup.

EDIT: You may be better off just getting a cheap single board computer and sending the backups directly to an attached disk.
 
Depends what you mean by safe. You'll lose redundancy during the time that they're apart and during resilvering you won't have that backup. And the more you do this the more likely it is that you'll run into issues related to typing something stupid. You also won't get any protection against changes between times when you sync things up.

You can do that, it would be functionally the same as if you have to replace a failed drive, but if you've got a 3rd disk, it's a lot safer as now you've got some ability to repair damage between swaps, even though the additional disk wouldn't be an actual backup.

In the past when I've had mirrored systems, I'll pull one of the disks out when I'm about to do something major like an upgrade as it's a bit faster to recover from if something does go wrong and I'm able to avoid the uncertainty of whether I really did back everything up.

Personally, I found the whole thing to be more of a hassle than it was really worth and now I collocate a drive offsite that gets the deduplicated backups with borgbackup.

EDIT: You may be better off just getting a cheap single board computer and sending the backups directly to an attached disk.

you right, is not safe , time to get a old board and make a fixed fbsd instalation, a "backup box"
 
you right, is not safe , time to get a old board and make a fixed fbsd instalation, a "backup box"
If it weren't for backups, it would probably be fine. There's stuff like marking the drive physically and using glabel to give it a matching name to make it less risky, but I wouldn't personally be comfortable having to do this on a regular basis as my backup strategy.
 
I don't like it ... in the sense that it is not a good solution.
But I do like it: It is a decent solution, and at least you're trying to make backups.

Why isn't it a good solution? It requires too much human intervention, you have to move disks back and forth, you have to type too many commands, and those commands have to be run as root. There is too much potential for mistakes here, and given that mistakes might be "pull the wrong disk out" or "type a command wrong as root", that's just too dangerous for my taste.

Here would be my suggestion: Don't make the second disk a mirror. Instead make it a second file system, and update it with ZFS send and receive, or with rsync. And try to set up the permissions so the process of backing up is NOT CAPABLE OF modifying the live disk. How you do that depends on your usage, your requirements, and what workflow / software you want to use.

To the point that "human mistakes are dangerous": My previous employer (IBM, at the time the largest computer company in the world) actually did accurate studies of what causes data loss on IBM-serviced storage systems. And the absolute largest contribution was human error. With the classic example being: The hardware of a storage system (which is in practice always using redundant storage) reports a disk failure; the system continues working fine due to redundancy, and a field service technician is sent to replace the failed disk. The service technician arrives, promptly pulls out the wrong disk (the one that is still working fine and contains good and valid data), throws it in the trash (as he should), leaves the dead disk in the system which is now down and has suffered data loss, and happily leaves and drives to the next customer. Big oops, but happens all the time. The fix? Very clearly labeling and numbering the disks and the slots they go into (with big letters or numbers); adding blinking lights so the good disk has a nice green light, and the dead disk has an angry flashing red light; giving instantaneous feedback, if you pull the wrong disk the system immediately starts beeping and the lights start flashing blue and red; and lots of training and attitude adjustment. And making it so less maintenance is requires, since every maintenance operation has a high risk of mistakes; one example is called "fail in place", leaving dead disks in the system, so there is no chance to remove the wrong disk.

In turn, this leads to the old joke: To administer a computer, you need to hire a man and a dog. The man is there to feed the dog. The dog is there to bite the man if he tries to touch the computer.

So the moral of these jokes: Think about how to simplify and automate your workflow, and reduce the risk of doing the wrong thing, like mirroring from the backup disk (which has outdated information) back to the live disk.
 
Using a mirror as a backup is not optimal. The problem is that if you want to update the backup it takes very long to resync. It is not incremental.

You don't need a second computer to do snapshot send and receive. If you have ZFS it is a good way to go.
 
Back
Top