Move away from unsafe FAT on USB sticks or disks, use ZFS

_Gea

Supreme [H]ardness
Joined
Dec 5, 2010
Messages
4,234
As we now have ZFS on every mainstream OS from BSD over OSX to Windows, I start using ZFS instead FAT on USB sticks or disks as the ultimate solution for data security on such unsecure media to have full checksum verification of data or redundancy with copies=2

There is no automount of ZFS removeable pools like you have with FAT, but I simply name all pools on USB sticks or disks "usb". A simple "zpool import -f usb" and the stick/disk is there. On Windows I place a usbmount.bat on the desktop. A simple right mouse click as admin and the stick is mounted.

Export pool usb prior remove
 
Last edited:
ok....
what aboot exfat?

ok, but then say

- no to checksums (no report on bad files)
- no to Copy on Write (undamaged filesystems after a crash/remove during write)
- no to transparent compress
- no to transparent encryption
- no to autorepair files on bad blocks with ZFS and copies=2
 
One could also use NTFS which is natively supported on Windows and Linux (kernel-based now). For all the positives about ZFS there are also downsides that don't usually get mentioned.

(I realize though the OP is the author of a ZFS front-end so it makes sense to evangelize its use)
 
There are use cases where you still need a *Fat* variant and a data loss or undetected bad file is not relevant.
There are use cases where data security is the main concern like a secure data move via stick or backup via checksum protected zfs send to a removeable ZFS pool with copies=2 on USB, equipped with regular disks, SSD or M.2 NMVe as a disaster backup instead a remote backup system or a checksum protected cloud backup. This is where I am, not the movie on a stick that you want to watch on TV.
 
In 30+ years of PC'ing I see little benefit for all the extra steps and lack of shifting it around for USB drives.

Plug and play baby!
 
Much respect for evangelizing your preferred filesystem, and if it works for your use case I'm happy to hear it. ZFS is an interesting choice here, and I'd like to hear about how its capabilities stack up versus NTFS on flash storage, especially since the latter's Master File Table is a potentially unwanted source of writes to a finitely writeable medium. But for most people thumb drives are driven by practicality - most of their use cases now are for situations where internet access between the origin and destination isn’t guaranteed or reliable, or would be slower than simply flinging a drive with the data at someone. The sneakernet method of transferring sensitive data on physical media's only as secure and stable as the person holding the drive, too. For the other stuff - playing music in your car where you don't want to bother with streaming, thumping movie rips into media players, &c. - FAT32's deeply entrenched, and exFAT has been gaining ground for shuffling around HD/4K media in those roles. But I genuinely appreciate the heads up.
 
Last edited:
As we now have ZFS on every mainstream OS from BSD over OSX to Windows
The "reason" you use things like FAT/vFAT/ExFAT is for compatibility. You're not going to just plugin a ZFS "whatever" into "something" and have it automatically understood.

Even in the case of typical computer OS's, ZFS isn't necessarily understood by a default install. So, "having" access to, is not the same as something being present.

But, if you handle your own device configurations and what you've enabled there, you can choose to use whatever makes best sense for you.
 
You can`t just give away a file on an USB stick to anyone like you can with *Fat* but that is not the point and for such I use a cloud link now.
All of my systems have ZFS so I can just plug an external USB disk (can be 20TB) ex to my Mac, Linux/ Unix or Windows systems and import the pool to access or backup data. Removeable USB disks are perfect for external disaster backups (should be online only for backups) but in no way on anything but ZFS.

If a new system lacks ZFS, it is no more than adding the ZFS driver on OSX (many versions supported) or Windows 10/11/Server via online download or from a FAT USB stick (30MB) From all options this is the only secure one to mutual access or move data inhouse or in a workgroup or do backups on external disks from either OS.

To view a movie on TV I also use a Fat stick but not for working, large or important data where I want ZFS checksum protection, encryption with a key per filesystem or single disk redundancy (copies=2). Only point is that you must care about the import/export process (a import/export link on desktop for pool "usb") as a single disk pool hangs in suspended mode if you just unplug (reboot required)

for example
How do I handle ZFS on Windows USB disks
- I always name usb pools "usb"
- I create three batch files on the desktop

poolstate.bat with file content:
zpool list
timeout /t 5

import_usb_pool.bat with file content:
zpool import -f usb
timeout /t 5


export_usb_pool.bat with file content:
zpool export -f usb
timeout /t 5

Execute the file via a mouse right click and "run as administrator"
Prior an unplug, export or check state
 
Last edited:
Back
Top