Skip to main content

Split Large File for FAT32 USB - Linux Guide

The error:

mv: error writing '/mnt/as.zip': File too large

means that the destination file system (in this case, likely mounted at /mnt/) does not support large files, typically files over 2 GB or 4 GB in size.

Common causes
#

  1. FAT32 file system β€” has a 4 GB file size limit.
  2. ext3 (with certain configurations) β€” may have issues with very large files.
  3. Filesystem is mounted with size limitations or quotas.

βœ… Solution Options
#

πŸ” 1. Check the file system type:
#

Run:

df -T /mnt

Look at the Type column β€” if it’s vfat (FAT32), it has a 4 GB file size limit.

πŸ’‘ 2. Solutions:
#

βœ… a. Reformat the destination with a large-file-friendly filesystem:
#
  • Use exFAT, NTFS, ext4, XFS, or Btrfs.

    # Example for reformatting to exFAT (after backing up data!)
    sudo mkfs.exfat /dev/sdX1
βœ… b. Compress or split the file before moving:
#

Split the file into parts:

split -b 2G as.zip as.zip.part-

Then move all parts:

mv as.zip.part-* /mnt/

To reassemble later:

cat as.zip.part-* > as.zip
βœ… c. Use a different destination:
#

Move the file to a location with an ext4, xfs, or exfat file system.


If you’re not sure about the filesystem or want help formatting safely, feel free to share the output of:

df -T /mnt
Youcef
Author
Youcef
My name is youcef and i’m linux user who fool in love with linux , like free and open software .