ZFS To partition or not

Greetings,
I am a newbie with both FreeBSD and ZFS. Well, I've been playing with it a couple of years but still inexperienced. I recently purchased a very small computer and an external 5TB USB hard drive that I intend to keep in a friends basement for nightly incremental backups of my FreeNAS Plex server.

I've been reading the FreeBSD Mastery: ZFS ebook which states the author recommends using a GPT disk partition with ZFS on top of that. Now clearly the authors know a lot more than I do about ZFS but it seems that for a single non-redundant USB drive that is not intended to boot that ZFS on the raw disk should work just fine. In fact, it seems not having a GPT partition would make it easier down the road should I try mounting this backup disk on another system.

So, Question One: For a stand-alone USB backup drive should I have not simply used zpool create backup /dev/ad0' then zfs create backup/mycomputername?

I've been using it and all seems go so far.


Question Two: I've been reading about zfs export and import. After my backup each night should I be running zfs export on the drive in case I need to move the drive to my home computer for a recovery? Is it required to export the drive if I intend to use it on another computer? Or, on another FreeBSD system can I just plug it in and use mount to mount it?

I appreciate any info regarding this.

Thanks.
-Cablet
 
So, Question One: For a stand-alone USB backup drive should I have not simply used zpool create backup /dev/ad0' then zfs create backup/mycomputername?

I've been using it and all seems go so far.
No, not in my opinion. It works, you probably won't get any problems but it can could to bite you in the longer run. In the event that you need to replace the HD with another one and you have the exact same model there is always a possibility that they do not fully match. So if the new HD is even one sector smaller you could run into issues.

However, this is all theoretically. Using the entire HD has become common practice, also because the chances of running into issues are quite slim.

Question Two: I've been reading about zfs export and import. After my backup each night should I be running zfs export on the drive in case I need to move the drive to my home computer for a recovery?
zfs export is a non-existent command, I think you were referring to zpool export. I wouldn't run that every day, also because your filesystems will be unmounted. See the zpool(8) manualpage.

In general using the export option can help to transport a filesystem and make it accessible on another computer, but it is not mandatory. If you try to access the pool on another computer you'll probably get a warning about the dataset being used elsewhere, but that's about it.

Hope this can help.
 
Back
Top