How do I get a single file that is 22GB onto a MS-DOS FAT 30GB memory stick?
You can format the memory stick as ExFAT. Go to Disk Utility, click the Erase button, and select the Format as ExFAT. ExFAT supports much larger file size and you'd be easily able to copy 22GB file on a ExFAT formatted filesystem.
ExFAT is supported on Mac, Windows as well as Linux and any of those OS can both read and write to an ExFAT formatted filesystem.
Alternate approach, if you wish to stick with MS-DOS FAT filesystem:
You can use the split
command-line utility. The split
utility comes pre-installed in macOS (I have assumed you are using a Mac).
The split
command-line utility lets you split a large file into smaller chunks which can be managed separately. The command lets you specify the size of a chunk and the input file is broken into the chunks of mentioned size with the last chunk equal to or less than the chunk size.
The chunks can at a later point be re-joined to restore the original file.
This command-line utility comes in handy in cases where you have restrictions on file size such as yours (or such as when wanting to email a larger file which is over the limit for the attachment size allowed in an email).
This is how you can use the split
command to break the 22GB file in question into chunks smaller than 4GB each. On your Mac, launch Terminal.app, use the cd
command to navigate to the directory where you have the original 22GB file and type the following command:
split -b 4000m "original_filename" "pattern_name."
where the original_filename
is the name of the input file and pattern_name.
would be the name used for chunks. The chunks would be generated as pattern_name.aa
, pattern_name.ab
, pattern_name.ac
and so on. The output file chunks would be generated and saved in the current directory. Each chunk would be 4000m or 4000 megabytes in size, which is under 4GB. You can choose any other appropriate chunk size as well.
Now you can copy the individual chunks on the memory sticks as they are smaller than the allowed size for the filesystem.
At a later point, when you want to re-join the chunks, copy the chunks onto a filesystem which supports larger file size (such as other Mac, or the same Mac in future), and run the following command:
cat pattern_name.* > original_filename
where the original_filename
is the name/path for the output file.
Additionally, if you'd also want to make sure that the integrity of the file is maintained, you can derive and verify with the MD5 checksum for the original and the re-joined file.
The MD5 checksum for a file can be obtained by running the following built-in macOS command:
md5 original_filename
which should give an output similar to the following:
MD5 (original_filename) = 00e47d9d1414d49ab5ab3eee653ed96b
The value for checksum should match before and after the split. The value of checksum shown above would differ in your case.