For Linux desktops, when Windows compatibility is not an issue, which file system is preferred for USB sticks? For example ext2, ext3, ext4, btrfs, nilfs, or even NTFS? Would journaling wear them out prematurely? I heard it's better to mount with noatime option, but how to set it if it's used across many computers?
3 Answers
All decent flash devices perform internal wear leveling so the journal won't wear them out ( too ) prematurely, so ext4 is fine from that perspective. The problem with using most unix filesystems across multiple computers is permissions. If the different computers do not have the same set of users with the same UIDs, the ownership will be wrong. For this reason, it is generally better to stick with fat32, which also allows you to share with Windows. As an alternative, you can use UDF, which can pretend the files are always owned by the interactively logged in user that (auto) mounted the drive.
-
With vfat, you don't have any permissions at all - how can it be an advantage? "Windows compatibility is not an issue" was the clear restriction from the question. Feb 27, 2012 at 13:15
-
@userunknown, because with no permissions at all, they can't cause problems when you move the drive to another machine where you have a different UID.– psusiFeb 27, 2012 at 15:38
-
If I have sudo permissions - if I have sudo permissions on one machine - I can do a chown for whole directory trees, but executables stay executable and writable is only what needs to be writable. With vfat, that information is lost and harder to restore than the owner of files. Feb 28, 2012 at 1:54
-
@userunknown, yes, if you like being able to keep some files writable/executable but not others, UDF would be the best option so you don't have to bother with chowning everything back and forth each time.– psusiMar 1, 2012 at 18:59
BTRFS would be good, but it's not stable yet, so I would use ext2 or ext3/4 without a journal.
BTRFS's copy on write method doesn't put as big wearing pressure on the USB as ext3-4 because of its journal.