0

Trying to copy an 8GB, encrypted image of one of my flash drives (gotten from "dd" command) onto a flash drive, but flash is FAT formatted. So I'll need to format a new flash to transfer it over to.

Not sure if I should format to ext4 or NTFS. I've read about the pros and cons of each, but if NTFS can be used on both windows and Linux, plus some other benefits, like handling longer file names, is it worth using ext4?

Jeff Schaller
  • 66,199
  • 35
  • 114
  • 250
hddfsck777
  • 99
  • 1
  • 8
  • 2
    Biggest benefit I see to using ext4 is less file corruption, if that is actually true. – hddfsck777 Aug 11 '19 at 19:54
  • 1
    I remember that some time ago I had a problem with too many files being created on NTFS disk and had to switch to ext for this reason. – Arkadiusz Drabczyk Aug 11 '19 at 20:31
  • 1
    Relating https://unix.stackexchange.com/q/355763/117549 https://unix.stackexchange.com/questions/32729/which-linux-file-systems-for-usb-sticks and https://unix.stackexchange.com/q/55496/117549 – Jeff Schaller Aug 11 '19 at 20:31
  • I got it, it was: `No free mft record for $MFT: No space left on device` – Arkadiusz Drabczyk Aug 11 '19 at 20:31
  • If you want to flash that image, why would original data matter? It's gonna be overwritten anyway. – 炸鱼薯条德里克 Aug 11 '19 at 22:30
  • 2
    It is unclear what you are asking, what is your use-case? – Paradox Aug 11 '19 at 23:39
  • Why would it be "overwritten anyway?" – hddfsck777 Aug 11 '19 at 23:50
  • [UDF](https://en.m.wikipedia.org/wiki/Universal_Disk_Format) is an alternative that supports big files, long file names, and more, and it is compatible with both Windows and Linux. – Johan Myréen Aug 12 '19 at 05:10
  • If you want to write it to the device, it's format is moot (it will be overwritten completely). If you want to copy a file there, it depends on how you want to use it. If only Linux, ext4 (NTFS support is somewhat flaky). If Linux and Windows, NTFS (ext4 on Windows is troublesome). – vonbrand Aug 12 '19 at 12:27
  • @vonbrand31 "it" will be overwritten completely. I assume you mean the destination hdd or flash drive..? Not sure what "it" is. Why would the device be overwritten completely? I have many other files on the destination. Why would copying an image overwrite anything other than the bites or blocks where the image is being copied to? – hddfsck777 Aug 12 '19 at 13:04
  • 1
    @hddfsck777 I think your question contains too many irrelevant details, which is confusing people. If you change the first sentence to "I have a big (8 GB) file I want to copy to a flash drive", your intention would be clearer. – Johan Myréen Aug 12 '19 at 15:31

1 Answers1

2

The question you are making is related to file systems:

Is there any benefit to using ext4 instead of NTFS?

The correct answer to that question is long, complex, and usually ends up including several personal opinions. My personal opinion is that ext4 is more useful than NTFS for use in Linux. But for Windows use, probably, NTFS is a better fit. But again, that's just my opinion.

What I recommend you is to decouple the issue of file size from the file system.

How?

Use FAT (aka vFAT) as it could be read (and correctly written) in all important OSes, and,

Build a compressed archive of all the files to transfer divided into volumes smaller than 2GiB.

To store one or many files you can build a tar file with all the permissions, ACLs and time tags you may need from Linux, MacOS and/or Windows (10).

Then, to compress the tar file (or one file as in your use case) you may use 7z:

On the command line (Usually Linux):

7z a -v2g -t7z -m0=lzma -mx=9 -mfb=64 -md=32m -ms=off archive.7z files

On Windows